summaryrefslogblamecommitdiffstats
path: root/multimedia/gstreamer-plugins/Makefile.common
blob: 16d9df3e3a6e1973a7200aadae4506e0de603d2a (plain) (tree)
1
2
3
4
5
6
7
8
9





                           
                          

                           
                       
                         










                            












                            
                            
                        
                        




                           
                               


                          
                          


                             
                        
                       

                        












                            












                                      
                                
                                



                                     
                                 

                                   




































                                                                        




                                                  








































                                                                              
                     

















                                             




                                                      









                                                        






















































                                                                       
                        











                                                         


                                                   
                                           

      


                                                 
                                           








































                                                               
                                                         











































                                                                 






                                                        

















                                               
                                                        





























                                                                                             
                                                                         

                                                                                                   




                                                                                                







                                                                            
GST_ALL_PLUGINS= \
        a52dec \
        aalib \
        aalibtest \
        alsa \
        arts \
        artstest \
        artsc \
        audiofile \
        cairo \
        cdaudio \
        cdparanoia \
        dirac \
        divx \
        dts \
        dvdnav \
        dvdread \
        dxr3 \
        esd \
        faac \
        faad \
        flac \
        gdk_pixbuf \
        gnome_vfs \
        gsm \
        hermes \
        ivorbis \
        jack \
        jpeg \
        ladspa \
        lame \
        lcs \
        libcaca \
        libdv \
        libfame \
        libfametest\
        libmng \
        libmms \
        libpng \
        librfb \
        libvisual \
        mad \
        mikmod \
        libmikmodtest \
        mpeg2dec \
        mpeg2enc \
        mplex \
        musepack \
        musicbrainz \
        nas \
        ogg \
        opengl \
        pango \
        polyp \
        dv1394 \
        qcam \
        raw1394 \
        sdl \
        shout \
        shout2 \
        sidplay \
        smoothwave \
        sndfile \
        sunaudio \
        speex \
        swfdec \
        tarkin \
        theora \
        vcd \
        vorbis \
        xine \
        xvid

# Disable all plugins by default\
.for d in ${GST_ALL_PLUGINS}
CONFIGURE_ARGS+=    --disable-${d}
.endfor

CONFIGURE_ARGS+=--disable-tests \
        --disable-alsa \
        --disable-http \
        --enable-cdrom \
        --enable-gconf \
        --enable-gconftool \
        --enable-oss \
        --disable-osx_audio \
        --disable-osx_video \
        --enable-static \
        --enable-gst_v4l \
        --enable-gst_v4l2 \
        --enable-x \
        --enable-xshm \
        --enable-xvideo

.if ${GST_PLUGIN}!="base"

GST_PLUGIN_SUFFIX?= -${GST_PLUGIN}

COMMENT=    Gstreamer ${GST_PLUGIN} plugin

# Enable the right plugin

CONFIGURE_ARGS:=${CONFIGURE_ARGS:S|--disable-${p}|--enable-${p}|}

# 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

# aalib
.if ${GST_PLUGIN}=="aalib"
LIB_DEPENDS+=   aa.1:${PORTSDIR}/graphics/aalib
PLIST_FILES=    ${GST_LIB_DIR}/libgstaasink.so
.endif

# artsd
.if ${GST_PLUGIN}=="artsd"
LIB_DEPENDS+=   artsc.0:${PORTSDIR}/audio/arts
GST_PLIST_SUFFIX=   sink
.endif

# cairo
.if ${GST_PLUGIN}=="cairo"
LIB_DEPENDS+=   cairo.1:${PORTSDIR}/graphics/cairo
.endif

# cdparanoia
.if ${GST_PLUGIN}=="cdparanoia"
LIB_DEPENDS+=   cdda_interface.0:${PORTSDIR}/audio/cdparanoia
.endif

# dirac
.if ${GST_PLUGIN}=="dirac"
BUILD_DEPENDS+= ${LOCALBASE}/lib/libconv_common.a:${PORTSDIR}/multimedia/dirac
.endif

# dts
.if ${GST_PLUGIN}=="dts"
BUILD_DEPENDS+= ${LOCALBASE}/lib/libdts_pic.a:${PORTSDIR}/multimedia/libdts
RUN_DEPENDS+=   ${LOCALBASE}/lib/libdts_pic.a:${PORTSDIR}/multimedia/libdts
GST_PLIST_SUFFIX=   dec
.endif

# esound
.if ${GST_PLUGIN}=="esound"
USE_GNOME+= esound
GST_PLUGIN_DIR= ext/esd
PLIST_FILES=    ${GST_LIB_DIR}/libgstesd.so
.endif

# faac
.if ${GST_PLUGIN}=="faac"
LIB_DEPENDS+=   faac.0:${PORTSDIR}/audio/faac
.endif

# faad
.if ${GST_PLUGIN}=="faad"
LIB_DEPENDS+=   faad.0:${PORTSDIR}/audio/faad
.endif

# flac
.if ${GST_PLUGIN}=="flac"
LIB_DEPENDS+=   FLAC.5:${PORTSDIR}/audio/flac
.endif

