Lines 2-13
Link Here
|
2 |
# $FreeBSD$ |
2 |
# $FreeBSD$ |
3 |
|
3 |
|
4 |
PORTNAME= cmus |
4 |
PORTNAME= cmus |
5 |
PORTVERSION= 2.6.0 |
5 |
PORTVERSION= 2.7.1 |
6 |
DISTVERSIONPREFIX= v |
6 |
DISTVERSIONPREFIX= v |
7 |
PORTREVISION= 3 |
|
|
8 |
CATEGORIES= audio |
7 |
CATEGORIES= audio |
9 |
|
8 |
|
10 |
MAINTAINER= h.skuhra@gmail.com |
9 |
MAINTAINER= t@tobik.me |
11 |
COMMENT= Console-based music player with really cool features |
10 |
COMMENT= Console-based music player with really cool features |
12 |
|
11 |
|
13 |
LICENSE= GPLv2 |
12 |
LICENSE= GPLv2 |
Lines 15-214
Link Here
|
15 |
|
14 |
|
16 |
USE_GITHUB= yes |
15 |
USE_GITHUB= yes |
17 |
|
16 |
|
18 |
USES= gmake pkgconfig iconv ncurses |
17 |
USES= gmake iconv ncurses pkgconfig |
19 |
HAS_CONFIGURE= yes |
18 |
HAS_CONFIGURE= yes |
20 |
CONFIGURE_ENV+= HOSTCC=${CC} |
19 |
CONFIGURE_ARGS= prefix=${PREFIX} mandir=${MANPREFIX}/man \ |
21 |
CONFIGURE_ARGS+=prefix=${PREFIX} mandir=${MANPREFIX}/man \ |
20 |
exampledir=${EXAMPLESDIR} |
22 |
exampledir=${EXAMPLESDIR} \ |
|
|
23 |
CONFIG_ALSA=n CONFIG_ARTS=n CONFIG_ROAR=n |
24 |
|
21 |
|
25 |
OPTIONS_DEFINE= AAC AO CDDB CDIO CUE DISCID FFMPEG FLAC JACK MAD MIKMOD \ |
22 |
# So the build does not use gcc for compiling ttman |
26 |
MODPLUG MP4 MUSEPACK OPUS PULSEAUDIO SAMPLERATE TREMOR \ |
23 |
CONFIGURE_ARGS+= HOSTCC=${CC} |
27 |
VORBIS WAVPACK |
|
|
28 |
OPTIONS_DEFAULT=AAC FFMPEG FLAC MAD MP4 VORBIS |
29 |
|
24 |
|
30 |
DISCID_DESC= DISCID support |
25 |
# Verbose build makes it easier to spot problems |
|
|
26 |
MAKE_ARGS= V=2 |
31 |
|
27 |
|
32 |
.include <bsd.port.options.mk> |
28 |
# Disable all configure options first. These will be overwritten by |
|
|
29 |
# enabled port options later. The args to cmus' configure script |
30 |
# follow shell value semantics i.e. later assignments overwrite |
31 |
# previous assignments. The options here appear in the same order as |
32 |
# ${WRKSRC}/configure --help. Please keep it that way. |
33 |
_CMUS_CONFIGURE_OPTS= CDDB CDIO DISCID FLAC MAD MODPLUG MIKMOD MPC \ |
34 |
VORBIS TREMOR OPUS WAV WAVPACK MP4 AAC FFMPEG \ |
35 |
VTX CUE ROAR PULSE ALSA JACK SAMPLERATE AO \ |
36 |
ARTS OSS SNDIO SUN WAVEOUT |
37 |
.for opt in ${_CMUS_CONFIGURE_OPTS} |
38 |
CONFIGURE_ARGS+= CONFIG_${opt}=n |
39 |
.endfor |
33 |
|
40 |
|
34 |
.if ${PORT_OPTIONS:MFLAC} |
41 |
OPTIONS_DEFAULT= AAC FFMPEG FLAC MAD MP4 OSS SNDIO VORBIS WAV |
35 |
LIB_DEPENDS+= libFLAC.so:audio/flac |
42 |
OPTIONS_SUB= yes |
36 |
CONFIGURE_ARGS+=CONFIG_FLAC=y |
|
|
37 |
PLIST_SUB+= FLAC="" |
38 |
.else |
39 |
CONFIGURE_ARGS+=CONFIG_FLAC=n |
40 |
PLIST_SUB+= FLAC="@comment " |
41 |
.endif |
42 |
|
43 |
|
43 |
.if ${PORT_OPTIONS:MMAD} |
44 |
OPTIONS_GROUP= OUT IN |
44 |
LIB_DEPENDS+= libmad.so:audio/libmad |
45 |
OPTIONS_GROUP_OUT= AO JACK OSS PULSEAUDIO SNDIO |
45 |
CONFIGURE_ARGS+=CONFIG_MAD=y |
46 |
OPTIONS_GROUP_IN= AAC CDDB CDIO CUE DISCID FFMPEG FLAC MAD MIKMOD \ |
46 |
PLIST_SUB+= MAD="" |
47 |
MODPLUG MP4 MUSEPACK OPUS SAMPLERATE TREMOR \ |
47 |
.else |
48 |
VORBIS WAV WAVPACK |
48 |
CONFIGURE_ARGS+=CONFIG_MAD=n |
|
|
49 |
PLIST_SUB+= MAD="@comment " |
50 |
.endif |
51 |
|
49 |
|
52 |
.if ${PORT_OPTIONS:MMODPLUG} |
50 |
DISCID_DESC= libdiscid CDDA identification support |
53 |
LIB_DEPENDS+= libmodplug.so:audio/libmodplug |
51 |
IN_DESC= Input plugins |
54 |
CONFIGURE_ARGS+=CONFIG_MODPLUG=y |
52 |
OUT_DESC= Output plugins |
55 |
PLIST_SUB+= MODPLUG="" |
|
|
56 |
.else |
57 |
CONFIGURE_ARGS+=CONFIG_MODPLUG=n |
58 |
PLIST_SUB+= MODPLUG="@comment " |
59 |
.endif |
60 |
|
53 |
|
61 |
.if ${PORT_OPTIONS:MMIKMOD} |
54 |
AAC_CONFIGURE_ON= CONFIG_AAC=y |
62 |
LIB_DEPENDS+= libmikmod.so:audio/libmikmod |
55 |
AAC_LIB_DEPENDS= libfaad.so:audio/faad |
63 |
CONFIGURE_ARGS+=CONFIG_MIKMOD=y |
|
|
64 |
PLIST_SUB+= MIKMOD="" |
65 |
.else |
66 |
PLIST_SUB+= MIKMOD="@comment " |
67 |
.endif |
68 |
|
56 |
|
69 |
.if ${PORT_OPTIONS:MMUSEPACK} |
57 |
AO_CONFIGURE_ON= CONFIG_AO=y |
70 |
LIB_DEPENDS+= libmpcdec.so:audio/musepack |
58 |
AO_LIB_DEPENDS= libao.so:audio/libao |
71 |
CONFIGURE_ARGS+=CONFIG_MPC=y |
|
|
72 |
PLIST_SUB+= MPC="" |
73 |
.else |
74 |
CONFIGURE_ARGS+=CONFIG_MPC=n |
75 |
PLIST_SUB+= MPC="@comment " |
76 |
.endif |
77 |
|
59 |
|
78 |
.if ${PORT_OPTIONS:MOPUS} |
60 |
CDDB_CONFIGURE_ON= CONFIG_CDDB=y |
79 |
LIB_DEPENDS+= libopusfile.so:audio/opusfile |
61 |
CDDB_LIB_DEPENDS= libcddb.so:audio/libcddb |
80 |
CONFIGURE_ARGS+=CONFIG_OPUS=y |
|
|
81 |
PLIST_SUB+= OPUS="" |
82 |
.else |
83 |
CONFIGURE_ARGS+=CONFIG_OPUS=n |
84 |
PLIST_SUB+= OPUS="@comment " |
85 |
.endif |
86 |
|
62 |
|
87 |
.if ${PORT_OPTIONS:MVORBIS} || ${PORT_OPTIONS:MTREMOR} |
63 |
CDIO_CONFIGURE_ON= CONFIG_CDIO=y |
88 |
LIB_DEPENDS+= libvorbisfile.so:audio/libvorbis |
64 |
CDIO_LIB_DEPENDS= libcdio_cdda.so:sysutils/libcdio-paranoia \ |
89 |
CONFIGURE_ARGS+=CONFIG_VORBIS=y |
65 |
libcdio.so:sysutils/libcdio |
90 |
PLIST_SUB+= VORBIS="" |
|
|
91 |
.else |
92 |
CONFIGURE_ARGS+=CONFIG_VORBIS=n |
93 |
PLIST_SUB+= VORBIS="@comment " |
94 |
.endif |
95 |
|
66 |
|
96 |
.if ${PORT_OPTIONS:MTREMOR} |
67 |
CUE_CONFIGURE_ON= CONFIG_CUE=y |
97 |
LIB_DEPENDS+= libvorbisidec.so:audio/libtremor |
68 |
CUE_LIB_DEPENDS= libcue.so:textproc/libcue |
98 |
CONFIGURE_ARGS+=CONFIG_TREMOR=y |
|
|
99 |
.endif |
100 |
|
69 |
|
101 |
.if ${PORT_OPTIONS:MMP4} |
70 |
DISCID_CONFIGURE_ON= CONFIG_DISCID=y |
102 |
LIB_DEPENDS+= libfaad.so:audio/faad |
71 |
DISCID_LIB_DEPENDS= libdiscid.so:audio/libdiscid |
103 |
LIB_DEPENDS+= libmp4v2.so:multimedia/mp4v2 |
|
|
104 |
CONFIGURE_ARGS+=CONFIG_MP4=y |
105 |
PLIST_SUB+= MP4="" |
106 |
.else |
107 |
CONFIGURE_ARGS+=CONFIG_MP4=n |
108 |
PLIST_SUB+= MP4="@comment " |
109 |
.endif |
110 |
|
72 |
|
111 |
.if ${PORT_OPTIONS:MAAC} |
73 |
FFMPEG_LIB_DEPENDS= libavcodec.so:multimedia/ffmpeg |
112 |
LIB_DEPENDS+= libfaad.so:audio/faad |
74 |
FFMPEG_CONFIGURE_ON= CONFIG_FFMPEG=y |
113 |
CONFIGURE_ARGS+=CONFIG_AAC=y |
|
|
114 |
PLIST_SUB+= AAC="" |
115 |
.else |
116 |
CONFIGURE_ARGS+=CONFIG_AAC=n |
117 |
PLIST_SUB+= AAC="@comment " |
118 |
.endif |
119 |
|
75 |
|
120 |
.if ${PORT_OPTIONS:MWAVPACK} |
76 |
FLAC_CONFIGURE_ON= CONFIG_FLAC=y |
121 |
LIB_DEPENDS+= libwavpack.so:audio/wavpack |
77 |
FLAC_LIB_DEPENDS= libFLAC.so:audio/flac |
122 |
CONFIGURE_ARGS+=CONFIG_WAVPACK=y |
|
|
123 |
PLIST_SUB+= WAVPACK="" |
124 |
.else |
125 |
CONFIGURE_ARGS+=CONFIG_WAVPACK=n |
126 |
PLIST_SUB+= WAVPACK="@comment " |
127 |
.endif |
128 |
|
78 |
|
129 |
.if ${PORT_OPTIONS:MFFMPEG} |
79 |
JACK_CONFIGURE_ON= CONFIG_JACK=y |
130 |
BUILD_DEPENDS+= ffmpeg>=2:multimedia/ffmpeg |
80 |
JACK_LIB_DEPENDS= libjack.so:audio/jack |
131 |
RUN_DEPENDS+= ffmpeg>=2:multimedia/ffmpeg |
|
|
132 |
CONFIGURE_ARGS+=CONFIG_FFMPEG=y |
133 |
PLIST_SUB+= FFMPEG="" |
134 |
.else |
135 |
CONFIGURE_ARGS+=CONFIG_FFMPEG=n |
136 |
PLIST_SUB+= FFMPEG="@comment " |
137 |
.endif |
138 |
|
81 |
|
139 |
.if ${PORT_OPTIONS:MAO} |
82 |
MAD_CONFIGURE_ON= CONFIG_MAD=y |
140 |
LIB_DEPENDS+= libao.so:audio/libao |
83 |
MAD_LIB_DEPENDS= libmad.so:audio/libmad |
141 |
CONFIGURE_ARGS+=CONFIG_AO=y |
|
|
142 |
PLIST_SUB+= AO="" |
143 |
.else |
144 |
CONFIGURE_ARGS+=CONFIG_AO=n |
145 |
PLIST_SUB+= AO="@comment " |
146 |
.endif |
147 |
|
84 |
|
148 |
.if ${PORT_OPTIONS:MPULSEAUDIO} |
85 |
MIKMOD_CONFIGURE_ON= CONFIG_MIKMOD=y |
149 |
LIB_DEPENDS+= libpulse.so:audio/pulseaudio |
86 |
MIKMOD_LIB_DEPENDS= libmikmod.so:audio/libmikmod |
150 |
CONFIGURE_ARGS+=CONFIG_PULSE=y |
|
|
151 |
PLIST_SUB+= PULSEAUDIO="" |
152 |
.else |
153 |
CONFIGURE_ARGS+=CONFIG_PULSE=n |
154 |
PLIST_SUB+= PULSEAUDIO="@comment " |
155 |
.endif |
156 |
|
87 |
|
157 |
.if ${PORT_OPTIONS:MCDDB} && ${PORT_OPTIONS:MCDIO} |
88 |
MODPLUG_CONFIGURE_ON= CONFIG_MODPLUG=y |
158 |
LIB_DEPENDS+= libcddb.so:audio/libcddb |
89 |
MODPLUG_LIB_DEPENDS= libmodplug.so:audio/libmodplug |
159 |
CONFIGURE_ARGS+=CONFIG_CDDB=y |
|
|
160 |
.else |
161 |
CONFIGURE_ARGS+=CONFIG_CDDB=n |
162 |
.endif |
163 |
|
90 |
|
164 |
.if ${PORT_OPTIONS:MCDIO} |
91 |
MP4_CONFIGURE_ON= CONFIG_MP4=y |
165 |
LIB_DEPENDS+= libcdio_cdda.so:sysutils/libcdio-paranoia |
92 |
MP4_LIB_DEPENDS= libfaad.so:audio/faad \ |
166 |
CONFIGURE_ARGS+=CONFIG_CDIO=y |
93 |
libmp4v2.so:multimedia/mp4v2 |
167 |
PLIST_SUB+= CDIO="" |
|
|
168 |
.else |
169 |
CONFIGURE_ARGS+=CONFIG_CDIO=n |
170 |
PLIST_SUB+= CDIO="@comment " |
171 |
.endif |
172 |
|
94 |
|
173 |
.if ${PORT_OPTIONS:MCUE} |
95 |
MUSEPACK_CONFIGURE_ON= CONFIG_MPC=y |
174 |
LIB_DEPENDS+= libcue.so:textproc/libcue |
96 |
MUSEPACK_LIB_DEPENDS= libmpcdec.so:audio/musepack |
175 |
CONFIGURE_ARGS+=CONFIG_CUE=y |
|
|
176 |
PLIST_SUB+= CUE="" |
177 |
.else |
178 |
CONFIGURE_ARGS+=CONFIG_CUE=n |
179 |
PLIST_SUB+= CUE="@comment " |
180 |
.endif |
181 |
|
97 |
|
182 |
.if ${PORT_OPTIONS:MDISCID} |
98 |
OPUS_CONFIGURE_ON= CONFIG_OPUS=y |
183 |
LIB_DEPENDS+= libdiscid.so:audio/libdiscid |
99 |
OPUS_LIB_DEPENDS= libopusfile.so:audio/opusfile |
184 |
CONFIGURE_ARGS+=CONFIG_DISCID=y |
|
|
185 |
.else |
186 |
CONFIGURE_ARGS+=CONFIG_DISCID=n |
187 |
.endif |
188 |
|
100 |
|
189 |
.if ${PORT_OPTIONS:MJACK} |
101 |
OSS_CONFIGURE_ON= CONFIG_OSS=y |
190 |
LIB_DEPENDS+= libjack.so:audio/jack |
|
|
191 |
CONFIGURE_ARGS+=CONFIG_JACK=y |
192 |
PLIST_SUB+= JACK="" |
193 |
.else |
194 |
CONFIGURE_ARGS+=CONFIG_JACK=n |
195 |
PLIST_SUB+= JACK="@comment " |
196 |
.endif |
197 |
|
102 |
|
198 |
.if ${PORT_OPTIONS:MSAMPLERATE} && ${PORT_OPTIONS:MJACK} |
103 |
PULSEAUDIO_CONFIGURE_ON= CONFIG_PULSE=y |
199 |
LIB_DEPENDS+= libsamplerate.so:audio/libsamplerate |
104 |
PULSEAUDIO_LIB_DEPENDS= libpulse.so:audio/pulseaudio |
200 |
CONFIGURE_ARGS+=CONFIG_SAMPLERATE=y |
|
|
201 |
.else |
202 |
CONFIGURE_ARGS+=CONFIG_SAMPLERATE=n |
203 |
.endif |
204 |
|
105 |
|
|
|
106 |
# Requires a port of RoarAudio |
107 |
#ROAR_CONFIGURE_ON= CONFIG_ROAR=y |
108 |
#ROAR_LIB_DEPENDS= ????:???? |
109 |
|
110 |
SAMPLERATE_IMPLIES= JACK |
111 |
SAMPLERATE_CONFIGURE_ON= CONFIG_SAMPLERATE=y |
112 |
SAMPLERATE_LIB_DEPENDS= libsamplerate.so:audio/libsamplerate |
113 |
|
114 |
SNDIO_CONFIGURE_ON= CONFIG_SNDIO=y |
115 |
SNDIO_LIB_DEPENDS= libsndio.so:audio/sndio |
116 |
|
117 |
TREMOR_IMPLIES= VORBIS |
118 |
TREMOR_CONFIGURE_ON= CONFIG_TREMOR=y |
119 |
TREMOR_LIB_DEPENDS= libvorbisidec.so:audio/libtremor |
120 |
|
121 |
VORBIS_CONFIGURE_ON= CONFIG_VORBIS=y |
122 |
VORBIS_LIB_DEPENDS= libvorbisfile.so:audio/libvorbis |
123 |
|
124 |
# VTX requires libayemu which isn't ported yet |
125 |
#VTX_CONFIGURE_ON= CONFIG_VTX=y |
126 |
#VTX_LIB_DEPENDS= libayemu.so:????? |
127 |
|
128 |
WAV_CONFIGURE_ON= CONFIG_WAV=y |
129 |
|
130 |
WAVPACK_CONFIGURE_ON= CONFIG_WAVPACK=y |
131 |
WAVPACK_LIB_DEPENDS= libwavpack.so:audio/wavpack |
132 |
|
133 |
# Doc/cmus.txt is used to generate the man pages. Fix paths to point |
134 |
# to the correct directories. |
205 |
post-patch: |
135 |
post-patch: |
206 |
@${REINPLACE_CMD} -e 's,doc/cmus/examples,examples/cmus,g' \ |
136 |
@${REINPLACE_CMD} \ |
|
|
137 |
-e 's,/usr/share/doc/cmus/examples,${EXAMPLESDIR},g' \ |
138 |
-e 's,/usr/share/cmus,${DATADIR},g' \ |
207 |
${WRKSRC}/Doc/cmus.txt |
139 |
${WRKSRC}/Doc/cmus.txt |
208 |
@${REINPLACE_CMD} -e 's,/usr,${PREFIX},g' ${WRKSRC}/Doc/cmus.txt |
|
|
209 |
|
140 |
|
210 |
post-install: |
141 |
post-install: |
211 |
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/cmus* |
142 |
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/cmus* |
212 |
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/cmus/[io]p/*.so |
143 |
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/cmus/[io]p/*.so |
|
|
144 |
# Install bash and zsh completion files |
145 |
${MKDIR} ${STAGEDIR}${PREFIX}/etc/bash_completion.d |
146 |
${INSTALL_DATA} ${WRKSRC}/contrib/cmus.bash-completion \ |
147 |
${STAGEDIR}${PREFIX}/etc/bash_completion.d/_cmus.bash |
148 |
${MKDIR} ${STAGEDIR}${PREFIX}/share/zsh/site-functions |
149 |
${INSTALL_DATA} ${WRKSRC}/contrib/_cmus \ |
150 |
${STAGEDIR}${PREFIX}/share/zsh/site-functions/_cmus |
213 |
|
151 |
|
214 |
.include <bsd.port.mk> |
152 |
.include <bsd.port.mk> |