Ticket #50660: Portfile.diff
File Portfile.diff, 6.9 KB (added by mcg@…, 9 years ago) |
---|
-
Portfile
old new 6 6 PortGroup waf 1.0 7 7 8 8 # Please revbump mpv whenever ffmpeg{,-devel} is updated! 9 github.setup mpv-player mpv 0.1 1.0 v9 github.setup mpv-player mpv 0.15.0 v 10 10 revision 2 11 11 categories multimedia 12 12 license GPL-2+ … … 31 31 extract.only-delete ${waf_distfile} 32 32 33 33 checksums ${mpv_distfile} \ 34 rmd160 47d625b899b7bbe3867845e9710fef14d41d5249\35 sha256 7d0598a0f5f5825143e2678f058d6305683c82ff36702235703e8d54048132fe\34 rmd160 78569931a3bf6bfe18154da8eaf9f3623d543957 \ 35 sha256 c2011c9c9a9e22cf84d16dcb5f23572bbbcf414b51955b5e095af274e51351c1 \ 36 36 ${waf_distfile} \ 37 37 rmd160 bb1dcd10a0c336a5497bb1247a301c27f997078c \ 38 38 sha256 01bf2beab2106d1558800c8709bc2c8e496d3da4a2ca343fe091f22fca60c98b … … 61 61 --enable-libass \ 62 62 --enable-coreaudio \ 63 63 --enable-cocoa \ 64 --disable-vda-hwaccel \65 64 --disable-videotoolbox-hwaccel \ 66 --disable-vda-gl \67 65 --disable-videotoolbox-gl 68 66 69 67 # mpv autodetects many support libs. To prevent undeclared … … 100 98 --disable-jpeg \ 101 99 --disable-tv \ 102 100 --disable-lua \ 103 --disable-apple-remote 101 --disable-apple-remote \ 102 --disable-libmpv-shared 104 103 105 104 # Fix picking up the correct talloc version. 106 105 # -isystem has the added benefit of moving the include … … 145 144 --enable-apple-remote 146 145 } 147 146 148 set has_vda 0149 147 set has_vtb 0 150 148 151 149 platform darwin { … … 159 157 and adjust it to your needs. 160 158 }] 161 159 162 # Note: VDA support has already been removed on master. The next update will probably not include it anymore.163 164 # VDA (video hardware acceleration, mostly H264) is only supported on 10.6.3+ up to (excluding) 10.11.165 #if {(${os.major} > 10 || (${os.major} == 10 && ${os.minor} >= 3)) && (${os.major} < 15)}166 # Due to a bug in ffmpeg(?), we have to enable VDA on 10.11 as well, even though it shouldn't be supported.167 # More information: https://github.com/mpv-player/mpv/issues/2299168 if {${os.major} > 10 || (${os.major} == 10 && ${os.minor} >= 3)} {169 set has_vda 1170 configure.args-delete --disable-vda-hwaccel \171 --disable-vda-gl172 configure.args-append --enable-vda-hwaccel \173 --enable-vda-gl174 }175 176 160 # VideotoolBox, a new hardware acceleration framework, is supported on 10.8+ and "here to stay". 177 161 # It provides support for H264, H263, MPEG1, MPEG2 and MPEG4. 178 162 if {${os.major} > 11} { … … 183 167 --enable-videotoolbox-gl 184 168 } 185 169 186 if { (${has_vtb}) || (${has_vda})} {170 if {${has_vtb}} { 187 171 notes-append { 188 172 This config file already defines the necessary video output settings to make \ 189 173 use of the hardware acceleration features provided by your operating system. 190 174 } 191 192 if {(${has_vtb}) && (${has_vda})} {193 notes-append [subst {194 While the default configuration file makes use of the newer and preferred \195 VideoToolBox framework, a separate config file set up for the old VDA \196 framework has been installed as197 * ${prefix}/share/examples/${name}/config-maintainer-vda.198 }]199 }200 175 } else { 201 176 notes-append { 202 177 Sadly, your system is incapable of utilizing mpv's hardware decoding features. … … 229 204 patch-video_out_opengl_cocoa.c-hardcode-OpenGL-2.diff \ 230 205 patch-osdep_macosx_compat.m-add-subscripting-implementation.diff \ 231 206 patch-audio_out_ao_coreaudio_utils.c-add-missing-header-for-getpid.diff \ 232 patch-video_decode_vda.c-disable-HAVE_VDA_DEFAULT_INIT2.diff \233 patch-video_out_opengl_hwdec_vda.c-disable-NV12.diff234 235 207 # Let's hope this is actually unneeded... 236 208 #patch-video_out_cocoa_common.m-use-deprecated-ColorSync-functions.diff 237 209 … … 246 218 } 247 219 248 220 post-extract { 249 xinstall -m 0644 -W "${filespath}" config-maintainer -vda config-maintainer-vtb"${worksrcpath}/TOOLS/"221 xinstall -m 0644 -W "${filespath}" config-maintainer "${worksrcpath}/TOOLS/" 250 222 } 251 223 252 224 pre-configure { 253 225 if {[variant_isset network]} { 254 reinplace -W "${worksrcpath}/TOOLS" "s|@@NETWORK@@||" config-maintainer-vda 255 reinplace -W "${worksrcpath}/TOOLS" "s|@@NETWORK@@||" config-maintainer-vtb 226 reinplace -W "${worksrcpath}/TOOLS" "s|@@NETWORK@@||" config-maintainer 256 227 } else { 257 reinplace -W "${worksrcpath}/TOOLS" "|@@NETWORK@@|d" config-maintainer-vda 258 reinplace -W "${worksrcpath}/TOOLS" "|@@NETWORK@@|d" config-maintainer-vtb 228 reinplace -W "${worksrcpath}/TOOLS" "|@@NETWORK@@|d" config-maintainer 259 229 } 260 230 } 261 231 } … … 312 282 313 283 post-destroot { 314 284 xinstall -d -m 0755 ${destroot}${prefix}/etc/${name} 315 foreach etcfile {encoding-profiles.conf example.conf input.conf} {285 foreach etcfile {encoding-profiles.conf mpv.conf input.conf} { 316 286 xinstall -m 0644 ${worksrcpath}/etc/${etcfile} \ 317 287 ${destroot}${prefix}/etc/${name}/${etcfile} 318 288 } … … 324 294 325 295 if {${os.platform} eq "darwin"} { 326 296 if {(${has_vtb})} { 327 xinstall -m 0644 ${worksrcpath}/TOOLS/config-maintainer -vtb\297 xinstall -m 0644 ${worksrcpath}/TOOLS/config-maintainer \ 328 298 ${destroot}${prefix}/share/examples/${name}/config-maintainer 329 299 330 if {(${has_vda})} {331 xinstall -m 0644 ${worksrcpath}/TOOLS/config-maintainer-vda \332 ${destroot}${prefix}/share/examples/${name}/333 }334 } else {335 xinstall -m 0644 ${worksrcpath}/TOOLS/config-maintainer-vda \336 ${destroot}${prefix}/share/examples/${name}/config-maintainer337 300 } 338 301 } 339 302 } … … 496 459 configure.args-replace --disable-pdf-build \ 497 460 --enable-pdf-build 498 461 } 462 463 variant api description {Enable C API} { 464 configure.args-replace --disable-libmpv-shared \ 465 --enable-libmpv-shared 466 }