# gdkpixbuf
.if ${GST_PLUGIN}=="gdkpixbuf"
USE_GNOME+= gtk20
GST_PLUGIN_DIR= ext/gdk_pixbuf
.endif

# gnomevfs
.if ${GST_PLUGIN}=="gnomevfs"
USE_GNOME+= gnomevfs2
.endif

# gsm
.if ${GST_PLUGIN}=="gsm"
LIB_DEPENDS+=   gsm.1:${PORTSDIR}/audio/gsm
.endif

# jack
.if ${GST_PLUGIN}=="jack"
LIB_DEPENDS+=   jack.0:${PORTSDIR}/audio/jack
.endif

# libcdaudio
.if ${GST_PLUGIN}=="libcdaudio"
LIB_DEPENDS+=   cdaudio.1:${PORTSDIR}/audio/libcdaudio
.endif

# libvisual
.if ${GST_PLUGIN}=="libvisual"
LIB_DEPENDS+=   visual.0:${PORTSDIR}/graphics/libvisual
.endif

# musepack
.if ${GST_PLUGIN}=="musepack"
LIB_DEPENDS+=   musepack.1:${PORTSDIR}/audio/libmusepack
.endif

# hermes
.if ${GST_PLUGIN}=="hermes"
LIB_DEPENDS+    Hermes.1:${PORTSDIR}/graphics/Hermes
PLIST_FILES=    ${GST_LIB_DIR}/libgsthermescolorspace.so
.endif

# jpeg
.if ${GST_PLUGIN}=="jpeg"
LIB_DEPENDS+=   jpeg.9:${PORTSDIR}/graphics/jpeg
CONFLICTS+= gstreamer-plugins-jpeg-mmx-*
.endif

# jpeg-mmx
.if ${GST_PLUGIN}=="jpeg-mmx"
LIB_DEPEDNS+=   jpeg-mmx.62:${PORTSDIR}/graphics/jpeg-mmx
CONFLICTS+= gstreamer-plugins-jpeg-*.*

GST_PLUGIN_DIR= ext/jpeg
PLIST_FILES=    ${GST_LIB_DIR}/libgstjpeg.so
.endif

# ladspa
.if ${GST_PLUGIN}=="ldspa"
BUILD_DEPENDS+= ${LOCALBASE}/include/ladspa.h:${PORTSDIR}/audio/ladspa
.endif

# lame
.if ${GST_PLUGIN}=="lame"
LIB_DEPENDS+=   mp3lame.0:${PORTSDIR}/audio/lame
.endif

# a52dec
.if ${GST_PLUGIN}=="a52dec"
LIB_DEPENDS+=   a52.0:${PORTSDIR}/audio/liba52
.endif

# audiofile
.if ${GST_PLUGIN}=="audiofile"
LIB_DEPENDS+=   audiofile.0:${PORTSDIR}/audio/libaudiofile
.endif

# libcaca
.if ${GST_PLUGIN}=="libcaca"
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcaca.a:${PORTSDIR}/graphics/libcaca
PLIST_FILES=    ${GST_LIB_DIR}/libgstcacasink.so
.endif

# dv
.if ${GST_PLUGIN}=="dv"
LIB_DEPENDS+=   dv.4:${PORTSDIR}/multimedia/libdv
GST_PLIST_SUFFIX=   dec
.endif

# dvd (dvdnav dvdread)
.if ${GST_PLUGIN}=="dvd"
EXTRA_LIBS+=    -ldvdnav
LIB_DEPENDS+=   dvdnav.3:${PORTSDIR}/multimedia/libdvdnav
GST_PLUGIN_DIR= ext/dvdnav \
        ext/dvdread
PLIST_FILES=    ${GST_LIB_DIR}/libgstdvdnavsrc.so \
        ${GST_LIB_DIR}/libgstdvdreadsrc.so
.endif

# libfame
.if ${GST_PLUGIN}=="libfame"
LIB_DEPENDS+=   fame-0.9.1:${PORTSDIR}/multimedia/libfame
.endif

# libmms
.if ${GST_PLUGIN}=="libmng"
LIB_DEPENDS+=   mms.0:${PORTSDIR}/multimedia/libmms
PLIST_FILES=    ${GST_LIB_DIR}/libgstmms.so
.endif

# libmng
.if ${GST_PLUGIN}=="libmng"
LIB_DEPENDS+=   mng.1:${PORTSDIR}/graphics/libmng
PLIST_FILES=    ${GST_LIB_DIR}/libgstmng.so
.endif

# mikmod
.if ${GST_PLUGIN}=="mikmod"
LIB_DEPENDS+=   mikmod.2:${PORTSDIR}/audio/libmikmod
.endif

# mpeg2dec
.if ${GST_PLUGIN}=="mpeg2dec"
LIB_DEPENDS+=   mpeg2.0:${PORTSDIR}/multimedia/libmpeg2
.endif

# mplex
.if ${GST_PLUGIN}=="mplex"
LIB_DEPENDS+=   lavjpeg-1.6.2:${PORTSDIR}/multimedia/mjpegtools
.endif

