freebsd-ports/audio/deadbeef/Makefile

233 lines
7 KiB
Makefile
Raw Normal View History

PORTNAME= deadbeef
PORTVERSION= 0.7.2
PORTREVISION= 24
CATEGORIES= audio
2014-08-07 12:27:34 +02:00
MASTER_SITES= SF/${PORTNAME}/
MAINTAINER= danfe@FreeBSD.org
COMMENT= Ultimate music player for Unix-like systems
WWW= http://deadbeef.sourceforge.net/
2014-07-30 19:51:18 +02:00
LICENSE= GPLv2 LGPL21
LICENSE_COMB= dual
GNU_CONFIGURE= yes
USES= compiler:c11 desktop-file-utils gettext gmake gnome iconv \
libtool pkgconfig shebangfix tar:bzip2
USE_LDCONFIG= yes
CONFIGURE_ARGS= --disable-alsa --disable-nullout --disable-static
CPPFLAGS+= -I../dumb/dumb-kode54/include -I../../plugins/libmp4ff \
-I../../plugins/gme/game-music-emu-0.6pre \
-I./sidplay-libs/libsidplay/include/sidplay \
-I${LOCALBASE}/include
CFLAGS+= -Wno-narrowing
LDFLAGS_i386= -Wl,-z,notext
Support LIBS like LDFLAGS. - Add LIBS="${LIBS}" to MAKE_ENV and CONFIGURE_ENV. - Add an option helper for LIBS. - Adjust all ports that already use LIBS. Also remove references to PTHREAD_CFLAGS and PTHREAD_LIBS while here. - Some ports did not support having a LIBS environment variable and required additional patches. Somewhat simplified a linker command line looks like: ${CC} ${src_LDFLAGS} ${LDFLAGS} ${src_LIBS} ${LIBS} where src_LDFLAGS and src_LIBS are controlled by upstream and LDFLAGS and LIBS can be controlled by us. If possible -L and -l flags need to be added to LIBS to make sure they appear after any -L and -l flags set by upstream. Many ports currently add -L${LOCALBASE}/lib to LDFLAGS but this may appear too early on the command line causing installed libraries to be linked in instead of freshly built ones. Additional changes: benchmarks/netio: Replace WITH_IPV6 with an IPV6 option. comms/gnokii: Replace some patches with USES=pathfix. Also remove -fPIC. graphics/gimageview: USES=libtool and install desktop file in DESKTOPDIR. graphics/visionworkbench: Remove FreeBSD 7 support. multimedia/libmovtar: New LIB_DEPENDS syntax. multimedia/opencinematools: Use standard do-build. net/siproxd: USES=libtool:keepla (port actually needs .la files for plugins) net-mgmt/nagios: Remove -fPIC. net-mgmt/nagios4: Remove -fPIC. print/cups-base: Only add -lssp_nonshared on i386 and OSVERSION < 1000036. security/p11-kit: Replace PTHREAD_LIBS in CONFIGURE_ENV with ac_cv_func_pthread_mutexattr_init=no in CONFIGURE_ARGS. This skips a test in configure that falsely detects pthread_mutexattr_init in our libc. sysutils/dar: Fix iconv detection. x11/rxvt-unicode: Remove -lstdc++ and patch configure to remove a FreeBSD hack and use $CXX as linker as on other platforms. PR: 190592 Exp-run by: antoine Approved by: portmgr (antoine)
2014-06-11 16:49:59 +02:00
LIBS+= -L${LOCALBASE}/lib -lexecinfo -lintl
USE_GNOME= intltool
2013-05-07 08:45:39 +02:00
SHEBANG_FILES= yasmwrapper.sh
INSTALL_TARGET= install-strip
OPTIONS_DEFINE= PULSEAUDIO GUI VFS LASTFM ART SUPEREQ SID FFAP VTX \
HOTKEYS OGG FFMPEG FLAC SNDFILE WAVPACK CDDA GME DUMB NOTIFY \
MUSEPACK WILDMIDI TTA DCA AAC MMS SHN SHELLEXEC NLS M3U \
PSF ADPLUG DSP MONO2STEREO CONVERTER VFS_ZIP ALAC PLTBROWSER \
WMA SC68
OPTIONS_DEFAULT=MAD GTK2 VFS LASTFM ART SUPEREQ SID FFAP VTX HOSTKEYS \
OGG FLAC SNDFILE WAVPACK CDDA GME DUMB NOTIFY MUSEPACK \
WILDMIDI TTA DCA AAC MMS SHN SHELLEXEC M3U PSF ADPLUG DSP \
MONO2STEREO CONVERTER VFS_ZIP HOTKEYS ALAC PLTBROWSER WMA SC68
PULSEAUDIO_DESC= PulseAudio output plugin (unsupported)
GUI_DESC= Standard GUI plugin
VFS_DESC= HTTP streaming VFS plugin
LASTFM_DESC= Last.fm/Libre.fm scrobbler plugin
ART_DESC= Cover artwork loader plugin
SUPEREQ_DESC= SuperEQ DSP plugin (equalizer)
SID_DESC= Commodore 64 SID music player plugin
FFAP_DESC= ${APE_DESC}
VTX_DESC= VTX ZX-Spectrum music player plugin
ADPLUG_DESC= AdPlug audio format (OPL2/OPL3) support
HOTKEYS_DESC= Local and global hotkeys support
GME_DESC= Chiptune music support (based on GME)
DUMB_DESC= D.U.M.B. plugin for MOD, S3M, etc.
NOTIFY_DESC= OSD notification support in GTKUI plugin
WILDMIDI_DESC= WildMIDI synthesizer plugin
SC68_DESC= sc68 Atari ST And Amiga player
SHN_DESC= Shorten waveform encoder support
SHELLEXEC_DESC= Shell commands execution plugin
M3U_DESC= M3U and PLS playlist format support
PSF_DESC= AOSDK-based PSF(,QSF,SSF,DSF) plugin
DSP_DESC= High-quality sample rate conversion support
MONO2STEREO_DESC= Mono to stereo converter DSP plugin
CONVERTER_DESC= Plugin for converting files from/to any formats
VFS_ZIP_DESC= Play files directly from ZIP archives
PLTBROWSER_DESC= Playlist browser GUI plugin
OPTIONS_SUB= yes
OPTIONS_RADIO+= GUI
OPTIONS_RADIO_GUI= GTK2 GTK3
GUI_IMPLIES= CONVERTER
OPTIONS_GROUP+= MP3
OPTIONS_GROUP_MP3= MAD MPG123
MAD_LIB_DEPENDS= libmad.so:audio/libmad
MAD_CONFIGURE_OFF= --disable-libmad
MPG123_LIB_DEPENDS= libmpg123.so:audio/mpg123
MPG123_CONFIGURE_OFF= --disable-libmpg123
PULSEAUDIO_LIB_DEPENDS= libpulse.so:audio/pulseaudio
PULSEAUDIO_CONFIGURE_OFF= --disable-pulse
GTK2_USE= gnome=gtk20,glib20
GTK2_CONFIGURE_OFF= --disable-gtk2
GTK2_CONFIGURE_ON= --enable-gtk2
GTK2_VARS= GTK_VER=2
GTK2_IMPLIES= GUI
GTK3_USE= gnome=gtk30
GTK3_CONFIGURE_OFF= --disable-gtk3
GTK3_CONFIGURE_ON= --enable-gtk3
GTK3_VARS= GTK_VER=3
GTK3_IMPLIES= GUI
PLIST_SUB+= GTK_VER=${GTK_VER}
GUI_CONFIGURE_OFF= --disable-gtk2 --disable-gtk3
GUI_LIB_DEPENDS= libjansson.so:devel/jansson
VFS_LIB_DEPENDS= libcurl.so:ftp/curl
VFS_CONFIGURE_OFF= --disable-vfs-curl
LASTFM_LIB_DEPENDS= libcurl.so:ftp/curl
LASTFM_CONFIGURE_OFF= --disable-lfm
ART_LIB_DEPENDS= libcurl.so:ftp/curl \
libImlib2.so:graphics/imlib2
2015-06-22 20:33:20 +02:00
ART_USES= jpeg
ART_CONFIGURE_OFF= --disable-artwork --disable-artwork-imlib2
ART_IMPLIES= VFS
SUPEREQ_CONFIGURE_OFF= --disable-supereq
SID_CONFIGURE_OFF= --disable-sid
FFAP_BUILD_DEPENDS= yasm:devel/yasm
FFAP_CONFIGURE_OFF= --disable-ffap
VTX_CONFIGURE_OFF= --disable-vtx
ADPLUG_CONFIGURE_OFF= --disable-adplug
HOTKEYS_CONFIGURE_OFF= --disable-hotkeys
OGG_LIB_DEPENDS= libvorbis.so:audio/libvorbis
OGG_CONFIGURE_OFF= --disable-vorbis
FFMPEG_LIB_DEPENDS= libavcodec.so:multimedia/ffmpeg \
libavformat.so:multimedia/ffmpeg \
libavutil.so:multimedia/ffmpeg
FFMPEG_CONFIGURE_ENABLE= ffmpeg
FLAC_LIB_DEPENDS= libFLAC.so:audio/flac
FLAC_CONFIGURE_OFF= --disable-flac
SNDFILE_LIB_DEPENDS= libsndfile.so:audio/libsndfile
SNDFILE_CONFIGURE_OFF= --disable-sndfile
WAVPACK_LIB_DEPENDS= libwavpack.so:audio/wavpack
WAVPACK_CONFIGURE_OFF= --disable-wavpack
CDDA_LIB_DEPENDS= libcdio.so:sysutils/libcdio \
libcddb.so:audio/libcddb
CDDA_CONFIGURE_OFF= --disable-cdda
GME_CONFIGURE_OFF= --disable-gme
DUMB_CONFIGURE_OFF= --disable-dumb
NOTIFY_LIB_DEPENDS= libdbus-glib-1.so:devel/dbus-glib
NOTIFY_CONFIGURE_OFF= --disable-notify
MUSEPACK_CONFIGURE_OFF= --disable-musepack
WILDMIDI_RUN_DEPENDS= ${LOCALBASE}/share/freepats/crude.cfg:audio/freepats
WILDMIDI_CONFIGURE_OFF= --disable-wildmidi
TTA_CONFIGURE_OFF= --disable-tta
DCA_CONFIGURE_OFF= --disable-dca
AAC_LIB_DEPENDS= libfaad.so:audio/faad
AAC_CONFIGURE_OFF= --disable-aac
MMS_CONFIGURE_OFF= --disable-mms
SC68_CONFIGURE_ON= --enable-sc68
SC68_CONFIGURE_OFF= --disable-sc68
SHN_CONFIGURE_OFF= --disable-shn
SHELLEXEC_CONFIGURE_OFF= --disable-shellexec
NLS_CONFIGURE_OFF= --disable-nls
M3U_CONFIGURE_OFF= --disable-m3u
PSF_CONFIGURE_OFF= --disable-psf
DSP_LIB_DEPENDS= libsamplerate.so:audio/libsamplerate
DSP_CONFIGURE_OFF= --disable-src
MONO2STEREO_CONFIGURE_OFF= --disable-mono2stereo
CONVERTER_CONFIGURE_OFF= --disable-converter
VFS_ZIP_LIB_DEPENDS= libzip.so:archivers/libzip
VFS_ZIP_CONFIGURE_OFF= --disable-vfs-zip
2014-07-30 19:51:18 +02:00
ALAC_CONFIGURE_OFF= --disable-alac
PLTBROWSER_CONFIGURE_OFF= --disable-pltbrowser
WMA_CONFIGURE_OFF= --disable-wma
.include <bsd.port.options.mk>
.if !${PORT_OPTIONS:MGTK2} && !${PORT_OPTIONS:MGTK3}
PORT_OPTIONS:= ${PORT_OPTIONS:NGUI}
.endif
.if !${PORT_OPTIONS:MMAD} && !${PORT_OPTIONS:MMPG123}
CONFIGURE_ARGS+= --disable-mp3
PLIST_SUB+= MP3="@comment "
.else
PLIST_SUB+= MP3=""
.endif
post-patch:
# Do not link to libsupc++ which may be PIC-unsafe (breaks 64-bit arches)
@${REINPLACE_CMD} -e 's, -lsupc++,,' \
${WRKSRC}/plugins/adplug/Makefile.in \
${WRKSRC}/plugins/gme/Makefile.in \
${WRKSRC}/plugins/sid/Makefile.in \
${WRKSRC}/plugins/supereq/Makefile.in
@${REINPLACE_CMD} -e 's,/etc/timidity++/timidity-freepats.cfg:/etc/timidity/freepats.cfg:/etc/timidity/,${LOCALBASE}/share/,' \
${WRKSRC}/plugins/wildmidi/wildmidiplug.c
# Clang accepts `-msse2' command line option even on !x86, need better check
@${REINPLACE_CMD} -e '25177s,^,#include <xmmintrin.h>,' \
${WRKSRC}/configure
@${REINPLACE_CMD} -e '/chnresolv/s,const char,signed &,' \
${WRKSRC}/plugins/adplug/adplug/s3m.cpp \
${WRKSRC}/plugins/adplug/adplug/s3m.h
@${REINPLACE_CMD} -e "/sampleConvertTable/s,int8_t,u&, ; \
86,+1 { s,',,g; s,\\\\x,0x,g; }" \
${WRKSRC}/plugins/sid/sidplay-libs/libsidplay/src/xsid/xsid.cpp \
${WRKSRC}/plugins/sid/sidplay-libs/libsidplay/src/xsid/xsid.h
# Fix build with libzip-1.0
@${REINPLACE_CMD} 's,zip_file_t,zip_file_DB,g' \
${WRKSRC}/plugins/vfs_zip/vfs_zip.c
.include <bsd.port.mk>