4 # bsd.gstreamer.mk - Support for gstreamer-plugins-based ports.
6 # Created by: Michael Johnson <ahze@FreeBSD.org>
9 # $MCom: ports/Mk/bsd.gstreamer.mk,v 1.56 2013/01/15 21:43:45 kwm Exp $
11 .if !defined(_POSTMKINCLUDED) && !defined(Gstreamer_Pre_Include)
13 Gstreamer_Include_MAINTAINER= multimedia@FreeBSD.org
14 Gstreamer_Pre_Include= bsd.gstreamer.mk
18 # Ports can use the following:
21 # USE_GSTREAMER= lame faac ffmpeg
23 # For Gstreamer 1.x the same rules apply but instead of
24 # USE_GSTREAMER=, USE_GSTREAMER1= is used.
26 # If you want to use USE_GSTREAMER after <bsd.port.pre.mk>
27 # you must follow one of the examples listed below
29 # .include <bsd.port.options.mk>
30 # .if defined(WITH_VORBIS)
31 # USE_GSTREAMER= vorbis
36 # .include <bsd.port.options.mk>
37 # .if defined(WITH_FAAD)
38 # USE_GSTREAMER+= faad
40 # .include <bsd.port.pre.mk>
42 # USE_GSTREAMER=yes will always add a dependency to
45 # The use of WANT_GSTREAMER=yes should be discouraged.
47 # "Normal" dependencies and variables
50 GSTREAMER_PORT= ${PORTSDIR}/multimedia/gstreamer-plugins
51 _GST_LIB_BASE= ${LOCALBASE}/lib/gstreamer-${GST_VERSION}
56 GSTREAMER1_PORT= ${PORTSDIR}/multimedia/gstreamer1-plugins
57 _GST1_LIB_BASE= ${LOCALBASE}/lib/gstreamer-${GST1_VERSION}
59 GST1_MINOR_VERSION= .0
61 GST1_MINIMAL_VERSION= .0
64 # missing base: alsa ivorbisdec
65 # missing good: pulseaudio(need newer pulse version)
69 # These are the current supported gstreamer-plugins modules:
70 # Supported plugins by both 0.10 and 1.0.
72 a52dec aalib amrnb amrwbdec cairo cdio \
73 cdparanoia dts dv faac faad flac flite \
74 gdkpixbuf gme gnonlin gsm jack jpeg lame libcaca \
75 libmms libvisual mad mpeg2dec mpeg2enc neon ogg \
76 opencv opus pango resindvd schroedinger \
77 shout2 sidplay soundtouch soup speex taglib \
78 theora twolame v4l2 vorbis wavpack x264
80 # plugins only in 0.10
81 .if defined(USE_GSTREAMER)
82 _GSTREAMER_PLUGINS+= \
83 annodex bz2 cdaudio dvd esound ffmpeg fluendo-mp3 \
84 fluendo-mpegdemux gconf gio gl gnomevfs hal \
85 ladspa libpng mm mp3 musepack nas pulse python qt4 \
86 sdl sndfile spc vdpau vp8 xvid
90 .if defined(USE_GSTREAMER1)
91 _GSTREAMER_PLUGINS+= \
92 assrender curl dvdread kate libav modplug openjpeg png rtmp \
93 spandsp vpx webp x ximagesrc zbar
98 _USE_GSTREAMER_ALL= bad core good ugly yes ${_GSTREAMER_PLUGINS}
100 #--------------------------------------------------------------------------#
102 core_DEPENDS= multimedia/gstreamer-plugins-core
104 yes_DEPENDS= multimedia/gstreamer-plugins
105 yes_NAME= gstreamer-plugins
106 yes_NAME10= gstreamer1-plugins
107 yes_GST_PREFIX= # empty
109 #-- audio plugins section -------------------------------------------------#
111 # Audio Plugins Section
112 a52dec_DEPENDS= audio/gstreamer-plugins-a52dec
114 amrnb_DEPENDS= audio/gstreamer-plugins-amrnb
116 amrwbdec_DEPENDS= audio/gstreamer-plugins-amrwbdec
118 artsd_DEPENDS= audio/gstreamer-plugins-artsd
120 audiofile_DEPENDS= audio/gstreamer-plugins-audiofile
122 cdaudio_DEPENDS= audio/gstreamer-plugins-cdaudio
124 cdparanoia_DEPENDS= audio/gstreamer-plugins-cdparanoia
126 esound_DEPENDS= audio/gstreamer-plugins-esound
128 faac_DEPENDS= audio/gstreamer-plugins-faac
130 faad_DEPENDS= audio/gstreamer-plugins-faad
132 flac_DEPENDS= audio/gstreamer-plugins-flac
134 flite_DEPENDS= audio/gstreamer-plugins-flite
136 fluendo-mp3_DEPENDS= audio/gstreamer-plugins-fluendo-mp3
138 gme_DEPENDS= audio/gstreamer-plugins-gme
140 gsm_DEPENDS= audio/gstreamer-plugins-gsm
142 hal_DEPENDS= sysutils/gstreamer-plugins-hal
144 jack_DEPENDS= audio/gstreamer-plugins-jack
146 ladspa_DEPENDS= audio/gstreamer-plugins-ladspa
148 lame_DEPENDS= audio/gstreamer-plugins-lame
150 mad_DEPENDS= audio/gstreamer-plugins-mad
152 mikmod_DEPENDS= audio/gstreamer-plugins-mikmod
154 modplug_DEPENDS= audio/gstreamer-plugins-modplug
156 mp3_DEPENDS= audio/gstreamer-plugins-mp3
158 musepack_DEPENDS= audio/gstreamer-plugins-musepack
160 nas_DEPENDS= audio/gstreamer-plugins-nas
162 neon_DEPENDS= www/gstreamer-plugins-neon
164 ogg_DEPENDS= audio/gstreamer-plugins-ogg
166 opus_DEPENDS= audio/gstreamer-plugins-opus
168 polyp_DEPENDS= audio/gstreamer-plugins-polyp
170 pulse_DEPENDS= audio/gstreamer-plugins-pulse
172 shout_DEPENDS= audio/gstreamer-plugins-shout
174 shout2_DEPENDS= audio/gstreamer-plugins-shout2
176 sidplay_DEPENDS= audio/gstreamer-plugins-sidplay
178 smoothwave_DEPENDS= audio/gstreamer-plugins-smoothwave
180 sndfile_DEPENDS= audio/gstreamer-plugins-sndfile
182 soundtouch_DEPENDS= audio/gstreamer-plugins-soundtouch
184 spc_DEPENDS= audio/gstreamer-plugins-spc
186 speex_DEPENDS= audio/gstreamer-plugins-speex
188 taglib_DEPENDS= audio/gstreamer-plugins-taglib
190 twolame_DEPENDS= audio/gstreamer-plugins-twolame
192 vorbis_DEPENDS= audio/gstreamer-plugins-vorbis
194 wavpack_DEPENDS= audio/gstreamer-plugins-wavpack
196 #-- comms plugin section --------------------------------------------------#
198 spandsp_DEPENDS= comms/gstreamer-plugins-spandsp
200 #-- devel plugin section --------------------------------------------------#
202 gconf_DEPENDS= devel/gstreamer-plugins-gconf
204 gio_DEPENDS= devel/gstreamer-plugins-gio
206 gnomevfs_DEPENDS= devel/gstreamer-plugins-gnomevfs
208 sdl_DEPENDS= devel/gstreamer-plugins-sdl
210 soup_DEPENDS= devel/gstreamer-plugins-soup
212 #-- ftp plugin section ----------------------------------------------------#
214 curl_DEPENDS= ftp/gstreamer-plugins-curl
216 #-- graphics plugin section -----------------------------------------------#
218 aalib_DEPENDS= graphics/gstreamer-plugins-aalib
220 annodex_DEPENDS= multimedia/gstreamer-plugins-annodex
222 assrender_DEPENDS= multimedia/gstreamer-plugins-assrender
224 cairo_DEPENDS= graphics/gstreamer-plugins-cairo
226 gdkpixbuf_DEPENDS= graphics/gstreamer-plugins-gdkpixbuf
228 gl_DEPENDS= graphics/gstreamer-plugins-gl
230 hermes_DEPENDS= graphics/gstreamer-plugins-hermes
232 jpeg_DEPENDS= graphics/gstreamer-plugins-jpeg
234 libcaca_DEPENDS= graphics/gstreamer-plugins-libcaca
236 libmng_DEPENDS= graphics/gstreamer-plugins-libmng
238 libpng_DEPENDS= graphics/gstreamer-plugins-libpng
240 libvisual_DEPENDS= graphics/gstreamer-plugins-libvisual
242 opencv_DEPENDS= graphics/gstreamer-plugins-opencv
244 openjpeg_DEPENDS= graphics/gstreamer-plugins-openjpeg
246 png_DEPENDS= graphics/gstreamer-plugins-png
248 webp_DEPENDS= graphics/gstreamer-plugins-webp
250 zbar_DEPENDS= graphics/gstreamer-plugins-zbar
252 #-- multimedia plugins section --------------------------------------------#
254 bad_DEPENDS= multimedia/gstreamer-plugins-bad
256 bz2_DEPENDS= multimedia/gstreamer-plugins-bz2
258 dvdread_DEPENDS= multimedia/gstreamer-plugins-dvdread
260 ffmpeg_DEPENDS= multimedia/gstreamer-ffmpeg
261 ffmpeg_GST_PREFIX= gstreamer-
262 ffmpeg_GST_SUFX= # empty
263 ffmpeg_GST_VERSION= 0.10.0
265 fluendo-mpegdemux_DEPENDS= multimedia/gstreamer-plugins-fluendo-mpegdemux
267 dts_DEPENDS= multimedia/gstreamer-plugins-dts
269 dv_DEPENDS= multimedia/gstreamer-plugins-dv
271 dvd_DEPENDS= multimedia/gstreamer-plugins-dvd
273 good_DEPENDS= multimedia/gstreamer-plugins-good
275 gnonlin_DEPENDS= multimedia/gstreamer-plugins-gnonlin
277 kate_DEPENDS= multimedia/gstreamer-plugins-kate
279 libav_DEPENDS= multimedia/gstreamer-libav
280 libav_GST_PREFIX= gstreamer1-
281 libav_GST_SUFX= # empty
282 libav_GST_VERSION= 1.0.0
284 libfame_DEPENDS= multimedia/gstreamer-plugins-libfame
286 mm_DEPENDS= multimedia/gstreamermm
287 mm_GST_PREFIX= gstreamer
289 mm_GST_VERSION= 0.9.4
291 mpeg2dec_DEPENDS= multimedia/gstreamer-plugins-mpeg2dec
293 mpeg2enc_DEPENDS= multimedia/gstreamer-plugins-mpeg2enc
295 mplex_DEPENDS= multimedia/gstreamer-plugins-mplex
297 qt4_DEPENDS= multimedia/gstreamer-qt4
298 qt4_GST_PREFIX= gstreamer-
300 rtmp_DEPENDS= multimedia/gstreamer1-plugins-rtmp
302 v4l2_DEPENDS= multimedia/gstreamer-plugins-v4l2
304 vaapi_DEPENDS= multimedia/gstreamer-plugins-vaapi
306 vp8_DEPENDS= multimedia/gstreamer-plugins-vp8
308 vpx_DEPENDS= multimedia/gstreamer-plugins-vpx
310 # XXX: This is a quick solution for ports with USE_GSTREAMER=python
311 # but without USE_PYTHON.
312 PYTHON_PKGNAMEPREFIX?= py*-
314 python_DEPENDS= multimedia/py-gstreamer
315 python_NAME= gstreamer
316 python_GST_PREFIX= ${PYTHON_PKGNAMEPREFIX}
317 python_GST_SUFX= # empty
318 python_GST_VERSION= 0.10.4
320 resindvd_DEPENDS= multimedia/gstreamer-plugins-resindvd
322 schroedinger_DEPENDS= multimedia/gstreamer-plugins-schroedinger
324 theora_DEPENDS= multimedia/gstreamer-plugins-theora
326 ugly_DEPENDS= multimedia/gstreamer-plugins-ugly
328 vdpau_DEPENDS= multimedia/gstreamer-plugins-vdpau
330 x264_DEPENDS= multimedia/gstreamer-plugins-x264
332 xvid_DEPENDS= multimedia/gstreamer-plugins-xvid
335 #-- Net Plugins Section ---------------------------------------------------#
337 libmms_DEPENDS= net/gstreamer-plugins-libmms
339 #-- sysutils plugins section ----------------------------------------------#
341 cdio_DEPENDS= sysutils/gstreamer-plugins-cdio
343 #-- x11 plugins section ---------------------------------------------------#
345 x_DEPENDS= x11/gstreamer-plugins-x
347 ximagesrc_DEPENDS= x11/gstreamer-plugins-ximagesrc
349 #-- x11-toolkits plugins section ------------------------------------------#
351 pango_DEPENDS= x11-toolkits/gstreamer-plugins-pango
353 #--------------------------------------------------------------------------#
355 .if defined(_POSTMKINCLUDED) && !defined(Gstreamer_Post_Include)
356 Gstreamer_Post_Include= bsd.gstreamer.mk
358 .if (defined (USE_GSTREAMER) && defined(USE_GSTREAMER1))
359 IGNORE= USE_GSTREAMER and USE_GSTREAMER1 can't be used together
362 .if defined(USE_GSTREAMER)
363 .for ext in ${USE_GSTREAMER}
364 ${ext}_GST_PREFIX?= gstreamer-plugins-
365 ${ext}_GST_VERSION?= ${GST_VERSION}${GST_MINOR_VERSION}
367 . if ${_USE_GSTREAMER_ALL:M${ext}}!= "" && exists(${PORTSDIR}/${${ext}_DEPENDS})
368 BUILD_DEPENDS+= ${${ext}_GST_PREFIX}${${ext}_NAME}>=${${ext}_GST_VERSION}:${PORTSDIR}/${${ext}_DEPENDS}
369 RUN_DEPENDS+= ${${ext}_GST_PREFIX}${${ext}_NAME}>=${${ext}_GST_VERSION}:${PORTSDIR}/${${ext}_DEPENDS}
371 IGNORE= cannot install: unknown gstreamer ${GST_VERSION} plugin -- ${ext}
376 .if defined(USE_GSTREAMER1)
377 .for ext in ${USE_GSTREAMER1}
378 ${ext}_GST_PREFIX?= gstreamer1-plugins-
379 ${ext}_GST_VERSION?= ${GST1_VERSION}${GST1_MINIMAL_VERSION}
380 ${ext}_NAME10?= ${ext}
381 ${ext}_GST_DEPENDS?= ${${ext}_DEPENDS:S,gstreamer-,gstreamer1-,}
382 . if ${_USE_GSTREAMER_ALL:M${ext}}!= "" && exists(${PORTSDIR}/${${ext}_GST_DEPENDS})
383 BUILD_DEPENDS+= ${${ext}_GST_PREFIX}${${ext}_NAME10}>=${${ext}_GST_VERSION}:${PORTSDIR}/${${ext}_GST_DEPENDS}
384 RUN_DEPENDS+= ${${ext}_GST_PREFIX}${${ext}_NAME10}>=${${ext}_GST_VERSION}:${PORTSDIR}/${${ext}_GST_DEPENDS}
386 IGNORE= cannot install: unknown gstreamer ${GST1_VERSION} plugin -- ${ext}