# musicbrainz
.if ${GST_PLUGIN}=="musicbrainz"
LIB_DEPENDS+=   musicbrainz.4:${PORTSDIR}/audio/libmusicbrainz
PLIST_FILES=    lib/gstreamer-${VERSION}/libgsttrm.so
.endif

# shout
.if ${GST_PLUGIN}=="shout"
LIB_DEPENDS+=   shout.2:${PORTSDIR}/audio/libshout
.endif

# sidplay
.if ${GST_PLUGIN}=="sidplay"
LIB_DEPENDS+=   sidplay.1:${PORTSDIR}/audio/libsidplay
PLIST_FILES=    ${GST_LIB_DIR}/libgstsid.so
.endif

# sndfile
.if ${GST_PLUGIN}=="sndfile"
LIB_DEPENDS+=   sndfile.1:${PORTSDIR}/audio/libsndfile
.endif

# theora
.if ${GST_PLUGIN}=="theora"
LIB_DEPENDS+=   theora.1:${PORTSDIR}/multimedia/libtheora
.endif

# mad
.if ${GST_PLUGIN}=="mad"
LIB_DEPENDS+=   mad.2:${PORTSDIR}/audio/libmad \
        id3tag.2:${PORTSDIR}/audio/libid3tag
.endif

# mpeg2enc
.if ${GST_PLUGIN}=="mpeg2enc"
USE_GSTREAMER+= mplex
LIB_DEPENDS+=   lavjpeg-1.6.2:${PORTSDIR}/multimedia/mjpegtools

# XXX - make sure CONFIGURE works with mpeg2enc even with "ccache
# c++" ... weird but necessary
CONFIGURE_ENV+= HAVE_CXX=yes
.endif

# nas
.if ${GST_PLUGIN}=="nas"
LIB_DEPENDS+=   audio.2:${PORTSDIR}/audio/nas
GST_PLIST_SUFFIX=   sink
.endif

# ogg
.if ${GST_PLUGIN}=="ogg"
LIB_DEPENDS+=   ogg.5:${PORTSDIR}/audio/libogg
.endif

# pango
.if ${GST_PLUGIN}=="pango"
USE_GNOME+= pango
PLIST_FILES=    ${GST_LIB_DIR}/libgsttextoverlay.so
.endif

# libpng
.if ${GST_PLUGIN}=="libpng"
LIB_DEPENDS+=   png.5:${PORTSDIR}/graphics/png
GST_PLUGIN_DIR= ext/libpng \
                ext/snapshot
PLIST_FILES=    ${GST_LIB_DIR}/libgstpng.so \
        ${GST_LIB_DIR}/libgstsnapshot.so
.endif

# polypaudio
.if ${GST_PLUGIN}=="polypaudio"
LIB_DEPENDS+=   polyp-0.7.0:${PORTSDIR}/audio/polypaudio
PLIST_FILES=    ${GST_LIB_DIR}/libpolypaudio.so
GST_PLUGIN_DIR= ext/polyp
.endif

# sdl
.if ${GST_PLUGIN}=="sdl"
USE_SDL+=   sdl
GST_PLIST_SUFFIX=   videosink
.endif

# smoothwave
.if ${GST_PLUGIN}=="smoothwave"
USE_GNOME+= gtk20
.endif

# speex
.if ${GST_PLUGIN}=="speex"
LIB_DEPENDS+=   speex.3:${PORTSDIR}/audio/speex
.endif

# swfdec
.if ${GST_PLUGIN}=="swfdec"
LIB_DEPENDS+=   swfdec-0.3.0:${PORTSDIR}/graphics/swfdec
.endif

# vorbis
.if ${GST_PLUGIN}=="vorbis"
USE_GSTREAMER+= ogg
LIB_DEPENDS+=   vorbis.3:${PORTSDIR}/audio/libvorbis
.endif

# ivorbis
.if ${GST_PLUGIN}=="ivorbis"
LIB_DEPENDS+=   vorbisidec.1:${PORTSDIR}/audio/libtremor
.endif

# xine
.if ${GST_PLUGIN}=="xine"
LIB_DEPENDS+=   xine.9:${PORTSDIR}/multimedia/libxine
.endif

# xvid
.if ${GST_PLUGIN}=="xvid"
LIB_DEPENDS+=   xvidcore.4:${PORTSDIR}/multimedia/xvid
.endif

LIB_DEPENDS+=   gstgconf-${VERSION}.${SHLIB_VERSION}:${PORTSDIR}/multimedia/gstreamer-plugins

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
    @${ECHO_CMD} "@unexec ${PREFIX}/bin/gst-register-${GST_VERSION} \
        --gst-registry=${PREFIX}/share/gnome/cache/gstreamer-${GST_VERSION}/registry.xml" \
        >> ${TMPPLIST}


post-build:
    @${ECHO_CMD} ${PREFIX}/bin/gst-register-${GST_VERSION} \
        --gst-registry=${PREFIX}/share/gnome/cache/gstreamer-${GST_VERSION}/registry.xml

do-install:
.for dir in ${GST_PLUGIN_DIR}
    @cd ${WRKSRC}/${dir}; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} \
        ${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET}
.endfor

.endif