1 | # $Id$ |
---|
2 | |
---|
3 | # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4 |
---|
4 | |
---|
5 | PortSystem 1.0 |
---|
6 | |
---|
7 | name mplayer-devel |
---|
8 | version 29181 |
---|
9 | revision 0 |
---|
10 | categories multimedia |
---|
11 | maintainers ecronin openmaintainer |
---|
12 | platforms darwin |
---|
13 | |
---|
14 | set dvdnav_ver 1167 |
---|
15 | set ffmpeg_ver 18522 |
---|
16 | |
---|
17 | description MPlayer is a movie player which runs on many systems. |
---|
18 | long_description ${description} It plays most MPEG/VOB, AVI, Ogg/OGM, \ |
---|
19 | VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, \ |
---|
20 | NUT, NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files, \ |
---|
21 | supported by many native, XAnim, and Win32 DLL codecs. \ |
---|
22 | You can watch VideoCD, SVCD, DVD, 3ivx, DivX 3/4/5, WMV \ |
---|
23 | and even H.264 movies. |
---|
24 | homepage http://www.mplayerhq.hu/ |
---|
25 | |
---|
26 | livecheck.check none |
---|
27 | |
---|
28 | depends_build port:pkgconfig port:yasm port:subversion |
---|
29 | depends_lib \ |
---|
30 | port:jpeg port:lame port:libiconv port:libmad \ |
---|
31 | port:libogg port:libpng port:libvorbis port:lzo2 \ |
---|
32 | port:ncurses port:zlib port:bzip2 port:liboil |
---|
33 | |
---|
34 | fetch.type svn |
---|
35 | #svn.tag ${version} |
---|
36 | #svn.url svn://svn.mplayerhq.hu/mplayer/trunk |
---|
37 | worksrcdir trunk |
---|
38 | |
---|
39 | fetch { |
---|
40 | system "svn export -r${version} --ignore-externals svn://svn.mplayerhq.hu/mplayer/trunk ${worksrcpath}/" |
---|
41 | system "svn export -r${dvdnav_ver} svn://svn.mplayerhq.hu/dvdnav/trunk/libdvdnav/src ${worksrcpath}/libdvdnav/" |
---|
42 | system "svn export -r${dvdnav_ver} svn://svn.mplayerhq.hu/dvdnav/trunk/libdvdread/src ${worksrcpath}/libdvdread4/" |
---|
43 | system "svn export -r${ffmpeg_ver} svn://svn.ffmpeg.org/ffmpeg/trunk/libavcodec ${worksrcpath}/libavcodec/" |
---|
44 | system "svn export -r${ffmpeg_ver} svn://svn.ffmpeg.org/ffmpeg/trunk/libavutil ${worksrcpath}/libavutil/" |
---|
45 | system "svn export -r${ffmpeg_ver} svn://svn.ffmpeg.org/ffmpeg/trunk/libavformat ${worksrcpath}/libavformat/" |
---|
46 | system "svn export -r${ffmpeg_ver} svn://svn.ffmpeg.org/ffmpeg/trunk/libpostproc ${worksrcpath}/libpostproc/" |
---|
47 | } |
---|
48 | # Do not use the following environment variables, otherwise the build phase |
---|
49 | # will fail. |
---|
50 | configure.cflags {} |
---|
51 | configure.cppflags {} |
---|
52 | configure.cxxflags {} |
---|
53 | configure.ldflags {} |
---|
54 | |
---|
55 | # Do not use pipes, otherwise the build phase will fail. |
---|
56 | configure.pipe no |
---|
57 | |
---|
58 | configure.args \ |
---|
59 | --datadir=${prefix}/share/${name} \ |
---|
60 | --confdir=${prefix}/etc/${name} \ |
---|
61 | --mandir=${prefix}/share/man \ |
---|
62 | --enable-png --enable-jpeg --enable-liblzo \ |
---|
63 | --enable-libvorbis --enable-mad \ |
---|
64 | --enable-largefiles |
---|
65 | |
---|
66 | configure.args-append \ |
---|
67 | --disable-smb --disable-live --disable-dvdnav \ |
---|
68 | --disable-dvdread --disable-cdparanoia --disable-freetype \ |
---|
69 | --disable-fontconfig --disable-fribidi \ |
---|
70 | --disable-enca --disable-libcdio --disable-xvid \ |
---|
71 | --disable-x264 --disable-speex --disable-theora \ |
---|
72 | --disable-faac --disable-ladspa --disable-libdv \ |
---|
73 | --disable-toolame --disable-twolame --disable-xmms \ |
---|
74 | --disable-musepack --disable-sdl --disable-aa \ |
---|
75 | --disable-caca --disable-x11 --disable-arts \ |
---|
76 | --disable-esd --disable-lirc --disable-mng --disable-libdirac-lavc \ |
---|
77 | --disable-libschroedinger-lavc |
---|
78 | |
---|
79 | post-destroot { |
---|
80 | xinstall -d -m 0755 ${destroot}${prefix}/share/doc/${name} |
---|
81 | eval file copy [glob ${worksrcpath}/DOCS/*] \ |
---|
82 | ${destroot}${prefix}/share/doc/${name} |
---|
83 | xinstall -d -m 0755 ${destroot}${prefix}/etc/${name} |
---|
84 | foreach etcfile {codecs.conf dvb-menu.conf example.conf \ |
---|
85 | input.conf menu.conf} { |
---|
86 | xinstall -m 0644 ${worksrcpath}/etc/${etcfile} \ |
---|
87 | ${destroot}${prefix}/etc/${name}/${etcfile} |
---|
88 | } |
---|
89 | } |
---|
90 | |
---|
91 | universal_variant no |
---|
92 | |
---|
93 | variant man_all_lang \ |
---|
94 | description {Install all possible languages for man pages} { |
---|
95 | configure.args-append --language=all |
---|
96 | } |
---|
97 | |
---|
98 | # Bundle all the font deps into one onscreen display variant |
---|
99 | # Allow autodetect to pick up fontconfig & freetype |
---|
100 | variant osd \ |
---|
101 | description {Enable onscreen display and TrueType font support} { |
---|
102 | depends_lib-append port:fontconfig port:freetype |
---|
103 | configure.args-delete --disable-fontconfig |
---|
104 | configure.args-delete --disable-freetype |
---|
105 | configure.args-append --enable-menu |
---|
106 | } |
---|
107 | |
---|
108 | variant fribidi requires osd \ |
---|
109 | description {Enable FriBidi Unicode support} { |
---|
110 | depends_lib-append port:fribidi |
---|
111 | configure.args-delete --disable-fribidi |
---|
112 | } |
---|
113 | |
---|
114 | variant noappleremote \ |
---|
115 | description {Disable Apple Infrared Remote support} { |
---|
116 | configure.args-append --disable-apple-remote |
---|
117 | } |
---|
118 | |
---|
119 | variant lirc \ |
---|
120 | description {Enable Linux Infrared Remote Daemon support} { |
---|
121 | depends_lib-append port:lirc |
---|
122 | configure.args-delete --disable-lirc |
---|
123 | } |
---|
124 | |
---|
125 | variant live \ |
---|
126 | description {Enable live555 support} { |
---|
127 | depends_lib-append port:live555 |
---|
128 | } |
---|
129 | |
---|
130 | ##### |
---|
131 | |
---|
132 | variant nodvd \ |
---|
133 | description {Disable DVD and DeCSS support} { |
---|
134 | configure.args-append --disable-dvdread-internal --disable-libdvdcss-internal |
---|
135 | } |
---|
136 | |
---|
137 | variant samba description {Enable Samba support} { |
---|
138 | depends_lib-append port:samba3 |
---|
139 | configure.args-append --enable-smb |
---|
140 | configure.args-delete --disable-smb |
---|
141 | } |
---|
142 | |
---|
143 | ##### External codecs |
---|
144 | |
---|
145 | variant theora \ |
---|
146 | description {Enable OggTheora support} { |
---|
147 | depends_lib-append port:libtheora |
---|
148 | configure.args-delete --disable-theora |
---|
149 | configure.args-append --enable-theora |
---|
150 | } |
---|
151 | |
---|
152 | variant xvid \ |
---|
153 | description {Enable XviD encoding} { |
---|
154 | depends_lib-append port:XviD |
---|
155 | configure.args-delete --disable-xvid |
---|
156 | } |
---|
157 | |
---|
158 | variant x264 \ |
---|
159 | description {Enable H.264 encoding} { |
---|
160 | depends_lib-append port:x264 |
---|
161 | configure.args-delete --disable-x264 |
---|
162 | } |
---|
163 | |
---|
164 | variant speex \ |
---|
165 | description {Enable Speex playback} { |
---|
166 | depends_lib-append port:speex-devel |
---|
167 | configure.args-delete --disable-speex |
---|
168 | } |
---|
169 | |
---|
170 | variant faac \ |
---|
171 | description {Enable AAC encoding} { |
---|
172 | depends_lib-append port:faac |
---|
173 | configure.args-delete --disable-faac |
---|
174 | } |
---|
175 | |
---|
176 | variant dv \ |
---|
177 | description {Enable DV encoding} { |
---|
178 | depends_lib-append port:libdv |
---|
179 | configure.args-delete --disable-libdv |
---|
180 | } |
---|
181 | |
---|
182 | variant twolame \ |
---|
183 | description {Enable MPEG Audio Layer 2 encoding} { |
---|
184 | depends_lib-append port:twolame |
---|
185 | configure.args-delete --disable-twolame |
---|
186 | } |
---|
187 | |
---|
188 | variant dts \ |
---|
189 | description {Enable non-passthrough DTS playback} { |
---|
190 | depends_lib-append port:libdts |
---|
191 | configure.args-delete --disable-libdts |
---|
192 | } |
---|
193 | |
---|
194 | variant mng \ |
---|
195 | description {Enable mng codec support} { |
---|
196 | depends_lib-append port:libmng |
---|
197 | configure.args-delete --disable-mng |
---|
198 | } |
---|
199 | |
---|
200 | variant dirac \ |
---|
201 | description {Enable dirac codec support} { |
---|
202 | depends_lib-append port:dirac port:schroedinger |
---|
203 | configure.args-delete --disable-libdirac-lavc |
---|
204 | configure.args-delete --disable-libschroedinger-lavc |
---|
205 | } |
---|
206 | |
---|
207 | ##### Outputs |
---|
208 | |
---|
209 | variant sdl \ |
---|
210 | description {Enable SDL video output} { |
---|
211 | depends_lib-append port:libsdl |
---|
212 | configure.args-delete --disable-sdl |
---|
213 | } |
---|
214 | |
---|
215 | variant aa \ |
---|
216 | description {Enable animated ASCII art video output} { |
---|
217 | depends_lib-append port:aalib |
---|
218 | configure.args-delete --disable-aa |
---|
219 | } |
---|
220 | |
---|
221 | variant caca \ |
---|
222 | description {Enable animated ASCII art video output} { |
---|
223 | depends_lib-append port:libcaca |
---|
224 | configure.args-delete --disable-caca |
---|
225 | } |
---|
226 | |
---|
227 | variant x11 { |
---|
228 | depends_lib-append lib:libX11.6:XFree86 |
---|
229 | configure.args-delete --disable-x11 |
---|
230 | configure.env-append PKG_CONFIG_PATH=${prefix}/lib/pkgconfig:${x11prefix}/lib/pkgconfig |
---|
231 | } |
---|
232 | |
---|
233 | variant arts \ |
---|
234 | description {Enable aRts audio output} { |
---|
235 | depends_lib-append port:arts |
---|
236 | configure.args-delete --disable-arts |
---|
237 | } |
---|
238 | |
---|
239 | variant esd \ |
---|
240 | description {Enable EsounD audio output} { |
---|
241 | depends_lib-append port:esound |
---|
242 | configure.args-delete --disable-esd |
---|
243 | } |
---|
244 | |
---|
245 | platform macosx { |
---|
246 | configure.args-append --enable-macosx --enable-macosx-bundle \ |
---|
247 | --enable-qtx |
---|
248 | } |
---|
249 | |
---|
250 | platform darwin { |
---|
251 | build.env LD=cc |
---|
252 | } |
---|
253 | |
---|
254 | platform darwin 8 { |
---|
255 | # Need to force use of c++ for linking when Xcode 2.2 is used since some |
---|
256 | # bits of libstdc++ are needed during linking |
---|
257 | build.env LD=c++ |
---|
258 | } |
---|