1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 inherit autotools multilib-minimal systemd
7 DESCRIPTION="Bluetooth Audio ALSA Backend"
8 HOMEPAGE="https://github.com/Arkq/bluez-alsa"
10 if [[ ${PV} == "9999" ]] ; then
12 EGIT_REPO_URI="https://github.com/Arkq/${PN}"
14 SRC_URI="https://github.com/Arkq/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
15 KEYWORDS="~amd64 ~x86"
20 IUSE="aac debug hcitop ldac ofono static-libs test"
21 RESTRICT="!test? ( test )"
23 RDEPEND=">=dev-libs/glib-2.26[dbus,${MULTILIB_USEDEP}]
24 >=media-libs/alsa-lib-1.1.2[${MULTILIB_USEDEP}]
25 >=media-libs/sbc-1.2[${MULTILIB_USEDEP}]
26 >=net-wireless/bluez-5.0[${MULTILIB_USEDEP}]
27 sys-apps/dbus[${MULTILIB_USEDEP}]
29 aac? ( >=media-libs/fdk-aac-0.1.1:=[${MULTILIB_USEDEP}] )
34 ldac? ( >=media-libs/libldac-2.0.0 )"
36 BDEPEND="virtual/pkgconfig"
43 multilib_src_configure() {
49 $(use_enable static-libs static)
51 $(multilib_native_use_enable hcitop)
52 $(multilib_native_use_enable ldac)
54 ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
57 multilib_src_install_all() {
59 find "${ED}" -name "*.la" -delete || die
61 newinitd "${FILESDIR}"/bluealsa-init.d bluealsa
62 newconfd "${FILESDIR}"/bluealsa-conf.d-2 bluealsa
63 systemd_dounit "${FILESDIR}"/bluealsa.service
67 elog "Users can use this service when they are members of the \"audio\" group."