cmake: bump version to 3.6.3
[buildroot-gz.git] / package / mpd / mpd.mk
blob0bf8ece08b72fa00a7e6c32a8fdefed27151f2b9
1 ################################################################################
3 # mpd
5 ################################################################################
7 MPD_VERSION_MAJOR = 0.19
8 MPD_VERSION = $(MPD_VERSION_MAJOR).19
9 MPD_SOURCE = mpd-$(MPD_VERSION).tar.xz
10 MPD_SITE = http://www.musicpd.org/download/mpd/$(MPD_VERSION_MAJOR)
11 MPD_DEPENDENCIES = host-pkgconf boost libglib2
12 MPD_LICENSE = GPLv2+
13 MPD_LICENSE_FILES = COPYING
14 MPD_AUTORECONF = YES
16 # Some options need an explicit --disable or --enable
18 # Zeroconf support depends on libdns_sd from avahi.
19 ifeq ($(BR2_PACKAGE_MPD_AVAHI_SUPPORT),y)
20 MPD_DEPENDENCIES += avahi
21 MPD_CONF_OPTS += --with-zeroconf=avahi
22 else
23 MPD_CONF_OPTS += --with-zeroconf=no
24 endif
26 # MPD prefers libicu for utf8 collation instead of libglib2.
27 ifeq ($(BR2_PACKAGE_ICU),y)
28 MPD_DEPENDENCIES += icu
29 MPD_CONF_OPTS += --enable-icu
30 else
31 MPD_CONF_OPTS += --disable-icu
32 endif
34 ifeq ($(BR2_PACKAGE_MPD_ALSA),y)
35 MPD_DEPENDENCIES += alsa-lib
36 MPD_CONF_OPTS += --enable-alsa
37 else
38 MPD_CONF_OPTS += --disable-alsa
39 endif
41 ifeq ($(BR2_PACKAGE_MPD_AO),y)
42 MPD_DEPENDENCIES += libao
43 MPD_CONF_OPTS += --enable-ao
44 else
45 MPD_CONF_OPTS += --disable-ao
46 endif
48 ifeq ($(BR2_PACKAGE_MPD_AUDIOFILE),y)
49 MPD_DEPENDENCIES += audiofile
50 MPD_CONF_OPTS += --enable-audiofile
51 else
52 MPD_CONF_OPTS += --disable-audiofile
53 endif
55 ifeq ($(BR2_PACKAGE_MPD_BZIP2),y)
56 MPD_DEPENDENCIES += bzip2
57 MPD_CONF_OPTS += --enable-bzip2
58 else
59 MPD_CONF_OPTS += --disable-bzip2
60 endif
62 ifeq ($(BR2_PACKAGE_MPD_CURL),y)
63 MPD_DEPENDENCIES += libcurl
64 MPD_CONF_OPTS += --enable-curl
65 else
66 MPD_CONF_OPTS += --disable-curl
67 endif
69 ifeq ($(BR2_PACKAGE_MPD_DSD),y)
70 MPD_CONF_OPTS += --enable-dsd
71 else
72 MPD_CONF_OPTS += --disable-dsd
73 endif
75 ifeq ($(BR2_PACKAGE_MPD_FAAD2),y)
76 MPD_DEPENDENCIES += faad2
77 MPD_CONF_OPTS += --enable-aac
78 else
79 MPD_CONF_OPTS += --disable-aac
80 endif
82 ifeq ($(BR2_PACKAGE_MPD_FFMPEG),y)
83 MPD_DEPENDENCIES += ffmpeg
84 MPD_CONF_OPTS += --enable-ffmpeg
85 else
86 MPD_CONF_OPTS += --disable-ffmpeg
87 endif
89 ifeq ($(BR2_PACKAGE_MPD_FLAC),y)
90 MPD_DEPENDENCIES += flac
91 MPD_CONF_OPTS += --enable-flac
92 else
93 MPD_CONF_OPTS += --disable-flac
94 endif
96 ifeq ($(BR2_PACKAGE_MPD_HTTPD_OUTPUT),y)
97 MPD_CONF_OPTS += --enable-httpd-output
98 else
99 MPD_CONF_OPTS += --disable-httpd-output
100 endif
102 ifeq ($(BR2_PACKAGE_MPD_JACK2),y)
103 MPD_DEPENDENCIES += jack2
104 MPD_CONF_OPTS += --enable-jack
105 else
106 MPD_CONF_OPTS += --disable-jack
107 endif
109 ifeq ($(BR2_PACKAGE_MPD_LAME),y)
110 MPD_DEPENDENCIES += lame
111 MPD_CONF_OPTS += --enable-lame-encoder
112 else
113 MPD_CONF_OPTS += --disable-lame-encoder
114 endif
116 ifeq ($(BR2_PACKAGE_MPD_LIBNFS),y)
117 MPD_DEPENDENCIES += libnfs
118 MPD_CONF_OPTS += --enable-nfs
119 else
120 MPD_CONF_OPTS += --disable-nfs
121 endif
123 ifeq ($(BR2_PACKAGE_MPD_LIBSMBCLIENT),y)
124 MPD_DEPENDENCIES += samba4
125 MPD_CONF_OPTS += --enable-smbclient
126 else
127 MPD_CONF_OPTS += --disable-smbclient
128 endif
130 ifeq ($(BR2_PACKAGE_MPD_LIBSAMPLERATE),y)
131 MPD_DEPENDENCIES += libsamplerate
132 MPD_CONF_OPTS += --enable-lsr
133 else
134 MPD_CONF_OPTS += --disable-lsr
135 endif
137 ifeq ($(BR2_PACKAGE_MPD_LIBSNDFILE),y)
138 MPD_DEPENDENCIES += libsndfile
139 MPD_CONF_OPTS += --enable-sndfile
140 else
141 MPD_CONF_OPTS += --disable-sndfile
142 endif
144 ifeq ($(BR2_PACKAGE_MPD_LIBSOXR),y)
145 MPD_DEPENDENCIES += libsoxr
146 MPD_CONF_OPTS += --enable-soxr
147 else
148 MPD_CONF_OPTS += --disable-soxr
149 endif
151 ifeq ($(BR2_PACKAGE_MPD_MAD),y)
152 MPD_DEPENDENCIES += libid3tag libmad
153 MPD_CONF_OPTS += --enable-mad
154 else
155 MPD_CONF_OPTS += --disable-mad
156 endif
158 ifeq ($(BR2_PACKAGE_MPD_MPG123),y)
159 MPD_DEPENDENCIES += libid3tag mpg123
160 MPD_CONF_OPTS += --enable-mpg123
161 else
162 MPD_CONF_OPTS += --disable-mpg123
163 endif
165 ifeq ($(BR2_PACKAGE_MPD_MUSEPACK),y)
166 MPD_DEPENDENCIES += musepack
167 MPD_CONF_OPTS += --enable-mpc
168 else
169 MPD_CONF_OPTS += --disable-mpc
170 endif
172 ifeq ($(BR2_PACKAGE_MPD_NEIGHBOR_DISCOVERY_SUPPORT),y)
173 MPD_CONF_OPTS += --enable-neighbor-plugins
174 else
175 MPD_CONF_OPTS += --disable-neighbor-plugins
176 endif
178 ifeq ($(BR2_PACKAGE_MPD_OPUS),y)
179 MPD_DEPENDENCIES += opus libogg
180 MPD_CONF_OPTS += --enable-opus
181 else
182 MPD_CONF_OPTS += --disable-opus
183 endif
185 ifeq ($(BR2_PACKAGE_MPD_OSS),y)
186 MPD_CONF_OPTS += --enable-oss
187 else
188 MPD_CONF_OPTS += --disable-oss
189 endif
191 ifeq ($(BR2_PACKAGE_MPD_PULSEAUDIO),y)
192 MPD_DEPENDENCIES += pulseaudio
193 MPD_CONF_OPTS += --enable-pulse
194 else
195 MPD_CONF_OPTS += --disable-pulse
196 endif
198 ifeq ($(BR2_PACKAGE_MPD_SHOUTCAST),y)
199 MPD_DEPENDENCIES += libshout
200 MPD_CONF_OPTS += --enable-shout
201 else
202 MPD_CONF_OPTS += --disable-shout
203 endif
205 ifeq ($(BR2_PACKAGE_MPD_SOUNDCLOUD),y)
206 MPD_DEPENDENCIES += yajl
207 MPD_CONF_OPTS += --enable-soundcloud
208 else
209 MPD_CONF_OPTS += --disable-soundcloud
210 endif
212 ifeq ($(BR2_PACKAGE_MPD_SQLITE),y)
213 MPD_DEPENDENCIES += sqlite
214 MPD_CONF_OPTS += --enable-sqlite
215 else
216 MPD_CONF_OPTS += --disable-sqlite
217 endif
219 ifneq ($(BR2_PACKAGE_MPD_TCP),y)
220 MPD_CONF_OPTS += --disable-tcp
221 endif
223 ifeq ($(BR2_PACKAGE_MPD_TREMOR),y)
224 MPD_DEPENDENCIES += tremor
225 MPD_CONF_OPTS += --with-tremor
226 endif
228 ifeq ($(BR2_PACKAGE_MPD_TWOLAME),y)
229 MPD_DEPENDENCIES += twolame
230 MPD_CONF_OPTS += --enable-twolame-encoder
231 else
232 MPD_CONF_OPTS += --disable-twolame-encoder
233 endif
235 ifeq ($(BR2_PACKAGE_MPD_UPNP),y)
236 MPD_DEPENDENCIES += expat libupnp
237 MPD_CONF_OPTS += --enable-upnp
238 else
239 MPD_CONF_OPTS += --disable-upnp
240 endif
242 ifeq ($(BR2_PACKAGE_MPD_VORBIS),y)
243 MPD_DEPENDENCIES += libvorbis
244 MPD_CONF_OPTS += --enable-vorbis --enable-vorbis-encoder
245 else
246 MPD_CONF_OPTS += --disable-vorbis --disable-vorbis-encoder
247 endif
249 ifeq ($(BR2_PACKAGE_MPD_WAVPACK),y)
250 MPD_DEPENDENCIES += wavpack
251 MPD_CONF_OPTS += --enable-wavpack
252 else
253 MPD_CONF_OPTS += --disable-wavpack
254 endif
256 define MPD_INSTALL_EXTRA_FILES
257 $(INSTALL) -m 0644 -D package/mpd/mpd.conf $(TARGET_DIR)/etc/mpd.conf
258 endef
260 MPD_POST_INSTALL_TARGET_HOOKS += MPD_INSTALL_EXTRA_FILES
262 define MPD_INSTALL_INIT_SYSV
263 $(INSTALL) -m 0755 -D package/mpd/S95mpd \
264 $(TARGET_DIR)/etc/init.d/S95mpd
265 endef
267 $(eval $(autotools-package))