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.xz -> ${P}.tar.xz"
14 SRC_URI="https://github.com/ejurgensen/forked-daapd/releases/download/${PV}/${P}.tar.xz"
18 IUSE="alsa flac itunes lastfm mpd musepack"
20 # Note: mpd support appears to be standalone, e.g. --enable-mpd doesn't
21 # result in additional linkage.
29 dev-libs/mxml[threads]
34 alsa? ( media-libs/alsa-lib )
35 flac? ( media-libs/flac )
36 itunes? ( app-pda/libplist )
37 lastfm? ( net-misc/curl )
38 musepack? ( media-libs/taglib )
52 # https://github.com/ejurgensen/forked-daapd/pull/185
53 #epatch "${FILESDIR}/antlr-3.5.patch"
59 ac_cv_prog_ANTLR=antlr3.5 \
63 $(use_enable musepack) \
64 $(use_enable itunes) \
65 $(use_enable lastfm) \
70 emake DESTDIR="${D}" install
72 newinitd "${FILESDIR}/daapd.initd" daapd
73 newconfd "${FILESDIR}/daapd.confd" daapd
75 # dodir by itself fails in the likely case of /srv/music having a
76 # volume mounted already.
77 test -d /srv/music || dodir /srv/music
79 fowners -R daapd:daapd /var/lib/cache/forked-daapd