432 lines
8.9 KiB
Text
432 lines
8.9 KiB
Text
# $FreeBSD$
|
|
# $MCom: ports/multimedia/gstreamer-plugins/Makefile.common,v 1.40 2006/04/23 21:40:21 marcus Exp $
|
|
# base
|
|
BASE_GST_ALL_PLUGINS= \
|
|
alsa \
|
|
cdparanoia \
|
|
gnomevfs \
|
|
libvisual \
|
|
ogg \
|
|
pango \
|
|
theora \
|
|
vorbis
|
|
# bad
|
|
BAD_GST_ALL_PLUGINS+= \
|
|
amrwb \
|
|
bz2 \
|
|
directfb \
|
|
divx \
|
|
dts \
|
|
faac \
|
|
faad \
|
|
gsm \
|
|
ivorbis \
|
|
libmms \
|
|
musepack \
|
|
musicbrainz \
|
|
neon \
|
|
sdl \
|
|
soundtouch \
|
|
swfdec \
|
|
xvid \
|
|
wavpack
|
|
# throra
|
|
|
|
# good
|
|
GOOD_GST_ALL_PLUGINS+= \
|
|
aalib \
|
|
annodex \
|
|
cairo \
|
|
cdio \
|
|
dv \
|
|
esd \
|
|
flac \
|
|
gconf \
|
|
gdk_pixbuf \
|
|
hal \
|
|
jpeg \
|
|
ladspa \
|
|
libcaca \
|
|
libpng \
|
|
raw1394 \
|
|
shout2 \
|
|
speex \
|
|
taglib
|
|
# Ugly
|
|
UGLY_GST_ALL_PLUGINS+= \
|
|
a52dec \
|
|
amrnb \
|
|
dvdnav \
|
|
dvdread \
|
|
lame \
|
|
mad \
|
|
mpeg2dec \
|
|
sidplay
|
|
|
|
CONFIG_GST_PLUGINS= gnome_vfs
|
|
GST_ALL_PLUGINS= ${BASE_GST_ALL_PLUGINS} ${BAD_GST_ALL_PLUGINS} \
|
|
${GOOD_GST_ALL_PLUGINS} ${UGLY_ALL_PLUGINS} \
|
|
${CONFIG_GST_PLUGINS}
|
|
|
|
# Disable all plugins by default
|
|
.for d in ${GST_ALL_PLUGINS}
|
|
CONFIGURE_ARGS+= --disable-${d}
|
|
.endfor
|
|
CONFIGURE_ARGS+= --enable-${GST_PLUGIN}
|
|
|
|
CONFIGURE_ARGS+=--disable-tests \
|
|
--disable-examples \
|
|
--disable-amrnb \
|
|
--disable-alsa \
|
|
--disable-http \
|
|
--enable-cdrom \
|
|
--disable-gconf \
|
|
--disable-gconftool \
|
|
--disable-schemas-install \
|
|
--enable-oss \
|
|
--disable-osx_audio \
|
|
--disable-osx_video \
|
|
--disable-tarkin \
|
|
--enable-static \
|
|
--disable-sunaudio \
|
|
--disable-gst_v4l \
|
|
--disable-gst_v4l2 \
|
|
--disable-xine \
|
|
--enable-x \
|
|
--enable-xshm \
|
|
--enable-xvideo
|
|
|
|
# spc is broken a the moment
|
|
#.if (${ARCH} == "i386")
|
|
#BUILD_DEPENDS+= nasm:${PORTSDIR}/devel/nasm
|
|
#CONFIGURE_ARGS+=--enable-spc
|
|
#PLIST_SUB+= SPC=""
|
|
#.else
|
|
CONFIGURE_ARGS+=--disable-spc
|
|
PLIST_SUB+= SPC="@comment "
|
|
#.endif
|
|
|
|
.if ${GST_PLUGIN}!="base" && !defined(NO_GSTREAMER_COMMON)
|
|
GST_PLUGIN_SUFFIX?= -${GST_PLUGIN}
|
|
|
|
COMMENT= Gstreamer ${GST_PLUGIN} plugin
|
|
|
|
# Enable the right plugin
|
|
|
|
CONFIGURE_ARGS:=${CONFIGURE_ARGS:S|--disable-${GST_PLUGIN}|--enable-${GST_PLUGIN}|}
|
|
|
|
# Build/Install directory. defaults to ext/${GST_PLUGIN}
|
|
# few plugins are in sys/
|
|
GST_PLUGIN_DIR?= ext/${GST_PLUGIN}
|
|
|
|
#
|
|
GST_LIB_DIR= lib/gstreamer-${VERSION}
|
|
|
|
# Auto create PLIST
|
|
PLIST= ${NONEXISTENT}
|
|
PLIST_FILES?= ${GST_LIB_DIR}/libgst${GST_PLUGIN}${GST_PLIST_SUFFIX}.so \
|
|
${GST_LIB_DIR}/libgst${GST_PLUGIN}${GST_PLIST_SUFFIX}.a \
|
|
${GST_LIB_DIR}/libgst${GST_PLUGIN}${GST_PLIST_SUFFIX}.la
|
|
|
|
# hack around WRKSRC stuff near the top... fix me
|
|
DIST?= good
|
|
|
|
# a52dec
|
|
.if ${GST_PLUGIN}=="a52dec"
|
|
LIB_DEPENDS+= a52.0:${PORTSDIR}/audio/liba52
|
|
DIST= ugly
|
|
.endif
|
|
|
|
# aalib
|
|
.if ${GST_PLUGIN}=="aalib"
|
|
LIB_DEPENDS+= aa.1:${PORTSDIR}/graphics/aalib
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstaasink.so \
|
|
${GST_LIB_DIR}/libgstaasink.a \
|
|
${GST_LIB_DIR}/libgstaasink.la
|
|
.endif
|
|
|
|
# cairo
|
|
.if ${GST_PLUGIN}=="cairo"
|
|
LIB_DEPENDS+= cairo.2:${PORTSDIR}/graphics/cairo
|
|
.endif
|
|
|
|
# cdparanoia
|
|
.if ${GST_PLUGIN}=="cdparanoia"
|
|
LIB_DEPENDS+= cdda_interface.0:${PORTSDIR}/audio/cdparanoia
|
|
EXTRA_LIBS+= -lgstcdda-${VERSION}
|
|
DIST= base
|
|
.endif
|
|
|
|
# dts
|
|
.if ${GST_PLUGIN}=="dts"
|
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libdts.a:${PORTSDIR}/multimedia/libdts
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstdtsdec.a \
|
|
${GST_LIB_DIR}/libgstdtsdec.la \
|
|
${GST_LIB_DIR}/libgstdtsdec.so
|
|
DIST= bad
|
|
.endif
|
|
|
|
# dv
|
|
.if ${GST_PLUGIN}=="dv"
|
|
LIB_DEPENDS+= dv.4:${PORTSDIR}/multimedia/libdv
|
|
.endif
|
|
|
|
.if ${GST_PLUGIN}=="dvd"
|
|
EXTRA_LIBS+= -ldvdnav
|
|
LIB_DEPENDS+= dvdnav.4:${PORTSDIR}/multimedia/libdvdnav
|
|
GST_PLUGIN_DIR= ext/dvdnav \
|
|
ext/dvdread
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstdvdnav.a \
|
|
${GST_LIB_DIR}/libgstdvdnav.la \
|
|
${GST_LIB_DIR}/libgstdvdnav.so \
|
|
${GST_LIB_DIR}/libgstdvdread.a \
|
|
${GST_LIB_DIR}/libgstdvdread.la \
|
|
${GST_LIB_DIR}/libgstdvdread.so
|
|
DIST= ugly
|
|
.endif
|
|
|
|
|
|
# esound
|
|
.if ${GST_PLUGIN}=="esound"
|
|
USE_GNOME+= esound
|
|
GST_PLUGIN_DIR= ext/esd
|
|
CONFIGURE_ENV+= ESD_CFLAGS="`pkg-config --cflags esound`" \
|
|
ESD_LIBS="`pkg-config --libs esound`"
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstesd.so \
|
|
${GST_LIB_DIR}/libgstesd.a \
|
|
${GST_LIB_DIR}/libgstesd.la
|
|
.endif
|
|
|
|
# faac
|
|
.if ${GST_PLUGIN}=="faac"
|
|
LIB_DEPENDS+= faac.0:${PORTSDIR}/audio/faac
|
|
DIST= bad
|
|
.endif
|
|
|
|
# faad
|
|
.if ${GST_PLUGIN}=="faad"
|
|
LIB_DEPENDS+= faad.0:${PORTSDIR}/audio/faad
|
|
DIST= bad
|
|
.endif
|
|
|
|
# flac
|
|
.if ${GST_PLUGIN}=="flac"
|
|
LIB_DEPENDS+= FLAC.7:${PORTSDIR}/audio/flac
|
|
.endif
|
|
|
|
# gconf
|
|
.if ${GST_PLUGIN}=="gconf"
|
|
USE_GNOME+= gconf2
|
|
GST_PLUGIN_DIR= ext/gconf \
|
|
gconf
|
|
GCONF_SCHEMAS= gstreamer-${GST_VERSION}.schemas
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstgconfelements.so \
|
|
${GST_LIB_DIR}/libgstgconfelements.a \
|
|
${GST_LIB_DIR}/libgstgconfelements.la
|
|
.endif
|
|
|
|
# gnomevfs
|
|
.if ${GST_PLUGIN}=="gnomevfs"
|
|
USE_GNOME+= gnomevfs2
|
|
CONFIGURE_ARGS+=--enable-gnome_vfs
|
|
DIST= base
|
|
.endif
|
|
|
|
# gsm
|
|
.if ${GST_PLUGIN}=="gsm"
|
|
LIB_DEPENDS+= gsm.1:${PORTSDIR}/audio/gsm
|
|
DIST= bad
|
|
.endif
|
|
|
|
# ivorbis
|
|
.if ${GST_PLUGIN}=="ivorbis"
|
|
LIB_DEPENDS+= vorbisidec.1:${PORTSDIR}/audio/libtremor
|
|
DIST= bad
|
|
.endif
|
|
|
|
# hal
|
|
.if ${GST_PLUGIN}=="hal"
|
|
LIB_DEPENDS+= hal.1:${PORTSDIR}/sysutils/hal
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgsthalelements.a \
|
|
${GST_LIB_DIR}/libgsthalelements.la \
|
|
${GST_LIB_DIR}/libgsthalelements.so
|
|
|
|
.endif
|
|
|
|
# jpeg
|
|
.if ${GST_PLUGIN}=="jpeg"
|
|
LIB_DEPENDS+= jpeg.9:${PORTSDIR}/graphics/jpeg
|
|
.endif
|
|
|
|
# ladspa
|
|
.if ${GST_PLUGIN}=="ladspa"
|
|
BUILD_DEPENDS+= ${LOCALBASE}/include/ladspa.h:${PORTSDIR}/audio/ladspa
|
|
.endif
|
|
|
|
# lame
|
|
.if ${GST_PLUGIN}=="lame"
|
|
LIB_DEPENDS+= mp3lame.0:${PORTSDIR}/audio/lame
|
|
DIST= ugly
|
|
.endif
|
|
|
|
# libcaca
|
|
.if ${GST_PLUGIN}=="libcaca"
|
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcaca.a:${PORTSDIR}/graphics/libcaca
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstcacasink.so \
|
|
${GST_LIB_DIR}/libgstcacasink.a \
|
|
${GST_LIB_DIR}/libgstcacasink.la
|
|
.endif
|
|
|
|
# libmms
|
|
.if ${GST_PLUGIN}=="libmms"
|
|
LIB_DEPENDS+= mms.0:${PORTSDIR}/net/libmms
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstmms.so \
|
|
${GST_LIB_DIR}/libgstmms.a \
|
|
${GST_LIB_DIR}/libgstmms.la
|
|
DIST= bad
|
|
.endif
|
|
|
|
# libpng and the snapshot plugin
|
|
.if ${GST_PLUGIN}=="libpng"
|
|
LIB_DEPENDS+= png.5:${PORTSDIR}/graphics/png
|
|
GST_PLUGIN_DIR= ext/libpng
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstpng.so \
|
|
${GST_LIB_DIR}/libgstpng.a \
|
|
${GST_LIB_DIR}/libgstpng.la
|
|
.endif
|
|
|
|
# libvisual
|
|
.if ${GST_PLUGIN}=="libvisual"
|
|
LIB_DEPENDS+= visual.0:${PORTSDIR}/graphics/libvisual
|
|
DIST= base
|
|
.if ${OSVERSION} < 500000
|
|
BROKEN= Does not build on 4.x
|
|
.endif
|
|
.endif
|
|
|
|
# mad
|
|
.if ${GST_PLUGIN}=="mad"
|
|
LIB_DEPENDS+= mad.2:${PORTSDIR}/audio/libmad \
|
|
id3tag.0:${PORTSDIR}/audio/libid3tag
|
|
DIST= ugly
|
|
.endif
|
|
|
|
# mpeg2dec
|
|
.if ${GST_PLUGIN}=="mpeg2dec"
|
|
LIB_DEPENDS+= mpeg2.0:${PORTSDIR}/multimedia/libmpeg2
|
|
DIST= ugly
|
|
.endif
|
|
|
|
# musepack
|
|
.if ${GST_PLUGIN}=="musepack"
|
|
LIB_DEPENDS+= mpcdec.4:${PORTSDIR}/audio/libmpcdec
|
|
DIST= bad
|
|
.endif
|
|
|
|
# musicbrainz
|
|
.if ${GST_PLUGIN}=="musicbrainz"
|
|
LIB_DEPENDS+= musicbrainz.4:${PORTSDIR}/audio/libmusicbrainz
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgsttrm.so \
|
|
${GST_LIB_DIR}/libgsttrm.a \
|
|
${GST_LIB_DIR}/libgsttrm.la
|
|
DIST= bad
|
|
.endif
|
|
|
|
# ogg
|
|
.if ${GST_PLUGIN}=="ogg"
|
|
LIB_DEPENDS+= ogg.5:${PORTSDIR}/audio/libogg
|
|
EXTRA_LIBS+= -lgstriff-${VERSION}
|
|
DIST= base
|
|
.endif
|
|
|
|
# pango
|
|
.if ${GST_PLUGIN}=="pango"
|
|
USE_GNOME+= pango
|
|
DIST= base
|
|
.endif
|
|
|
|
# sdl
|
|
.if ${GST_PLUGIN}=="sdl"
|
|
USE_SDL+= sdl
|
|
GST_PLIST_SUFFIX= videosink
|
|
DIST= bad
|
|
.endif
|
|
|
|
# shout2
|
|
.if ${GST_PLUGIN}=="shout2"
|
|
LIB_DEPENDS+= shout.5:${PORTSDIR}/audio/libshout2
|
|
.endif
|
|
|
|
# sidplay
|
|
.if ${GST_PLUGIN}=="sidplay"
|
|
LIB_DEPENDS+= sidplay.1:${PORTSDIR}/audio/libsidplay
|
|
PLIST_FILES= ${GST_LIB_DIR}/libgstsid.so \
|
|
${GST_LIB_DIR}/libgstsid.a \
|
|
${GST_LIB_DIR}/libgstsid.la
|
|
DIST= ugly
|
|
.endif
|
|
|
|
# speex
|
|
.if ${GST_PLUGIN}=="speex"
|
|
LIB_DEPENDS+= speex.3:${PORTSDIR}/audio/speex
|
|
.endif
|
|
|
|
# theora
|
|
.if ${GST_PLUGIN}=="theora"
|
|
LIB_DEPENDS+= theora.2:${PORTSDIR}/multimedia/libtheora
|
|
DIST= base
|
|
.endif
|
|
|
|
# vorbis
|
|
.if ${GST_PLUGIN}=="vorbis"
|
|
USE_GSTREAMER+= ogg
|
|
LIB_DEPENDS+= vorbis.3:${PORTSDIR}/audio/libvorbis
|
|
EXTRA_LIBS+= -lgsttag-${VERSION} -lgstaudio-${VERSION}
|
|
DIST= base
|
|
.endif
|
|
|
|
# xvid
|
|
.if ${GST_PLUGIN}=="xvid"
|
|
LIB_DEPENDS+= xvidcore.4:${PORTSDIR}/multimedia/xvid
|
|
DIST= bad
|
|
.endif
|
|
|
|
# wavpack
|
|
.if ${GST_PLUGIN}=="wavpack"
|
|
LIB_DEPENDS+= wavpack.0:${PORTSDIR}/audio/wavpack
|
|
DIST= bad
|
|
.endif
|
|
|
|
.if ${DIST}=="base"
|
|
EXTRACT_ONLY=${BASE_DISTFILE}
|
|
WRKSRC=${WRKDIR}/${BASE_DISTNAME}
|
|
.elif ${DIST}=="bad"
|
|
EXTRACT_ONLY=${BAD_DISTFILE}
|
|
WRKSRC=${WRKDIR}/${BAD_DISTNAME}
|
|
.elif ${DIST}=="ugly"
|
|
EXTRACT_ONLY=${UGLY_DISTFILE}
|
|
WRKSRC=${WRKDIR}/${UGLY_DISTNAME}
|
|
.else
|
|
EXTRACT_ONLY=${GOOD_DISTFILE}
|
|
WRKSRC=${WRKDIR}/${GOOD_DISTNAME}
|
|
.endif
|
|
|
|
BUILD_DEPENDS+= gstreamer-plugins>=${GST_VERSION}${GST_MINOR_VERSION}:${PORTSDIR}/multimedia/gstreamer-plugins
|
|
RUN_DEPENDS+= gstreamer-plugins>=${GST_VERSION}${GST_MINOR_VERSION}:${PORTSDIR}/multimedia/gstreamer-plugins
|
|
|
|
.if !target(do-build)
|
|
do-build:
|
|
.for dir in ${GST_PREBUILD_DIR} ${GST_PLUGIN_DIR} ${GST_POSTBUILD_DIR}
|
|
@cd ${WRKSRC}/${dir}; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} \
|
|
${MAKEFILE} ${MAKE_ARGS} ${ALL_TARGET}
|
|
.endfor
|
|
.endif
|
|
|
|
.if !target(do-install)
|
|
do-install:
|
|
.for dir in ${GST_PLUGIN_DIR}
|
|
@cd ${WRKSRC}/${dir}; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} \
|
|
${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET}
|
|
.endfor
|
|
.endif
|
|
.endif
|