2013-08-19 09:02:30 +02:00
|
|
|
# Template file for 'mpd'
|
|
|
|
pkgname=mpd
|
2014-02-07 03:53:08 +01:00
|
|
|
version=0.18.8
|
2013-11-09 09:28:41 +01:00
|
|
|
revision=1
|
2013-08-19 09:02:30 +02:00
|
|
|
build_style=gnu-configure
|
2013-10-30 07:46:09 +01:00
|
|
|
configure_args="
|
2013-11-09 09:28:41 +01:00
|
|
|
--enable-soundcloud --enable-pipe-output --disable-twolame-encoder
|
|
|
|
--disable-sidplay --with-systemdsystemunitdir=/usr/lib/systemd/system
|
2014-02-07 04:05:52 +01:00
|
|
|
--enable-bzip2 --enable-zzip LDFLAGS="
|
2013-08-19 09:02:30 +02:00
|
|
|
hostmakedepends="pkg-config"
|
2013-10-30 07:44:18 +01:00
|
|
|
makedepends="
|
|
|
|
ffmpeg-devel>=2.1 libmodplug-devel libmad-devel libcurl-devel faad2-devel
|
2013-11-09 09:28:41 +01:00
|
|
|
sqlite-devel libmms-devel avahi-glib-libs-devel libid3tag-devel
|
|
|
|
yajl-devel>=2.0.4 libogg-devel libflac-devel libsoup-devel bzip2-devel
|
2013-08-19 09:02:30 +02:00
|
|
|
libmikmod-devel libsndfile-devel alsa-lib-devel mpg123-devel libsamplerate-devel
|
2013-11-09 09:28:41 +01:00
|
|
|
libcdio-devel systemd-devel zziplib-devel libmpdclient-devel"
|
2014-01-01 16:10:11 +01:00
|
|
|
conf_files="/etc/mpd.conf"
|
|
|
|
system_accounts="mpd"
|
|
|
|
systemd_services="mpd.service on"
|
|
|
|
mpd_homedir="/var/lib/mpd"
|
|
|
|
make_dirs="/var/lib/mpd/playlists 0755 mpd mpd"
|
2013-08-19 09:02:30 +02:00
|
|
|
short_desc="Flexible, powerful, server-side application for playing music"
|
|
|
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
|
|
|
license="GPL-3"
|
|
|
|
homepage="http://www.musicpd.org/"
|
|
|
|
distfiles="http://www.musicpd.org/download/mpd/${version%.*}/mpd-${version}.tar.xz"
|
2014-02-07 03:53:08 +01:00
|
|
|
checksum=5366378e548fb77996cc33b0e15165ddd84f1e496bdd04616bd593aecdc26450
|
2013-10-30 07:46:09 +01:00
|
|
|
|
2013-08-19 09:02:30 +02:00
|
|
|
post_install() {
|
|
|
|
vinstall doc/mpdconf.example 644 etc mpd.conf
|
|
|
|
vinstall ${FILESDIR}/tmpfiles.d 644 usr/lib/tmpfiles.d mpd.conf
|
|
|
|
vmkdir usr/lib/systemd/user
|
|
|
|
ln -s ../system/mpd.service ${DESTDIR}/usr/lib/systemd/user/mpd.service
|
|
|
|
sed \
|
|
|
|
-e '/^#playlist_directory/c playlist_directory "/var/lib/mpd/playlists"' \
|
|
|
|
-e '/^#db_file/c db_file "/var/lib/mpd/mpd.db"' \
|
|
|
|
-e '/^#pid_file/c pid_file "/run/mpd/mpd.pid"' \
|
|
|
|
-e '/^#state_file/c state_file "/var/lib/mpd/mpdstate"' \
|
|
|
|
-e '/^#user/c user "mpd"' \
|
|
|
|
-i ${DESTDIR}/etc/mpd.conf
|
|
|
|
}
|
|
|
|
|
2013-11-09 09:28:41 +01:00
|
|
|
# Package build options
|
|
|
|
build_options="jack lame mpcdec pulseaudio wavpack"
|
|
|
|
desc_option_jack="Enable support for the JACK sound server"
|
|
|
|
desc_option_lame="Enable support for the LAME encoder"
|
|
|
|
desc_option_mpcdec="Enable support for the Musepack decoder"
|
|
|
|
desc_option_pulseaudio="Enable support for the PulseAudio sound server"
|
|
|
|
desc_option_wavpack="Enable support for the Wavpack decoder"
|
|
|
|
|
|
|
|
build_options_default="pulseaudio"
|
|
|
|
|
|
|
|
if [ "$build_option_jack" ]; then
|
|
|
|
configure_args+=" --enable-jack"
|
|
|
|
makedepends+=" jack-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --disable-jack"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$build_option_lame" ]; then
|
|
|
|
configure_args+=" --enable-lame-encoder"
|
|
|
|
makedepends+=" lame-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --disable-lame-encoder"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$build_option_mpcdec" ]; then
|
|
|
|
configure_args+=" --enable-mpc"
|
|
|
|
makedepends+=" libmpcdec-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --disable-mpc"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$build_option_pulseaudio" ]; then
|
|
|
|
configure_args+=" --enable-pulse"
|
|
|
|
makedepends+=" pulseaudio-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --disable-pulse"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$build_option_wavpack" ]; then
|
|
|
|
configure_args+=" --enable-wavpack"
|
|
|
|
makedepends+=" wavpack-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --disable-wavpack"
|
|
|
|
fi
|