Index: head/audio/xmms2/Makefile =================================================================== --- head/audio/xmms2/Makefile (revision 395642) +++ head/audio/xmms2/Makefile (revision 395643) @@ -1,386 +1,223 @@ # Created by: Alexander Botero-Lowry # $FreeBSD$ PORTNAME?= xmms2 PORTVERSION= 0.8 DISTVERSIONSUFFIX=DrO_o -PORTREVISION?= 16 +PORTREVISION?= 17 CATEGORIES?= audio MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTVERSION}%20${DISTVERSIONSUFFIX} MAINTAINER?= madpilot@FreeBSD.org COMMENT?= Rewrite of xmms as a client/server system (developer release) USES+= pkgconfig tar:bzip2 waf CONFIGURE_ARGS+= --conf-prefix=${LOCALBASE} \ --mandir=${MANPREFIX}/man INSTALL_TARGET= install --without-ldconfig .if !defined(XMMS2_SLAVE) USE_GNOME= glib20 USE_SQLITE= 3 USE_LDCONFIG= yes PLIST_SUB+= INCLUDEDIR="include/${PORTNAME}" LIBDIR="lib/${PORTNAME}" CPPFLAGS+= -I${LOCALBASE}/include OPTIONS_DEFINE= AIRPLAY AO APE AVCODEC CDDA CURL ET FAAD FAM FLAC \ GME GVFS ICES JACK MAD MDNS MMS \ MODPLUG MPG123 MUSEPACK OFA PULSEAUDIO SAMBA SID \ SNDFILE SPEEX TREMOR VISUAL VOCODER VORBIS WAVPACK XML OPTIONS_SINGLE= MDNS OPTIONS_SINGLE_MDNS= MDNS_APPLE MDNS_AVAHI OPTIONS_DEFAULT= CURL FAAD FLAC MAD MDNS MDNS_APPLE VORBIS AIRPLAY_DESC= Support output via Airport Express AVCODEC_DESC= Avcodevc playback support ET_DESC= Install usage feedback reporting client FAM_DESC= Support to update Media Library on file change GME_DESC= Video game music files support GVFS_DESC= Playback files via GVFS ICES_DESC= Playback files to an icecast server MDNS_DESC= Announce XMMS2d via mDNS (Choose implementation) MDNS_APPLE_DESC= Use Apple mDNS implementation MDNS_AVAHI_DESC= Use Avahi mDNS implementation OFA_DESC= Collect MusicDNS fingerprints SAMBA_DESC= Playback files via SMB SID_DESC= Playback SID files VISUAL_DESC= Visualization plugins support VOCODER_DESC= Phase Vocoder effect plugin XML_DESC= Support XML based playlists (XSPF, RSS) -.endif # !XMMS_SLAVE +OPTIONS_SUB= yes -.include +AIRPLAY_USE= OPENSSL=yes +AIRPLAY_CONFIGURE_OFF= --without-plugins="airplay" -.if defined(XMMS2_SLAVE) -CONFIGURE_ARGS+= --without-xmms2d +AO_LIB_DEPENDS= libao.so:${PORTSDIR}/audio/libao +AO_CONFIGURE_OFF= --without-plugins="ao" -.if ${XMMS2_SLAVE} == "python" -CONFIGURE_ARGS+= --with-optionals="python" -.elif ${XMMS2_SLAVE} == "ruby" -CONFIGURE_ARGS+= --with-optionals="ruby" -.elif ${XMMS2_SLAVE} == "perl" -CONFIGURE_ARGS+= --with-optionals="perl" -.elif ${XMMS2_SLAVE} == "ruby-ecore" -CONFIGURE_ARGS+= --with-optionals="ruby" --with-optionals="xmmsclient-ecore" -.elif ${XMMS2_SLAVE} == "cpp" -CONFIGURE_ARGS+= --with-optionals="xmmsclient++" \ - --with-optionals="xmmsclient++-glib" -.endif +APE_LIB_DEPENDS= libmac.so:${PORTSDIR}/audio/mac +APE_CONFIGURE_OFF= --without-plugins="mac" -.else # XMMS2_SLAVE -CONFIGURE_ARGS+= --without-optionals="python" \ - --without-optionals="ruby" \ - --without-optionals="xmmsclient-ecore" \ - --without-optionals="xmmsclient++" \ - --without-optionals="xmmsclient++-glib" \ - --without-optionals="perl" -.endif # XMMS2_SLAVE +AVCODEC_LIB_DEPENDS= libavutil.so:${PORTSDIR}/multimedia/ffmpeg +AVCODEC_CONFIGURE_OFF= --without-plugins="avcodec" -.if !defined(XMMS2_SLAVE) +CDDA_LIB_DEPENDS= libcdio.so:${PORTSDIR}/sysutils/libcdio \ + libcdio_cdda.so:${PORTSDIR}/sysutils/libcdio-paranoia \ + libdiscid.so:${PORTSDIR}/audio/libdiscid +CDDA_CONFIGURE_OFF= --without-plugins="cdda" -.if ${PORT_OPTIONS:MAIRPLAY} -USE_OPENSSL= yes -PLIST_SUB+= AIRPLAY="" -.else -CONFIGURE_ARGS+= --without-plugins="airplay" -PLIST_SUB+= AIRPLAY="@comment " -.endif +CURL_LIB_DEPENDS= libcurl.so:${PORTSDIR}/ftp/curl +CURL_CONFIGURE_OFF= --without-plugins="curl" --without-plugins="icymetaint" -.if ${PORT_OPTIONS:MAO} -LIB_DEPENDS+= libao.so:${PORTSDIR}/audio/libao -PLIST_SUB+= AO="" -.else -CONFIGURE_ARGS+= --without-plugins="ao" -PLIST_SUB+= AO="@comment " -.endif +FAAD_LIB_DEPENDS= libfaad.so:${PORTSDIR}/audio/faad +FAAD_CONFIGURE_OFF= --without-plugins="faad" --without-plugins="mp4" -.if ${PORT_OPTIONS:MAPE} -LIB_DEPENDS+= libmac.so:${PORTSDIR}/audio/mac -PLIST_SUB+= MAC="" -.else -CONFIGURE_ARGS+= --without-plugins="mac" -PLIST_SUB+= MAC="@comment " -.endif +FAM_USES= fam:gamin +FAM_CONFIGURE_OFF= --without-optionals="medialib-updater" -.if ${PORT_OPTIONS:MAVCODEC} -LIB_DEPENDS+= libavutil.so:${PORTSDIR}/multimedia/ffmpeg -PLIST_SUB+= AVCODEC="" -.else -CONFIGURE_ARGS+= --without-plugins="avcodec" -PLIST_SUB+= AVCODEC="@comment " -.endif +FLAC_LIB_DEPENDS= libFLAC.so:${PORTSDIR}/audio/flac -.if ${PORT_OPTIONS:MCDDA} -LIB_DEPENDS+= libcdio.so:${PORTSDIR}/sysutils/libcdio \ - libcdio_cdda.so:${PORTSDIR}/sysutils/libcdio-paranoia \ - libdiscid.so:${PORTSDIR}/audio/libdiscid -PLIST_SUB+= CDDA="" -.else -CONFIGURE_ARGS+= --without-plugins="cdda" -PLIST_SUB+= CDDA="@comment " -.endif +GME_LIB_DEPENDS= libgme.so:${PORTSDIR}/audio/libgme +GME_CONFIGURE_OFF= --without-plugins="gme" -.if ${PORT_OPTIONS:MCURL} -LIB_DEPENDS+= libcurl.so:${PORTSDIR}/ftp/curl -PLIST_SUB+= CURL="" -.else -CONFIGURE_ARGS+= --without-plugins="curl" --without-plugins="icymetaint" -PLIST_SUB+= CURL="@comment " -.endif +GVFS_USE= GNOME=gvfs +GVFS_CONFIGURE_OFF= --without-plugins="gvfs" -.if ${PORT_OPTIONS:MFAAD} -LIB_DEPENDS+= libfaad.so:${PORTSDIR}/audio/faad -PLIST_SUB+= FAAD="" -.else -CONFIGURE_ARGS+= --without-plugins="faad" --without-plugins="mp4" -PLIST_SUB+= FAAD="@comment " -.endif +ICES_LIB_DEPENDS= libshout.so:${PORTSDIR}/audio/libshout +ICES_CONFIGURE_OFF= --without-plugins="ices" -.if ${PORT_OPTIONS:MFAM} -USES+= fam:gamin -PLIST_SUB+= FAM="" -.else -CONFIGURE_ARGS+= --without-optionals="medialib-updater" -PLIST_SUB+= FAM="@comment " -.endif +JACK_LIB_DEPENDS= libjack.so:${PORTSDIR}/audio/jack +JACK_CONFIGURE_OFF= --without-plugins="jack" -.if ${PORT_OPTIONS:MFLAC} -LIB_DEPENDS+= libFLAC.so:${PORTSDIR}/audio/flac -PLIST_SUB+= FLAC="" -.else -CONFIGURE_ARGS+= --without-plugins="flac" -PLIST_SUB+= FLAC="@comment " -.endif +MAD_LIB_DEPENDS= libmad.so:${PORTSDIR}/audio/libmad +MAD_CONFIGURE_OFF= --without-plugins="mad" -.if ${PORT_OPTIONS:MGME} -LIB_DEPENDS+= libgme.so:${PORTSDIR}/audio/libgme -PLIST_SUB+= GME="" -.else -CONFIGURE_ARGS+= --without-plugins="gme" -PLIST_SUB+= GME="@comment " -.endif +MDNS_CONFIGURE_OFF= --without-optionals="mdns" -.if ${PORT_OPTIONS:MGVFS} -USE_GNOME+= gvfs -PLIST_SUB+= GVFS="" -.else -CONFIGURE_ARGS+= --without-plugins="gvfs" -PLIST_SUB+= GVFS="@comment " -.endif +MDNS_APPLE_CONFIGURE_ON= --with-mdns-backend="dns_sd" +MDNS_APPLE_LIB_DEPENDS= libdns_sd.so:${PORTSDIR}/net/mDNSResponder -.if ${PORT_OPTIONS:MICES} -LIB_DEPENDS+= libshout.so:${PORTSDIR}/audio/libshout -PLIST_SUB+= ICES="" -.else -CONFIGURE_ARGS+= --without-plugins="ices" -PLIST_SUB+= ICES="@comment " -.endif +MDNS_AVAHI_CONFIGURE_ON= --with-mdns-backend="avahi" +MDNS_AVAHI_LIB_DEPENDS= libavahi-core.so:${PORTSDIR}/net/avahi-app -.if ${PORT_OPTIONS:MJACK} -LIB_DEPENDS+= libjack.so:${PORTSDIR}/audio/jack -PLIST_SUB+= JACK="" -.else -CONFIGURE_ARGS+= --without-plugins="jack" -PLIST_SUB+= JACK="@comment " -.endif +MMS_LIB_DEPENDS= libmms.so:${PORTSDIR}/net/libmms +MMS_CONFIGURE_OFF= --without-plugins="mms" -.if ${PORT_OPTIONS:MMAD} -LIB_DEPENDS+= libmad.so:${PORTSDIR}/audio/libmad -PLIST_SUB+= MAD="" -.else -CONFIGURE_ARGS+= --without-plugins="mad" -PLIST_SUB+= MAD="@comment " -.endif +MODPLUG_LIB_DEPENDS= libmodplug.so:${PORTSDIR}/audio/libmodplug +MODPLUG_CONFIGURE_OFF= --without-plugins="modplug" -.if empty(PORT_OPTIONS:MMDNS) -CONFIGURE_ARGS+= --without-optionals="mdns" -.endif +MPG123_LIB_DEPENDS= libmpg123.so:${PORTSDIR}/audio/mpg123 +MPG123_CONFIGURE_OFF= --without-plugins="mpg123" -.if ${PORT_OPTIONS:MMDNS_APPLE} -CONFIGURE_ARGS+= --with-mdns-backend="dns_sd" -LIB_DEPENDS+= libdns_sd.so:${PORTSDIR}/net/mDNSResponder -PLIST_SUB+= MDNS_APPLE="" -.else -PLIST_SUB+= MDNS_APPLE="@comment " -.endif +MUSEPACK_LIB_DEPENDS= libmpcdec.so:${PORTSDIR}/audio/musepack +MUSEPACK_CONFIGURE_OFF= --without-plugins="musepack" -.if ${PORT_OPTIONS:MMDNS_AVAHI} -CONFIGURE_ARGS+= --with-mdns-backend="avahi" -LIB_DEPENDS+= libavahi-core.so:${PORTSDIR}/net/avahi-app -PLIST_SUB+= MDNS_AVAHI="" -MAN1+= xmms2-mdns-avahi.1 -.else -PLIST_SUB+= MDNS_AVAHI="@comment " -.endif +OFA_LIB_DEPENDS= libofa.so:${PORTSDIR}/audio/libofa +OFA_CONFIGURE_OFF= --without-plugins="ofa" -.if ${PORT_OPTIONS:MMMS} -LIB_DEPENDS+= libmms.so:${PORTSDIR}/net/libmms -PLIST_SUB+= MMS="" -.else -CONFIGURE_ARGS+= --without-plugins="mms" -PLIST_SUB+= MMS="@comment " -.endif +PULSEAUDIO_LIB_DEPENDS= libpulse.so:${PORTSDIR}/audio/pulseaudio +PULSEAUDIO_CONFIGURE_OFF= --without-plugins="pulse" -.if ${PORT_OPTIONS:MMODPLUG} -LIB_DEPENDS+= libmodplug.so:${PORTSDIR}/audio/libmodplug -PLIST_SUB+= MODPLUG="" -.else -CONFIGURE_ARGS+= --without-plugins="modplug" -PLIST_SUB+= MODPLUG="@comment " -.endif +SAMBA_LIB_DEPENDS= libsmbclient.so:${PORTSDIR}/net/samba-libsmbclient +SAMBA_CONFIGURE_OFF= --without-plugins="samba" -.if ${PORT_OPTIONS:MMPG123} -LIB_DEPENDS+= libmpg123.so:${PORTSDIR}/audio/mpg123 -PLIST_SUB+= MPG123="" -.else -CONFIGURE_ARGS+= --without-plugins="mpg123" -PLIST_SUB+= MPG123="@comment " -.endif +SID_LIB_DEPENDS= libsidplay2.so:${PORTSDIR}/audio/libsidplay2 +SID_CONFIGURE_OFF= --without-plugins="sid" -.if ${PORT_OPTIONS:MMUSEPACK} -LIB_DEPENDS+= libmpcdec.so:${PORTSDIR}/audio/musepack -PLIST_SUB+= MUSEPACK="" -.else -CONFIGURE_ARGS+= --without-plugins="musepack" -PLIST_SUB+= MUSEPACK="@comment " -.endif +SNDFILE_LIB_DEPENDS= libsndfile.so:${PORTSDIR}/audio/libsndfile +SNDFILE_CONFIGURE_OFF= --without-plugins="sndfile" -.if ${PORT_OPTIONS:MOFA} -LIB_DEPENDS+= libofa.so:${PORTSDIR}/audio/libofa -PLIST_SUB+= OFA="" -.else -CONFIGURE_ARGS+= --without-plugins="ofa" -PLIST_SUB+= OFA="@comment " -.endif +SPEEX_LIB_DEPENDS= libspeex.so:${PORTSDIR}/audio/speex +SPEEX_CONFIGURE_OFF= --without-plugins="speex" -.if ${PORT_OPTIONS:MPULSEAUDIO} -LIB_DEPENDS+= libpulse.so:${PORTSDIR}/audio/pulseaudio -PLIST_SUB+= PULSE="" -.else -CONFIGURE_ARGS+= --without-plugins="pulse" -PLIST_SUB+= PULSE="@comment " -.endif +TREMOR_LIB_DEPENDS= libvorbisidec.so:${PORTSDIR}/audio/libtremor +TREMOR_CONFIGURE_OFF= --without-plugins="tremor" -.if ${PORT_OPTIONS:MSAMBA} -LIB_DEPENDS+= libsmbclient.so:${PORTSDIR}/net/samba-libsmbclient -PLIST_SUB+= SAMBA="" -.else -CONFIGURE_ARGS+= --without-plugins="samba" -PLIST_SUB+= SAMBA="@comment " -.endif +VISUAL_USE= SDL=yes +VISUAL_LIB_DEPENDS= libvisual-0.4.so:${PORTSDIR}/graphics/libvisual04 +VISUAL_CONFIGURE_OFF= --without-optionals="vistest" +VISUAL_CONFIGURE_ON= --with-vis-reference-clients -.if ${PORT_OPTIONS:MSID} -LIB_DEPENDS+= libsidplay2.so:${PORTSDIR}/audio/libsidplay2 -PLIST_SUB+= SID="" -.else -CONFIGURE_ARGS+= --without-plugins="sid" -PLIST_SUB+= SID="@comment " -.endif +VOCODER_LIB_DEPENDS= libfftw3f.so:${PORTSDIR}/math/fftw3-float \ + libsamplerate.so:${PORTSDIR}/audio/libsamplerate +VOCODER_CONFIGURE_OFF= --without-plugins="vocoder" -.if ${PORT_OPTIONS:MSNDFILE} -LIB_DEPENDS+= libsndfile.so:${PORTSDIR}/audio/libsndfile -PLIST_SUB+= SNDFILE="" -.else -CONFIGURE_ARGS+= --without-plugins="sndfile" -PLIST_SUB+= SNDFILE="@comment " -.endif +VORBIS_LIB_DEPENDS= libvorbis.so:${PORTSDIR}/audio/libvorbis +VORBIS_CONFIGURE_OFF= --without-plugins="vorbis" -.if ${PORT_OPTIONS:MSPEEX} -LIB_DEPENDS+= libspeex.so:${PORTSDIR}/audio/speex -PLIST_SUB+= SPEEX="" -.else -CONFIGURE_ARGS+= --without-plugins="speex" -PLIST_SUB+= SPEEX="@comment " -.endif +WAVPACK_LIB_DEPENDS= libwavpack.so:${PORTSDIR}/audio/wavpack +WAVPACK_CONFIGURE_OFF= --without-plugins="wavpack" -.if ${PORT_OPTIONS:MTREMOR} -LIB_DEPENDS+= libvorbisidec.so:${PORTSDIR}/audio/libtremor -PLIST_SUB+= TREMOR="" -.else -CONFIGURE_ARGS+= --without-plugins="tremor" -PLIST_SUB+= TREMOR="@comment " -.endif +XML_USE= GNOME=libxml2 +XML_CONFIGURE_OFF= --without-plugins="xml" --without-plugins="rss" \ + --without-plugins="xspf" -# xmms2-ripper -.if ${PORT_OPTIONS:MVISUAL} && ${PORT_OPTIONS:MVORBIS} -LIB_DEPENDS+= libvorbisenc.so:${PORTSDIR}/audio/libvorbis -.else -EXTRA_PATCHES+= ${FILESDIR}/extra-patch-src-clients-vistest-wscript -.endif +ET_CONFIGURE_OFF= --without-optionals="et" -# XXX: shm support requires semtimedop(2) -.if ${PORT_OPTIONS:MVISUAL} -USE_SDL= yes -LIB_DEPENDS+= libvisual-0.4.so:${PORTSDIR}/graphics/libvisual04 -.else -CONFIGURE_ARGS+= --without-optionals="vistest" -.endif +.endif # !XMMS_SLAVE -.if ${PORT_OPTIONS:MVISUAL} && ${CONFIGURE_ARGS:M--with-vis-reference-clients} -PLIST_SUB+= VISUAL="" -.else -PLIST_SUB+= VISUAL="@comment " -.endif +.include -.if ${PORT_OPTIONS:MVOCODER} -LIB_DEPENDS+= libfftw3f.so:${PORTSDIR}/math/fftw3-float \ - libsamplerate.so:${PORTSDIR}/audio/libsamplerate -PLIST_SUB+= VOCODER="" -.else -CONFIGURE_ARGS+= --without-plugins="vocoder" -PLIST_SUB+= VOCODER="@comment " -.endif +.if defined(XMMS2_SLAVE) +CONFIGURE_ARGS+= --without-xmms2d -.if ${PORT_OPTIONS:MVORBIS} -LIB_DEPENDS+= libvorbis.so:${PORTSDIR}/audio/libvorbis -PLIST_SUB+= VORBIS="" -.else -CONFIGURE_ARGS+= --without-plugins="vorbis" -PLIST_SUB+= VORBIS="@comment " +.if ${XMMS2_SLAVE} == "python" +CONFIGURE_ARGS+= --with-optionals="python" +.elif ${XMMS2_SLAVE} == "ruby" +CONFIGURE_ARGS+= --with-optionals="ruby" +.elif ${XMMS2_SLAVE} == "perl" +CONFIGURE_ARGS+= --with-optionals="perl" +.elif ${XMMS2_SLAVE} == "ruby-ecore" +CONFIGURE_ARGS+= --with-optionals="ruby" --with-optionals="xmmsclient-ecore" +.elif ${XMMS2_SLAVE} == "cpp" +CONFIGURE_ARGS+= --with-optionals="xmmsclient++" \ + --with-optionals="xmmsclient++-glib" .endif -.if ${PORT_OPTIONS:MWAVPACK} -LIB_DEPENDS+= libwavpack.so:${PORTSDIR}/audio/wavpack -PLIST_SUB+= WAVPACK="" -.else -CONFIGURE_ARGS+= --without-plugins="wavpack" -PLIST_SUB+= WAVPACK="@comment " -.endif +.else # XMMS2_SLAVE +CONFIGURE_ARGS+= --without-optionals="python" \ + --without-optionals="ruby" \ + --without-optionals="xmmsclient-ecore" \ + --without-optionals="xmmsclient++" \ + --without-optionals="xmmsclient++-glib" \ + --without-optionals="perl" +.endif # XMMS2_SLAVE -.if ${PORT_OPTIONS:MXML} -USE_GNOME+= libxml2 -PLIST_SUB+= XML="" -.else -CONFIGURE_ARGS+= --without-plugins="xml" --without-plugins="rss" \ - --without-plugins="xspf" -PLIST_SUB+= XML="@comment " -.endif +.if !defined(XMMS2_SLAVE) -.if ${PORT_OPTIONS:MET} -PLIST_SUB+= ET="" -MAN1+= xmms2-et.1 +# xmms2-ripper +.if ${PORT_OPTIONS:MVISUAL} && ${PORT_OPTIONS:MVORBIS} +LIB_DEPENDS+= libvorbisenc.so:${PORTSDIR}/audio/libvorbis .else -CONFIGURE_ARGS+= --without-optionals="et" -PLIST_SUB+= ET="@comment " +EXTRA_PATCHES+= ${FILESDIR}/extra-patch-src-clients-vistest-wscript .endif .endif # !XMMS2_SLAVE +.include + +# Force to nothing to avoid bsd.openssl.mk adding definitions +# to it when AIRPLAY option is active, waf does not understand it anyway. +MAKE_ARGS= + post-patch: @${REINPLACE_CMD} -e "s|%%WRKSRC%%|${WRKSRC}|" ${WRKSRC}/wscript .if ${PORT_OPTIONS:MVISUAL} && ${PORT_OPTIONS:MVORBIS} @${REINPLACE_CMD} -e "s|'vorbisenc',|'vorbisenc vorbis ogg',|" \ ${WRKSRC}/src/clients/vistest/wscript .endif post-install: .if !defined(XMMS2_SLAVE) ${MKDIR} ${STAGEDIR}${DATADIR}/scripts/startup.d + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/* + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/${PORTNAME}/* + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libxmmsclient* .endif -.include +.include Index: head/audio/xmms2/files/patch-patch-src-plugins-musepack-wscript =================================================================== --- head/audio/xmms2/files/patch-patch-src-plugins-musepack-wscript (revision 395642) +++ head/audio/xmms2/files/patch-patch-src-plugins-musepack-wscript (nonexistent) @@ -1,11 +0,0 @@ ---- src/plugins/musepack/wscript.orig 2010-09-10 22:55:03.412930402 +0200 -+++ src/plugins/musepack/wscript 2010-09-10 23:02:05.738208553 +0200 -@@ -8,7 +8,7 @@ def plugin_configure(conf): - conf.check_cc(header_name="mpcdec/mpcdec.h", defines="HAVE_MPCDEC_OLD", - uselib_store="mpcdec") - -- conf.check_cc(lib="mpcdec", uselib_store="mpcdec") -+ conf.check_cc(lib="mpcdec", uselib="math", uselib_store="mpcdec") - - configure, build = plugin("musepack", configure=plugin_configure, - libs=["mpcdec"]) Property changes on: head/audio/xmms2/files/patch-patch-src-plugins-musepack-wscript ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/audio/xmms2/files/patch-src-clients-lib-xmmsclient-glib-wscript =================================================================== --- head/audio/xmms2/files/patch-src-clients-lib-xmmsclient-glib-wscript (revision 395642) +++ head/audio/xmms2/files/patch-src-clients-lib-xmmsclient-glib-wscript (revision 395643) @@ -1,34 +1,34 @@ ---- src/clients/lib/xmmsclient-glib/wscript.orig 2013-05-24 16:43:51.815281865 +0200 -+++ src/clients/lib/xmmsclient-glib/wscript 2013-05-24 17:00:04.966198019 +0200 +--- src/clients/lib/xmmsclient-glib/wscript.orig 2011-10-20 19:26:08 UTC ++++ src/clients/lib/xmmsclient-glib/wscript @@ -1,19 +1,21 @@ from waftools import tool def build(bld): - obj = bld(features='c cshlib', - target = 'xmmsclient-glib', - includes = '../../../.. ../../../include', - source = 'xmmsclient-glib.c', - uselib = 'glib2', - use = 'xmmsclient', - vnum = '1.0.0' - ) + if bld.env.BUILD_XMMS2D: + obj = bld(features='c cshlib', + target = 'xmmsclient-glib', + includes = '../../../.. ../../../include', + source = 'xmmsclient-glib.c', + uselib = 'glib2', + use = 'xmmsclient', + vnum = '1.0.0' + ) - tool.add_install_flag(bld, obj) + tool.add_install_flag(bld, obj) def configure(conf): - conf.env.XMMS_PKGCONF_FILES.append(('xmms2-client-glib', '-lxmmsclient-glib')) + if not conf.options.without_xmms2d: + conf.env.XMMS_PKGCONF_FILES.append(('xmms2-client-glib', '-lxmmsclient-glib')) return True Index: head/audio/xmms2/files/patch-src-clients-lib-xmmsclient-wscript =================================================================== --- head/audio/xmms2/files/patch-src-clients-lib-xmmsclient-wscript (revision 395642) +++ head/audio/xmms2/files/patch-src-clients-lib-xmmsclient-wscript (revision 395643) @@ -1,34 +1,34 @@ ---- src/clients/lib/xmmsclient/wscript.orig 2013-05-24 16:42:05.810273309 +0200 -+++ src/clients/lib/xmmsclient/wscript 2013-05-24 17:00:19.345205807 +0200 -@@ -25,19 +25,21 @@ +--- src/clients/lib/xmmsclient/wscript.orig 2011-10-20 19:26:08 UTC ++++ src/clients/lib/xmmsclient/wscript +@@ -25,19 +25,21 @@ def build(bld): else: source.extend(["visualization/dummy.c"]) - obj = bld(features = 'c cshlib', - target = 'xmmsclient', - includes = '../../../.. ../../../include ../../../includepriv', - source = source, - uselib = 'socket time', - use = 'xmmsipc xmmssocket xmmsutils xmmstypes xmmsvisualization', - vnum = '6.0.0' - ) + if bld.env.BUILD_XMMS2D: + obj = bld(features = 'c cshlib', + target = 'xmmsclient', + includes = '../../../.. ../../../include ../../../includepriv', + source = source, + uselib = 'socket time', + use = 'xmmsipc xmmssocket xmmsutils xmmstypes xmmsvisualization', + vnum = '6.0.0' + ) - tool.add_install_flag(bld, obj) + tool.add_install_flag(bld, obj) def configure(conf): - conf.env.XMMS_PKGCONF_FILES.append(("xmms2-client", "-lxmmsclient")) + if not conf.options.without_xmms2d: + conf.env.XMMS_PKGCONF_FILES.append(("xmms2-client", "-lxmmsclient")) conf.check_cc(function_name="semtimedop", header_name=["sys/types.h", "sys/ipc.h", "sys/sem.h"], Index: head/audio/xmms2/files/patch-src-include-wscript =================================================================== --- head/audio/xmms2/files/patch-src-include-wscript (revision 395642) +++ head/audio/xmms2/files/patch-src-include-wscript (revision 395643) @@ -1,22 +1,22 @@ ---- src/include/wscript.orig 2011-10-20 21:26:08.000000000 +0200 -+++ src/include/wscript 2013-05-24 17:17:24.643159743 +0200 -@@ -2,12 +2,13 @@ +--- src/include/wscript.orig 2011-10-20 19:26:08 UTC ++++ src/include/wscript +@@ -2,12 +2,13 @@ import os def build(bld): # FIXME: This is a test that should work. - for d in bld.path.ant_glob('**', dir=True, src=False): - rpath = d.path_from(bld.path) - bld.recurse(rpath) - f = d.ant_glob('*.h') - if f: - bld.install_files(os.path.join(bld.env.INCLUDEDIR, 'xmms2', rpath), f) + if bld.env.BUILD_XMMS2D: + for d in bld.path.ant_glob('**', dir=True, src=False): + rpath = d.path_from(bld.path) + bld.recurse(rpath) + f = d.ant_glob('*.h') + if f: + bld.install_files(os.path.join(bld.env.INCLUDEDIR, 'xmms2', rpath), f) #paths = ['xmms', 'xmmsc', 'xmmsclient', 'xmmsclient/xmmsclient++'] #for p in paths: Index: head/audio/xmms2/files/patch-src-include-xmmsclient-xmmsclient++-coll.h =================================================================== --- head/audio/xmms2/files/patch-src-include-xmmsclient-xmmsclient++-coll.h (revision 395642) +++ head/audio/xmms2/files/patch-src-include-xmmsclient-xmmsclient++-coll.h (revision 395643) @@ -1,11 +1,11 @@ ---- src/include/xmmsclient/xmmsclient++/coll.h.orig 2013-05-24 12:04:02.505430442 +0200 -+++ src/include/xmmsclient/xmmsclient++/coll.h 2013-05-24 12:07:11.694426120 +0200 -@@ -612,7 +612,7 @@ +--- src/include/xmmsclient/xmmsclient++/coll.h.orig 2011-10-20 19:26:08 UTC ++++ src/include/xmmsclient/xmmsclient++/coll.h +@@ -612,7 +612,7 @@ namespace Xmms template< typename keyT, typename valT > AbstractElement< keyT, valT >::AbstractElement( const Coll& coll, keyT index ) - : coll_ (coll), index_( index ) + : coll_ ( const_cast< Coll& >( coll ) ), index_( index ) { xmmsv_coll_ref( coll_.getColl() ); } Index: head/audio/xmms2/files/patch-src-plugins-airplay-wscript =================================================================== --- head/audio/xmms2/files/patch-src-plugins-airplay-wscript (revision 395642) +++ head/audio/xmms2/files/patch-src-plugins-airplay-wscript (revision 395643) @@ -1,11 +1,11 @@ ---- src/plugins/airplay/wscript.orig 2010-02-19 18:43:54.000000000 +0100 -+++ src/plugins/airplay/wscript 2010-03-17 15:14:34.459359323 +0100 +--- src/plugins/airplay/wscript.orig 2011-10-20 19:26:08 UTC ++++ src/plugins/airplay/wscript @@ -12,8 +12,6 @@ rtspmessage.c def plugin_configure(conf): # MinGW doesn't ship sys/select.h conf.check_cc(header_name='sys/select.h') - conf.check_cfg(package="openssl", args="--cflags --libs", - uselib_store="openssl") configure, build = plugin("airplay", configure=plugin_configure, source = source, libs=["openssl"], output_prio=4) Index: head/audio/xmms2/files/patch-src-plugins-file-wscript =================================================================== --- head/audio/xmms2/files/patch-src-plugins-file-wscript (revision 395642) +++ head/audio/xmms2/files/patch-src-plugins-file-wscript (revision 395643) @@ -1,19 +1,19 @@ ---- src/plugins/file/wscript.orig 2011-10-20 21:26:08.000000000 +0200 -+++ src/plugins/file/wscript 2012-05-04 23:01:58.940585349 +0200 +--- src/plugins/file/wscript.orig 2011-10-20 19:26:08 UTC ++++ src/plugins/file/wscript @@ -1,7 +1,7 @@ from waftools.plugin import plugin def plugin_build(bld, obj): - if bld.env.HAVE_FSTATAT and bld.env.HAVE_DIRFD: + if bld.env.HAVE_FSTATAT: obj.source.append('browse/fstatat.c') else: obj.source.append('browse/gdir.c') -@@ -9,7 +9,6 @@ +@@ -9,7 +9,6 @@ def plugin_build(bld, obj): def plugin_configure(conf): conf.check_cc(function_name='fstatat', header_name=['fcntl.h','sys/stat.h'], defines=['_ATFILE_SOURCE=1']) - conf.check_cc(function_name='dirfd', header_name=['dirent.h','sys/types.h']) configure, build = plugin("file", configure=plugin_configure, build=plugin_build, Index: head/audio/xmms2/files/patch-src-plugins-modplug-modplug.c =================================================================== --- head/audio/xmms2/files/patch-src-plugins-modplug-modplug.c (revision 395642) +++ head/audio/xmms2/files/patch-src-plugins-modplug-modplug.c (revision 395643) @@ -1,11 +1,11 @@ ---- src/plugins/modplug/modplug.c.orig 2011-10-20 21:26:08.000000000 +0200 -+++ src/plugins/modplug/modplug.c 2014-04-09 15:05:29.232679291 +0200 +--- src/plugins/modplug/modplug.c.orig 2011-10-20 19:26:08 UTC ++++ src/plugins/modplug/modplug.c @@ -9,7 +9,7 @@ #include "xmms/xmms_sample.h" #include "xmms/xmms_medialib.h" #include "xmms/xmms_log.h" -#include +#include #include #include Index: head/audio/xmms2/files/patch-src__plugins__cdda__cdda.c =================================================================== --- head/audio/xmms2/files/patch-src__plugins__cdda__cdda.c (revision 395642) +++ head/audio/xmms2/files/patch-src__plugins__cdda__cdda.c (revision 395643) @@ -1,11 +1,11 @@ ---- src/plugins/cdda/cdda.c.orig 2011-10-20 23:26:08.000000000 +0400 -+++ src/plugins/cdda/cdda.c 2014-08-21 14:24:46.000000000 +0400 +--- src/plugins/cdda/cdda.c.orig 2011-10-20 19:26:08 UTC ++++ src/plugins/cdda/cdda.c @@ -18,7 +18,7 @@ #include "xmms/xmms_log.h" #include "xmms/xmms_util.h" -#include +#include #include #include #include Index: head/audio/xmms2/files/patch-src_plugins_ao_ao.c =================================================================== --- head/audio/xmms2/files/patch-src_plugins_ao_ao.c (revision 395642) +++ head/audio/xmms2/files/patch-src_plugins_ao_ao.c (revision 395643) @@ -1,10 +1,10 @@ ---- src/plugins/ao/ao.c.orig +--- src/plugins/ao/ao.c.orig 2011-10-20 19:26:08 UTC +++ src/plugins/ao/ao.c -@@ -160,6 +160,7 @@ +@@ -162,6 +162,7 @@ xmms_ao_new (xmms_output_t *output) /* let's just use some common format to check if the device * name is valid */ + memset(&format, 0, sizeof(format)); format.bits = 16; format.rate = 44100; format.channels = 2; Index: head/audio/xmms2/files/patch-src_plugins_avcodec_avcodec.c =================================================================== --- head/audio/xmms2/files/patch-src_plugins_avcodec_avcodec.c (revision 395642) +++ head/audio/xmms2/files/patch-src_plugins_avcodec_avcodec.c (revision 395643) @@ -1,527 +1,527 @@ ---- src/plugins/avcodec/avcodec.c.orig 2011-10-20 21:26:08.000000000 +0200 -+++ src/plugins/avcodec/avcodec.c 2014-02-27 18:55:51.060717698 +0100 +--- src/plugins/avcodec/avcodec.c.orig 2011-10-20 19:26:08 UTC ++++ src/plugins/avcodec/avcodec.c @@ -1,7 +1,7 @@ /** @file avcodec.c * Decoder plugin for ffmpeg avcodec formats * - * Copyright (C) 2006-2011 XMMS2 Team + * Copyright (C) 2006-2014 XMMS2 Team * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -14,15 +14,16 @@ * Lesser General Public License for more details. */ -#include "xmms_configuration.h" -#include "xmms/xmms_xformplugin.h" -#include "xmms/xmms_sample.h" -#include "xmms/xmms_log.h" +#include +#include +#include +#include #include #include #include #include +#include #include "avcodec_compat.h" -@@ -36,6 +37,8 @@ +@@ -36,6 +37,8 @@ typedef struct { guint buffer_size; gboolean no_demuxer; + AVFrame *read_out_frame; + guint channels; guint samplerate; xmms_sample_format_t sampleformat; -@@ -53,10 +56,14 @@ +@@ -53,10 +56,14 @@ typedef struct { static gboolean xmms_avcodec_plugin_setup (xmms_xform_plugin_t *xform_plugin); static gboolean xmms_avcodec_init (xmms_xform_t *xform); static void xmms_avcodec_destroy (xmms_xform_t *xform); +static gint xmms_avcodec_internal_read_some (xmms_xform_t *xform, xmms_avcodec_data_t *data, xmms_error_t *error); +static gint xmms_avcodec_internal_decode_some (xmms_avcodec_data_t *data); +static void xmms_avcodec_internal_append (xmms_avcodec_data_t *data); static gint xmms_avcodec_read (xmms_xform_t *xform, xmms_sample_t *buf, gint len, xmms_error_t *error); static gint64 xmms_avcodec_seek (xmms_xform_t *xform, gint64 samples, xmms_xform_seek_mode_t whence, xmms_error_t *err); +static xmms_sample_format_t xmms_avcodec_translate_sample_format (enum AVSampleFormat av_sample_format); /* * Plugin header -@@ -85,13 +92,23 @@ +@@ -85,13 +92,23 @@ xmms_avcodec_plugin_setup (xmms_xform_pl xmms_magic_add ("A/52 (AC-3) header", "audio/x-ffmpeg-ac3", "0 beshort 0x0b77", NULL); xmms_magic_add ("DTS header", "audio/x-ffmpeg-dca", - "0 belong 0x7ffe8001", NULL); + "0 belong 0x7ffe8001", NULL); xmms_xform_plugin_indata_add (xform_plugin, XMMS_STREAM_TYPE_MIMETYPE, "audio/x-ffmpeg-*", NULL); + XMMS_DBG ("avcodec version at build time is %d.%d.%d", + (LIBAVCODEC_VERSION_INT >> 16), + (LIBAVCODEC_VERSION_INT >> 8) & 0xff, + LIBAVCODEC_VERSION_INT & 0xff); + XMMS_DBG ("avcodec version at run time is %d.%d.%d", + (avcodec_version() >> 16), + (avcodec_version() >> 8) & 0xff, + avcodec_version() & 0xff); + XMMS_DBG ("avcodec configuration is %s", avcodec_configuration()); + return TRUE; } -@@ -107,6 +124,7 @@ +@@ -107,6 +124,7 @@ xmms_avcodec_destroy (xmms_xform_t *xfor avcodec_close (data->codecctx); av_free (data->codecctx); + av_frame_free (&data->read_out_frame); g_string_free (data->outbuf, TRUE); g_free (data->buffer); -@@ -132,9 +150,10 @@ +@@ -132,9 +150,10 @@ xmms_avcodec_init (xmms_xform_t *xform) data->buffer_size = AVCODEC_BUFFER_SIZE; data->codecctx = NULL; + data->read_out_frame = av_frame_alloc (); + xmms_xform_private_data_set (xform, data); - avcodec_init (); avcodec_register_all (); mimetype = xmms_xform_indata_get_str (xform, -@@ -161,12 +180,12 @@ +@@ -161,12 +180,12 @@ xmms_avcodec_init (xmms_xform_t *xform) data->channels = ret; } - /* bitrate required for WMA files */ + /* Required by WMA xform. */ xmms_xform_auxdata_get_int (xform, "bitrate", &data->bitrate); - /* ALAC and MAC require bits per sample field to be 16 */ + /* Required by tta and apefile xforms. */ xmms_xform_auxdata_get_int (xform, "samplebits", &data->samplebits); -@@ -188,7 +207,8 @@ +@@ -188,7 +207,8 @@ xmms_avcodec_init (xmms_xform_t *xform) !strcmp (data->codec_id, "adpcm_swf") || !strcmp (data->codec_id, "pcm_s16le") || !strcmp (data->codec_id, "ac3") || - !strcmp (data->codec_id, "dca")) { + !strcmp (data->codec_id, "dca") || + !strcmp (data->codec_id, "nellymoser")) { /* number 1024 taken from libavformat raw.c RAW_PACKET_SIZE */ data->extradata = g_malloc0 (1024); data->extradata_size = 1024; -@@ -196,22 +216,22 @@ +@@ -196,22 +216,22 @@ xmms_avcodec_init (xmms_xform_t *xform) } else { /* A demuxer plugin forgot to give decoder config? */ xmms_log_error ("Decoder config data not found!"); - return FALSE; + goto err; } } - data->codecctx = avcodec_alloc_context (); + data->codecctx = avcodec_alloc_context3 (codec); data->codecctx->sample_rate = data->samplerate; data->codecctx->channels = data->channels; data->codecctx->bit_rate = data->bitrate; - CONTEXT_BPS (data->codecctx) = data->samplebits; + data->codecctx->bits_per_coded_sample = data->samplebits; data->codecctx->block_align = data->block_align; data->codecctx->extradata = data->extradata; data->codecctx->extradata_size = data->extradata_size; data->codecctx->codec_id = codec->id; data->codecctx->codec_type = codec->type; - if (avcodec_open (data->codecctx, codec) < 0) { + if (avcodec_open2 (data->codecctx, codec, NULL) < 0) { XMMS_DBG ("Opening decoder '%s' failed", codec->name); goto err; } else { -@@ -220,7 +240,7 @@ +@@ -220,7 +240,7 @@ xmms_avcodec_init (xmms_xform_t *xform) /* some codecs need to have something read before they set * the samplerate and channels correctly, unfortunately... */ - if ((ret = xmms_avcodec_read (xform, buf, 42, &error)) > 0) { + if ((ret = xmms_avcodec_read (xform, buf, sizeof (buf), &error)) > 0) { g_string_insert_len (data->outbuf, 0, buf, ret); } else { XMMS_DBG ("First read failed, codec is not working..."); -@@ -231,19 +251,27 @@ +@@ -231,19 +251,27 @@ xmms_avcodec_init (xmms_xform_t *xform) data->samplerate = data->codecctx->sample_rate; data->channels = data->codecctx->channels; + data->sampleformat = xmms_avcodec_translate_sample_format (data->codecctx->sample_fmt); + if (data->sampleformat == XMMS_SAMPLE_FORMAT_UNKNOWN) { + avcodec_close (data->codecctx); + goto err; + } xmms_xform_outdata_type_add (xform, XMMS_STREAM_TYPE_MIMETYPE, "audio/pcm", XMMS_STREAM_TYPE_FMT_FORMAT, - XMMS_SAMPLE_FORMAT_S16, + data->sampleformat, XMMS_STREAM_TYPE_FMT_CHANNELS, data->channels, XMMS_STREAM_TYPE_FMT_SAMPLERATE, data->samplerate, XMMS_STREAM_TYPE_END); - XMMS_DBG ("Decoder '%s' initialized successfully!", codec->name); + XMMS_DBG ("Decoder %s at rate %d with %d channels of format %s initialized", + codec->name, data->codecctx->sample_rate, + data->codecctx->channels, + av_get_sample_fmt_name (data->codecctx->sample_fmt)); return TRUE; -@@ -251,6 +279,9 @@ +@@ -251,6 +279,9 @@ err: if (data->codecctx) { av_free (data->codecctx); } + if (data->read_out_frame) { + avcodec_free_frame (&data->read_out_frame); + } g_string_free (data->outbuf, TRUE); g_free (data->extradata); g_free (data); -@@ -263,102 +294,24 @@ +@@ -263,102 +294,24 @@ xmms_avcodec_read (xmms_xform_t *xform, xmms_error_t *error) { xmms_avcodec_data_t *data; - char outbuf[AVCODEC_MAX_AUDIO_FRAME_SIZE]; - gint outbufsize, bytes_read = 0; guint size; data = xmms_xform_private_data_get (xform); g_return_val_if_fail (data, -1); - size = MIN (data->outbuf->len, len); - while (size == 0) { - AVPacket packet; - av_init_packet (&packet); + while (0 == (size = MIN (data->outbuf->len, len))) { + gint res; if (data->no_demuxer || data->buffer_length == 0) { - gint read_total; - - bytes_read = xmms_xform_read (xform, - (gchar *) (data->buffer + data->buffer_length), - data->buffer_size - data->buffer_length, - error); - - if (bytes_read < 0) { - XMMS_DBG ("Error while reading data"); - return bytes_read; - } else if (bytes_read == 0) { - XMMS_DBG ("EOF"); - return 0; - } -+ gint bytes_read; - +- - read_total = bytes_read; - - /* If we have a demuxer plugin, make sure we read the whole packet */ - while (read_total == data->buffer_size && !data->no_demuxer) { - /* multiply the buffer size and try to read again */ - data->buffer = g_realloc (data->buffer, data->buffer_size * 2); - bytes_read = xmms_xform_read (xform, - (gchar *) data->buffer + - data->buffer_size, - data->buffer_size, - error); - data->buffer_size *= 2; - - if (bytes_read < 0) { - XMMS_DBG ("Error while reading data"); - return bytes_read; - } - - read_total += bytes_read; - - if (read_total < data->buffer_size) { - /* finally double the buffer size for performance reasons, the - * hotspot handling likes to fit two frames in the buffer */ - data->buffer = g_realloc (data->buffer, data->buffer_size * 2); - data->buffer_size *= 2; - XMMS_DBG ("Reallocated avcodec internal buffer to be %d bytes", - data->buffer_size); - - break; - } - } - - /* Update the buffer length */ - data->buffer_length += read_total; -+ bytes_read = xmms_avcodec_internal_read_some (xform, data, error); -+ if (bytes_read <= 0) { return bytes_read; } - } - +- } +- - packet.data = data->buffer; - packet.size = data->buffer_length; - - outbufsize = sizeof (outbuf); - bytes_read = avcodec_decode_audio3 (data->codecctx, (short *) outbuf, - &outbufsize, &packet); - - /* The DTS decoder of ffmpeg is buggy and always returns - * the input buffer length, get frame length from header */ - if (!strcmp (data->codec_id, "dca") && bytes_read > 0) { - bytes_read = ((int)data->buffer[5] << 12) | - ((int)data->buffer[6] << 4) | - ((int)data->buffer[7] >> 4); - bytes_read = (bytes_read & 0x3fff) + 1; - } - - if (bytes_read < 0 || bytes_read > data->buffer_length) { - XMMS_DBG ("Error decoding data!"); - return -1; - } else if (bytes_read != data->buffer_length) { - g_memmove (data->buffer, - data->buffer + bytes_read, - data->buffer_length - bytes_read); - } - - data->buffer_length -= bytes_read; -- ++ gint bytes_read; + - if (outbufsize > 0) { - g_string_append_len (data->outbuf, outbuf, outbufsize); -- } -- ++ bytes_read = xmms_avcodec_internal_read_some (xform, data, error); ++ if (bytes_read <= 0) { return bytes_read; } + } + - size = MIN (data->outbuf->len, len); + res = xmms_avcodec_internal_decode_some (data); + if (res < 0) { return res; } + if (res > 0) { xmms_avcodec_internal_append (data); } } memcpy (buf, data->outbuf->str, size); -@@ -371,8 +324,6 @@ +@@ -371,8 +324,6 @@ static gint64 xmms_avcodec_seek (xmms_xform_t *xform, gint64 samples, xmms_xform_seek_mode_t whence, xmms_error_t *err) { xmms_avcodec_data_t *data; - char outbuf[AVCODEC_MAX_AUDIO_FRAME_SIZE]; - gint outbufsize, bytes_read = 0; gint64 ret = -1; g_return_val_if_fail (xform, -1); -@@ -390,23 +341,11 @@ +@@ -390,23 +341,11 @@ xmms_avcodec_seek (xmms_xform_t *xform, /* The buggy ape decoder doesn't flush buffers, so we need to finish decoding * the frame before seeking to avoid segfaults... this hack sucks */ + /* FIXME: Is ^^^ still true? */ while (data->buffer_length > 0) { - AVPacket packet; - av_init_packet (&packet); - packet.data = data->buffer; - packet.size = data->buffer_length; - - outbufsize = sizeof (outbuf); - bytes_read = avcodec_decode_audio3 (data->codecctx, (short *) outbuf, - &outbufsize, &packet); - - if (bytes_read < 0 || bytes_read > data->buffer_length) { - XMMS_DBG ("Error decoding data!"); + if (xmms_avcodec_internal_decode_some (data) < 0) { return -1; } - - data->buffer_length -= bytes_read; - g_memmove (data->buffer, data->buffer + bytes_read, data->buffer_length); } ret = xmms_xform_seek (xform, samples, whence, err); -@@ -420,3 +359,178 @@ +@@ -420,3 +359,178 @@ xmms_avcodec_seek (xmms_xform_t *xform, return ret; } + +static xmms_sample_format_t +xmms_avcodec_translate_sample_format (enum AVSampleFormat av_sample_format) +{ + switch (av_sample_format) { + case AV_SAMPLE_FMT_U8: + case AV_SAMPLE_FMT_U8P: + return XMMS_SAMPLE_FORMAT_U8; + case AV_SAMPLE_FMT_S16: + case AV_SAMPLE_FMT_S16P: + return XMMS_SAMPLE_FORMAT_S16; + case AV_SAMPLE_FMT_S32: + case AV_SAMPLE_FMT_S32P: + return XMMS_SAMPLE_FORMAT_S32; + case AV_SAMPLE_FMT_FLT: + case AV_SAMPLE_FMT_FLTP: + return XMMS_SAMPLE_FORMAT_FLOAT; + case AV_SAMPLE_FMT_DBL: + case AV_SAMPLE_FMT_DBLP: + return XMMS_SAMPLE_FORMAT_DOUBLE; + default: + XMMS_DBG ("AVSampleFormat (%i: %s) not supported.", av_sample_format, + av_get_sample_fmt_name (av_sample_format)); + return XMMS_SAMPLE_FORMAT_UNKNOWN; + } +} + +/* +Read some data from our source of data to data->buffer, updating buffer_length +and buffer_size as needed. + +Returns: on error: negative + on EOF: zero + otherwise: number of bytes read. +*/ +static gint +xmms_avcodec_internal_read_some (xmms_xform_t *xform, + xmms_avcodec_data_t *data, + xmms_error_t *error) +{ + gint bytes_read, read_total; + + bytes_read = xmms_xform_read (xform, + (gchar *) (data->buffer + data->buffer_length), + data->buffer_size - data->buffer_length, + error); + + if (bytes_read < 0) { + XMMS_DBG ("Error while reading data"); + return bytes_read; + } else if (bytes_read == 0) { + XMMS_DBG ("EOF"); + return 0; + } + + read_total = bytes_read; + + /* If we have a demuxer plugin, make sure we read the whole packet */ + while (read_total == data->buffer_size && !data->no_demuxer) { + /* multiply the buffer size and try to read again */ + data->buffer = g_realloc (data->buffer, data->buffer_size * 2); + bytes_read = xmms_xform_read (xform, + (gchar *) data->buffer + + data->buffer_size, + data->buffer_size, + error); + data->buffer_size *= 2; + + if (bytes_read < 0) { + XMMS_DBG ("Error while reading data"); + return bytes_read; + } + + read_total += bytes_read; + + if (read_total < data->buffer_size) { + /* finally double the buffer size for performance reasons, the + * hotspot handling likes to fit two frames in the buffer */ + data->buffer = g_realloc (data->buffer, data->buffer_size * 2); + data->buffer_size *= 2; + XMMS_DBG ("Reallocated avcodec internal buffer to be %d bytes", + data->buffer_size); + + break; + } + } + + /* Update the buffer length */ + data->buffer_length += read_total; + + return read_total; +} + +/* +Decode some data from data->buffer[0..data->buffer_length-1] to +data->read_out_frame + +Returns: on error: negative + on no new data produced: zero + otherwise: positive + +FIXME: data->buffer should be at least data->buffer_length + +FF_INPUT_BUFFER_PADDING_SIZE long. +*/ +static gint +xmms_avcodec_internal_decode_some (xmms_avcodec_data_t *data) +{ + int got_frame = 0; + gint bytes_read = 0; + AVPacket packet; + + av_init_packet (&packet); + packet.data = data->buffer; + packet.size = data->buffer_length; + + /* clear buffers and reset fields to defaults */ + av_frame_unref (data->read_out_frame); + + bytes_read = avcodec_decode_audio4 ( + data->codecctx, data->read_out_frame, &got_frame, &packet); + + /* The DTS decoder of ffmpeg is buggy and always returns + * the input buffer length, get frame length from header */ + /* FIXME: Is ^^^^ still true? */ + if (!strcmp (data->codec_id, "dca") && bytes_read > 0) { + bytes_read = ((int)data->buffer[5] << 12) | + ((int)data->buffer[6] << 4) | + ((int)data->buffer[7] >> 4); + bytes_read = (bytes_read & 0x3fff) + 1; + } + + if (bytes_read < 0 || bytes_read > data->buffer_length) { + XMMS_DBG ("Error decoding data!"); + return -1; + } + + if (bytes_read < data->buffer_length) { + data->buffer_length -= bytes_read; + g_memmove (data->buffer, + data->buffer + bytes_read, + data->buffer_length); + } else { + data->buffer_length = 0; + } + + return got_frame ? 1 : 0; +} + +static void +xmms_avcodec_internal_append (xmms_avcodec_data_t *data) +{ + enum AVSampleFormat fmt = (enum AVSampleFormat) data->read_out_frame->format; + int samples = data->read_out_frame->nb_samples; + int channels = data->codecctx->channels; + int bps = av_get_bytes_per_sample (fmt); + + if (av_sample_fmt_is_planar (fmt)) { + /* Convert from planar to packed format */ + gint i, j; + + for (i = 0; i < samples; i++) { + for (j = 0; j < channels; j++) { + g_string_append_len ( + data->outbuf, + (gchar *) (data->read_out_frame->extended_data[j] + i*bps), + bps + ); + } + } + } else { + g_string_append_len (data->outbuf, + (gchar *) data->read_out_frame->extended_data[0], + samples * channels * bps); + } +} Index: head/audio/xmms2/files/patch-src_plugins_avcodec_avcodec__compat.h =================================================================== --- head/audio/xmms2/files/patch-src_plugins_avcodec_avcodec__compat.h (revision 395642) +++ head/audio/xmms2/files/patch-src_plugins_avcodec_avcodec__compat.h (revision 395643) @@ -1,69 +1,69 @@ ---- src/plugins/avcodec/avcodec_compat.h.orig 2011-10-20 21:26:08.000000000 +0200 -+++ src/plugins/avcodec/avcodec_compat.h 2014-02-27 18:38:22.000000000 +0100 +--- src/plugins/avcodec/avcodec_compat.h.orig 2011-10-20 19:26:08 UTC ++++ src/plugins/avcodec/avcodec_compat.h @@ -1,7 +1,7 @@ /** @file avcodec_compat.h * Compatibility header for libavcodec backwards compatibility * - * Copyright (C) 2011 XMMS2 Team + * Copyright (C) 2011-2014 XMMS2 Team * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,47 +21,16 @@ # include "avcodec.h" #endif -/* Map avcodec_decode_audio2 into the deprecated version - * avcodec_decode_audio in versions earlier than 51.28 */ -#if LIBAVCODEC_VERSION_INT < 0x331c00 -# define avcodec_decode_audio2 avcodec_decode_audio -+/* Map avcodec_free_frame to av_freep if the former doesn't exist. -+ * (This is in versions earlier than 54.28.0 (libav) or 54.59.100 (ffmpeg)) */ -+#if ! HAVE_AVCODEC_FREE_FRAME -+# define avcodec_free_frame av_freep - #endif - +-#endif +- -/* Handle API change that happened in libavcodec 52.00 */ -#if LIBAVCODEC_VERSION_INT < 0x340000 -# define CONTEXT_BPS(codecctx) (codecctx)->bits_per_sample -#else -# define CONTEXT_BPS(codecctx) (codecctx)->bits_per_coded_sample -#endif - -/* Before 52.23 AVPacket was defined in avformat.h which we - * do not want to depend on, so we define part of it manually - * on versions smaller than 52.23 (this makes me cry) */ -#if LIBAVCODEC_VERSION_INT < 0x341700 -typedef struct AVPacket { - uint8_t *data; - int size; -} AVPacket; -#endif - -/* Same thing as above for av_init_packet and version 52.25 */ -#if LIBAVCODEC_VERSION_INT < 0x341900 -# define av_init_packet(pkt) do { \ - (pkt)->data = NULL; \ - (pkt)->size = 0; \ - } while(0) -+/* Map av_frame_alloc, av_frame_unref, av_frame_free into their -+ * deprecated versions in versions earlier than 55.28.1 */ -+#if LIBAVCODEC_VERSION_INT < 0x371c01 -+# define av_frame_alloc avcodec_alloc_frame -+# define av_frame_unref avcodec_get_frame_defaults -+# define av_frame_free avcodec_free_frame - #endif +-#endif - -/* Map avcodec_decode_audio3 into the deprecated version - * avcodec_decode_audio2 in versions earlier than 52.26 */ -#if LIBAVCODEC_VERSION_INT < 0x341a00 -# define avcodec_decode_audio3(avctx, samples, frame_size_ptr, avpkt) \ - avcodec_decode_audio2(avctx, samples, frame_size_ptr, \ - (avpkt)->data, (avpkt)->size) --#endif -- ++/* Map avcodec_free_frame to av_freep if the former doesn't exist. ++ * (This is in versions earlier than 54.28.0 (libav) or 54.59.100 (ffmpeg)) */ ++#if ! HAVE_AVCODEC_FREE_FRAME ++# define avcodec_free_frame av_freep + #endif + -/* Handle API change that happened in libavcodec 52.64 */ -#if LIBAVCODEC_VERSION_INT < 0x344000 -# define AVMEDIA_TYPE_AUDIO CODEC_TYPE_AUDIO --#endif ++/* Map av_frame_alloc, av_frame_unref, av_frame_free into their ++ * deprecated versions in versions earlier than 55.28.1 */ ++#if LIBAVCODEC_VERSION_INT < 0x371c01 ++# define av_frame_alloc avcodec_alloc_frame ++# define av_frame_unref avcodec_get_frame_defaults ++# define av_frame_free avcodec_free_frame + #endif - Index: head/audio/xmms2/files/patch-src_plugins_musepack_wscript =================================================================== --- head/audio/xmms2/files/patch-src_plugins_musepack_wscript (nonexistent) +++ head/audio/xmms2/files/patch-src_plugins_musepack_wscript (revision 395643) @@ -0,0 +1,11 @@ +--- src/plugins/musepack/wscript.orig 2011-10-20 19:26:08 UTC ++++ src/plugins/musepack/wscript +@@ -8,7 +8,7 @@ def plugin_configure(conf): + conf.check_cc(header_name="mpcdec/mpcdec.h", defines="HAVE_MPCDEC_OLD", + uselib_store="mpcdec") + +- conf.check_cc(lib="mpcdec", uselib_store="mpcdec") ++ conf.check_cc(lib="mpcdec", uselib="math", uselib_store="mpcdec") + + configure, build = plugin("musepack", configure=plugin_configure, + libs=["mpcdec"]) Property changes on: head/audio/xmms2/files/patch-src_plugins_musepack_wscript ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/audio/xmms2/files/patch-wscript =================================================================== --- head/audio/xmms2/files/patch-wscript (revision 395642) +++ head/audio/xmms2/files/patch-wscript (revision 395643) @@ -1,40 +1,40 @@ ---- wscript.orig 2011-10-20 21:26:08.000000000 +0200 -+++ wscript 2013-05-24 16:57:29.409207485 +0200 -@@ -131,7 +131,8 @@ +--- wscript.orig 2011-10-20 19:26:08 UTC ++++ wscript +@@ -131,7 +131,8 @@ def build(bld): VERSION = bld.env.VERSION ) - bld.install_files('${SHAREDDIR}', "mind.in.a.box-lament_snipplet.ogg") + if bld.env.BUILD_XMMS2D: + bld.install_files('${SHAREDDIR}', "mind.in.a.box-lament_snipplet.ogg") bld.add_post_fun(shutdown) -@@ -295,9 +296,6 @@ +@@ -295,9 +296,6 @@ def configure(conf): conf.msg("uncommited changed", changed and "yes" or "no") conf.env.VERSION = "%s (git commit: %s%s)" % (BASEVERSION, nam, dirty) - conf.env.append_unique('CFLAGS', ['-g', '-O0']) - conf.env.append_unique('CXXFLAGS', ['-g', '-O0']) - if conf.options.with_profiling: conf.env.with_profiling = True conf.env.append_unique('CFLAGS', ['--coverage']) -@@ -330,7 +328,7 @@ +@@ -330,7 +328,7 @@ def configure(conf): conf.env.PKGCONFIGDIR = conf.options.pkgconfigdir Logs.pprint('Normal', conf.env.PKGCONFIGDIR) #XXX What is it ? else: - conf.env.PKGCONFIGDIR = os.path.join(conf.env.LIBDIR, 'pkgconfig') + conf.env.PKGCONFIGDIR = os.path.join(conf.env.PREFIX, 'libdata', 'pkgconfig') if conf.options.config_prefix: for d in conf.options.config_prefix: -@@ -339,6 +337,8 @@ +@@ -339,6 +337,8 @@ def configure(conf): conf.env.prepend_value('LIBPATH', os.path.join(d, 'lib')) conf.env.prepend_value('CPPPATH', os.path.join(d, 'include')) + conf.env.prepend_value('LIBPATH', "%%WRKSRC%%/_build_/src/clients/lib/xmmsclient") + if Options.platform != 'win32': conf.env.append_unique('CFLAGS_cstlib', ['-fPIC', '-DPIC']) conf.env.append_unique('CPPFLAGS_cxxshlib', ['-fPIC', '-DPIC']) Index: head/audio/xmms2/pkg-plist =================================================================== --- head/audio/xmms2/pkg-plist (revision 395642) +++ head/audio/xmms2/pkg-plist (revision 395643) @@ -1,154 +1,154 @@ bin/nyxmms2 %%VISUAL%%bin/vistest %%VISUAL%%bin/vistest-fft bin/xmms2 %%ET%%bin/xmms2-et -%%MDNS_AVAHI%%bin/xmms2-find-avahi +%%MDNS%%%%MDNS_AVAHI%%bin/xmms2-find-avahi bin/xmms2-launcher %%VISUAL%%bin/xmms2-libvisual -%%MDNS_AVAHI%%bin/xmms2-mdns-avahi -%%MDNS_APPLE%%bin/xmms2-mdns-dnssd +%%MDNS%%%%MDNS_AVAHI%%bin/xmms2-mdns-avahi +%%MDNS%%%%MDNS_APPLE%%bin/xmms2-mdns-dnssd %%FAM%%bin/xmms2-mlib-updater %%VISUAL%%%%VORBIS%%bin/xmms2-ripper bin/xmms2d %%INCLUDEDIR%%/xmms/xmms_bindata.h %%INCLUDEDIR%%/xmms/xmms_config.h %%INCLUDEDIR%%/xmms/xmms_error.h %%INCLUDEDIR%%/xmms/xmms_ipc.h %%INCLUDEDIR%%/xmms/xmms_log.h %%INCLUDEDIR%%/xmms/xmms_medialib.h %%INCLUDEDIR%%/xmms/xmms_object.h %%INCLUDEDIR%%/xmms/xmms_outputplugin.h %%INCLUDEDIR%%/xmms/xmms_plugin.h %%INCLUDEDIR%%/xmms/xmms_sample.h %%INCLUDEDIR%%/xmms/xmms_streamtype.h %%INCLUDEDIR%%/xmms/xmms_util.h %%INCLUDEDIR%%/xmms/xmms_xformplugin.h %%INCLUDEDIR%%/xmmsc/xmmsc_compiler.h %%INCLUDEDIR%%/xmmsc/xmmsc_errorcodes.h %%INCLUDEDIR%%/xmmsc/xmmsc_idnumbers.h %%INCLUDEDIR%%/xmmsc/xmmsc_ipc_msg.h %%INCLUDEDIR%%/xmmsc/xmmsc_ipc_transport.h %%INCLUDEDIR%%/xmmsc/xmmsc_sockets.h %%INCLUDEDIR%%/xmmsc/xmmsc_stdbool.h %%INCLUDEDIR%%/xmmsc/xmmsc_stdint.h %%INCLUDEDIR%%/xmmsc/xmmsc_stringport.h %%INCLUDEDIR%%/xmmsc/xmmsc_strlist.h %%INCLUDEDIR%%/xmmsc/xmmsc_unistd.h %%INCLUDEDIR%%/xmmsc/xmmsc_util.h %%INCLUDEDIR%%/xmmsc/xmmsc_visualization.h %%INCLUDEDIR%%/xmmsc/xmmsv.h %%INCLUDEDIR%%/xmmsc/xmmsv_bitbuffer.h %%INCLUDEDIR%%/xmmsc/xmmsv_build.h %%INCLUDEDIR%%/xmmsc/xmmsv_coll.h %%INCLUDEDIR%%/xmmsc/xmmsv_deprecated.h %%INCLUDEDIR%%/xmmsc/xmmsv_dict.h %%INCLUDEDIR%%/xmmsc/xmmsv_general.h %%INCLUDEDIR%%/xmmsc/xmmsv_list.h %%INCLUDEDIR%%/xmmsc/xmmsv_util.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++-glib.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/bindata.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/client.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/coll.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/collection.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/config.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/dict.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/exceptions.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/helpers.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/list.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/listener.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/mainloop.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/medialib.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/playback.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/playlist.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/result.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/signal.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/stats.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/typedefs.h %%INCLUDEDIR%%/xmmsclient/xmmsclient++/xform.h %%INCLUDEDIR%%/xmmsclient/xmmsclient-cf.h %%INCLUDEDIR%%/xmmsclient/xmmsclient-ecore.h %%INCLUDEDIR%%/xmmsclient/xmmsclient-glib.h %%INCLUDEDIR%%/xmmsclient/xmmsclient-qt.h %%INCLUDEDIR%%/xmmsclient/xmmsclient.h lib/libxmmsclient-glib.so lib/libxmmsclient-glib.so.1 lib/libxmmsclient-glib.so.1.0.0 lib/libxmmsclient.so lib/libxmmsclient.so.6 lib/libxmmsclient.so.6.0.0 %%AIRPLAY%%%%LIBDIR%%/libxmms_airplay.so %%AO%%%%LIBDIR%%/libxmms_ao.so %%LIBDIR%%/libxmms_apefile.so %%LIBDIR%%/libxmms_asf.so %%LIBDIR%%/libxmms_asx.so %%AVCODEC%%%%LIBDIR%%/libxmms_avcodec.so %%CDDA%%%%LIBDIR%%/libxmms_cdda.so %%LIBDIR%%/libxmms_cue.so %%CURL%%%%LIBDIR%%/libxmms_curl.so %%LIBDIR%%/libxmms_daap.so %%LIBDIR%%/libxmms_diskwrite.so %%LIBDIR%%/libxmms_equalizer.so %%FAAD%%%%LIBDIR%%/libxmms_faad.so %%LIBDIR%%/libxmms_file.so %%FLAC%%%%LIBDIR%%/libxmms_flac.so %%LIBDIR%%/libxmms_flv.so %%GME%%%%LIBDIR%%/libxmms_gme.so %%GVFS%%%%LIBDIR%%/libxmms_gvfs.so %%LIBDIR%%/libxmms_html.so %%ICES%%%%LIBDIR%%/libxmms_ices.so %%CURL%%%%LIBDIR%%/libxmms_icymetaint.so %%LIBDIR%%/libxmms_id3v2.so %%JACK%%%%LIBDIR%%/libxmms_jack.so %%LIBDIR%%/libxmms_karaoke.so %%LIBDIR%%/libxmms_m3u.so -%%MAC%%%%LIBDIR%%/libxmms_mac.so +%%APE%%%%LIBDIR%%/libxmms_mac.so %%MAD%%%%LIBDIR%%/libxmms_mad.so %%MMS%%%%LIBDIR%%/libxmms_mms.so %%MODPLUG%%%%LIBDIR%%/libxmms_modplug.so %%MPG123%%%%LIBDIR%%/libxmms_mpg123.so %%MUSEPACK%%%%LIBDIR%%/libxmms_musepack.so %%FAAD%%%%LIBDIR%%/libxmms_mp4.so %%LIBDIR%%/libxmms_normalize.so %%LIBDIR%%/libxmms_null.so %%LIBDIR%%/libxmms_nulstripper.so %%OFA%%%%LIBDIR%%/libxmms_ofa.so %%LIBDIR%%/libxmms_oss.so %%LIBDIR%%/libxmms_pls.so -%%PULSE%%%%LIBDIR%%/libxmms_pulse.so +%%PULSEAUDIO%%%%LIBDIR%%/libxmms_pulse.so %%LIBDIR%%/libxmms_replaygain.so %%XML%%%%LIBDIR%%/libxmms_rss.so %%SAMBA%%%%LIBDIR%%/libxmms_samba.so %%SID%%%%LIBDIR%%/libxmms_sid.so %%SNDFILE%%%%LIBDIR%%/libxmms_sndfile.so %%SPEEX%%%%LIBDIR%%/libxmms_speex.so %%TREMOR%%%%LIBDIR%%/libxmms_tremor.so %%LIBDIR%%/libxmms_tta.so %%VOCODER%%%%LIBDIR%%/libxmms_vocoder.so %%VORBIS%%%%LIBDIR%%/libxmms_vorbis.so %%LIBDIR%%/libxmms_wave.so %%WAVPACK%%%%LIBDIR%%/libxmms_wavpack.so %%XML%%%%LIBDIR%%/libxmms_xml.so %%XML%%%%LIBDIR%%/libxmms_xspf.so libdata/pkgconfig/xmms2-client-glib.pc libdata/pkgconfig/xmms2-client.pc libdata/pkgconfig/xmms2-plugin.pc %%ET%%man/man1/xmms2-et.1.gz man/man1/xmms2-launcher.1.gz -%%MDNS_AVAHI%%man/man1/xmms2-mdns-avahi.1.gz +%%MDNS%%%%MDNS_AVAHI%%man/man1/xmms2-mdns-avahi.1.gz man/man1/xmms2.1.gz man/man1/xmms2d.1.gz share/pixmaps/xmms2-128.png share/pixmaps/xmms2-16.png share/pixmaps/xmms2-32.png share/pixmaps/xmms2-48.png share/pixmaps/xmms2-black-on-white.svg share/pixmaps/xmms2-white-on-black.svg share/pixmaps/xmms2.svg %%DATADIR%%/mind.in.a.box-lament_snipplet.ogg %%ET%%%%DATADIR%%/scripts/startup.d/xmms2-et-launcher.sh -%%MDNS_AVAHI%%%%DATADIR%%/scripts/startup.d/xmms2-mdns-launcher.sh -%%MDNS_APPLE%%%%DATADIR%%/scripts/startup.d/xmms2-mdns-launcher.sh +%%MDNS%%%%MDNS_AVAHI%%%%DATADIR%%/scripts/startup.d/xmms2-mdns-launcher.sh +%%MDNS%%%%MDNS_APPLE%%%%DATADIR%%/scripts/startup.d/xmms2-mdns-launcher.sh %%FAM%%%%DATADIR%%/scripts/startup.d/xmms2-mlib-updater.sh @dir %%DATADIR%%/scripts/startup.d