1 # Copyright 1999-2016 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
5 # Add --enable-spotify when it works
9 inherit autotools eutils user
11 DESCRIPTION="A DAAP (iTunes) media server"
12 HOMEPAGE="https://github.com/ejurgensen/forked-daapd"
13 SRC_URI="https://github.com/ejurgensen/forked-daapd/archive/${PV}.tar.gz -> ${P}.tar.gz"
17 IUSE="alsa flac itunes lastfm mpd musepack"
19 # Note: mpd support appears to be standalone, e.g. --enable-mpd doesn't
20 # result in additional linkage.
28 dev-libs/mxml[threads]
32 alsa? ( media-libs/alsa-lib )
33 flac? ( media-libs/flac )
34 itunes? ( app-pda/libplist )
35 lastfm? ( net-misc/curl )
36 musepack? ( media-libs/taglib )
50 # https://github.com/ejurgensen/forked-daapd/pull/185
51 #epatch "${FILESDIR}/antlr-3.5.patch"
57 ac_cv_prog_ANTLR=antlr3.5 \
61 $(use_enable musepack) \
62 $(use_enable itunes) \
63 $(use_enable lastfm) \
68 emake DESTDIR="${D}" install
70 newinitd "${FILESDIR}/daapd.initd" daapd
71 newconfd "${FILESDIR}/daapd.confd" daapd
73 # dodir by itself fails in the likely case of /srv/music having a
74 # volume mounted already.
75 test -d /srv/music || dodir /srv/music
77 fowners -R daapd:daapd /var/lib/cache/forked-daapd