Ticket #12158: MPlayer-variants.patch
File MPlayer-variants.patch, 8.7 KB (added by ecronin (Eric Cronin), 17 years ago) |
---|
-
Portfile
../ 46 46 livecheck.regex MPlayer-(1.0rc\[0-9\]+)\.tar\.bz2 47 47 48 48 depends_lib port:jpeg port:lame port:libiconv port:libmad \ 49 port:libpng port:libvorbis port:lzo port:ncurses \ 50 port:zlib 49 port:libogg port:libpng port:libungif \ 50 port:libvorbis port:lzo port:ncurses port:zlib 51 depends_build port:pkgconfig 51 52 52 53 # MPlayer's ./configure REALLY does not want you to use ENV for this 53 54 configure.cflags {} … … 56 57 configure.ldflags {} 57 58 58 59 configure.args \ 59 --with-extraincdir=${prefix}/include :${prefix}/include/cdparanoia/interface:${prefix}/include/cdparanoia/paranoia\60 --with-extraincdir=${prefix}/include \ 60 61 --with-extralibdir=${prefix}/lib:${prefix}/lib/samba3 \ 61 62 --datadir=${prefix}/share/${name} \ 62 63 --confdir=${prefix}/etc/${name} \ 63 64 --mandir=${prefix}/share/man \ 64 65 --enable-png --enable-jpeg \ 65 66 --enable-liblzo --enable-libvorbis \ 66 --enable-mad -- disable-faad-external\67 -- enable-largefiles67 --enable-mad --enable-mpdvdkit \ 68 --disable-faad-external --enable-largefiles 68 69 69 70 # MPlayer autodetects many support libs. To prevent undeclared 70 71 # dependencies, explicitly disable everything optional first. 71 72 # Later, let autodetect do its magic not explicit --enable 72 73 configure.args-append \ 73 74 --disable-smb --disable-live --disable-dvdnav \ 74 --disable-dvdread --disable-mpdvdkit\75 --disable-dvdread \ 75 76 --disable-cdparanoia --disable-freetype \ 76 77 --disable-fontconfig --disable-unrarlib \ 77 78 --disable-fribidi --disable-enca \ 78 --disable- gif --disable-libcdio --disable-xvid \79 --disable-libcdio --disable-xvid \ 79 80 --disable-x264 --disable-nut --disable-libfame \ 80 81 --disable-speex --disable-theora --disable-faac \ 81 82 --disable-ladspa --disable-libdv --disable-toolame \ … … 85 86 --disable-esd 86 87 87 88 post-destroot { 88 file mkdir${destroot}${prefix}/share/doc/${name}89 xinstall -d -m 0755 ${destroot}${prefix}/share/doc/${name} 89 90 eval file copy [glob ${worksrcpath}/DOCS/*] \ 90 91 ${destroot}${prefix}/share/doc/${name} 92 xinstall -d -m 0755 ${destroot}${prefix}/etc/${name} 93 foreach etcfile {codecs.conf dvb-menu.conf example.conf \ 94 input.conf menu.conf} { 95 xinstall -m 0644 ${worksrcpath}/etc/${etcfile} \ 96 ${destroot}${prefix}/etc/${name}/${etcfile} 97 } 91 98 } 92 99 93 100 ##### Mplayer features 94 101 95 # Install all possible languages for man pages 96 variant man_all_lang{102 variant man_all_lang \ 103 description {Install all possible languages for man pages} { 97 104 configure.args-append --language=all 98 105 } 99 106 107 # Bundle all the font deps into one onscreen display variant 100 108 # configure doesn't fully build up necessary flags when --enable-fontconfig 101 109 # is used, so use autodetect instead 102 variant fontconfig { 103 depends_lib-append port:fontconfig 110 variant osd \ 111 description {Enable onscreen display and font support} { 112 depends_lib-append port:fontconfig port:freetype 104 113 configure.args-delete --disable-fontconfig 105 }106 107 variant freetype {108 depends_lib-append port:freetype109 114 configure.args-delete --disable-freetype 110 configure.args-append --enable-freetype 115 configure.args-append --enable-freetype --enable-menu 111 116 } 112 117 113 variant fribidi { 118 variant fribidi \ 119 description {Enable FriBidi Unicode support} { 114 120 depends_lib-append port:fribidi 115 121 configure.args-delete --disable-fribidi 116 122 #configure.args-append --enable-fribidi … … 118 124 119 125 ##### Inputs 120 126 121 ## Broken as of 10/25/06 (samba3 produces bad libsmbclient.dylib) 122 #variant smb { 123 # depends_lib-append port:samba3 124 # configure.args-delete --disable-smb 125 # #configure.args-append --enable-smb 126 #} 127 variant nodvd \ 128 description {Disable DVD and DeCSS support} { 129 configure.args-delete --enable-mpdvdkit 130 configure.args-append --disable-mpdvdkit 131 } 127 132 128 variant dvdread { 129 depends_lib-append port:libdvdread 130 configure.args-delete --disable-dvdread 133 variant smb \ 134 description {Enable smb:// network support} { 135 depends_lib-append port:samba3 136 configure.args-delete --disable-smb 137 configure.args-append --enable-smb 131 138 } 132 139 133 140 ## Broken as of 10/25/06 (version issue?) 134 #variant cdparanoia { 141 #variant cdparanoia 142 # description {Enable CDDA support} { 135 143 # depends_lib-append port:cdparanoia 136 144 # configure.args-delete --disable-cdparanoia 137 145 # #configure.args-append --enable-dvdread … … 139 147 140 148 ##### External codecs 141 149 142 variant gif { 143 depends_lib-append port:libungif 144 configure.args-delete --disable-gif 145 } 146 147 ## Broken as of 10/25/06 (undefined symbol _read_toc) 148 #variant cdio { 149 # depends_lib-append port:libcdio 150 # configure.args-delete --disable-libcdio 151 # #configure.args-append --enable-libcdio 152 #} 153 154 variant theora { 150 variant theora \ 151 description {Enable OggTheora support} { 155 152 depends_lib-append port:libtheora 156 153 configure.args-delete --disable-theora 157 154 configure.args-append --enable-theora 158 155 } 159 156 160 variant xvid { 157 variant xvid \ 158 description {Enable XviD encoding} { 161 159 depends_lib-append port:XviD 162 160 configure.args-delete --disable-xvid 163 161 configure.args-append --enable-xvid 164 162 } 165 163 166 164 ## Needs 20070316 snapshot of x264 or later 167 variant x264 { 165 variant x264 \ 166 description {Enable H.264 encoding} { 168 167 depends_lib-append port:x264 169 168 configure.args-delete --disable-x264 170 169 configure.args-append --enable-x264 170 # upstream ./configure broken, fixed in mplayer-svn. 171 post-patch { 172 reinplace "s|if test \"\$_x264\" = yes ; then|if test \"\$_x264\" = yes ; then\\\n _ld_x264=-lx264|g" \ 173 ${worksrcpath}/configure 174 } 171 175 } 172 176 173 177 # binary_codecs replaced 'variant real' 174 variant real requires binary_codecs {} 178 variant real requires binary_codecs \ 179 description {Deprecated: use binary_codecs instead} {} 175 180 176 variant binary_codecs { 181 variant binary_codecs \ 182 description {Enable platform-specific binary codecs} { 177 183 if {[variant_isset darwin_powerpc]} { 178 184 global mplayercodecs mplayercodecsfile 179 185 set mplayercodecs rp9codecs-macosx-20041107.pkg … … 232 238 } 233 239 } 234 240 235 variant speex { 241 variant speex \ 242 description {Enable Speex playback} { 236 243 depends_lib-append port:speex-devel 237 244 configure.args-delete --disable-speex 238 245 #configure.args-append --enable-speex 239 246 } 240 247 241 variant faac { 248 variant faac \ 249 description {Enable AAC encoding} { 242 250 depends_lib-append port:faac 243 251 configure.args-delete --disable-faac 244 252 } 245 253 246 variant dv { 254 variant dv \ 255 description {Enable DV encoding} { 247 256 depends_lib-append port:libdv 248 257 configure.args-delete --disable-libdv 249 258 } 250 259 251 variant twolame { 260 variant twolame \ 261 description {Enable MPEG Audio Layer 2 encoding} { 252 262 depends_lib-append port:twolame 253 263 configure.args-delete --disable-twolame 254 264 } 255 265 256 variant dts { 266 variant dts \ 267 description {Enable non-passthrough DTS playback} { 257 268 depends_lib-append port:libdts 258 269 configure.args-delete --disable-libdts 259 270 } 260 271 261 272 ##### Outputs 262 273 263 variant sdl { 274 variant sdl \ 275 description {Enable SDL video output} { 264 276 depends_lib-append port:libsdl 265 277 configure.args-delete --disable-sdl 266 278 } 267 279 268 variant aa { 280 variant aa \ 281 description {Enable animated ASCII art video output} { 269 282 depends_lib-append port:aalib 270 283 configure.args-delete --disable-aa 271 284 } 272 285 273 variant caca { 286 variant caca \ 287 description {Enable animated ASCII art video output} { 274 288 depends_lib-append port:libcaca 275 289 configure.args-delete --disable-caca 276 290 } 277 291 278 variant x11 requires freetype requires fontconfig{292 variant x11 { 279 293 depends_lib-append lib:libX11.6:XFree86 280 294 configure.args-delete --disable-x11 281 295 configure.env-append PKG_CONFIG_PATH=${prefix}/lib/pkgconfig:${x11prefix}/lib/pkgconfig 282 296 } 283 297 284 variant arts { 298 variant arts \ 299 description {Enable aRts audio output} { 285 300 depends_lib-append port:arts 286 301 configure.args-delete --disable-arts 287 302 } 288 303 289 variant esd { 304 variant esd \ 305 description {Enable EsounD audio output} { 290 306 depends_lib-append port:esound 291 307 configure.args-delete --disable-esd 292 308 }