From b50033ecb5e30204457b16c251c7b7cf798f0673 Mon Sep 17 00:00:00 2001 From: Pablo Cholaky Date: Mon, 23 Mar 2020 01:17:28 -0400 Subject: [PATCH] media-sound/pulseaudio-modules-bt: add USE flags Closes: https://bugs.gentoo.org/713878 Signed-off-by: Pablo Cholaky Signed-off-by: Jason A. Donenfeld --- .../pulseaudio-modules-bt/metadata.xml | 29 +++++++++++++++---- ...ld => pulseaudio-modules-bt-1.3-r1.ebuild} | 22 ++++++++++---- .../pulseaudio-modules-bt-9999.ebuild | 22 ++++++++++---- 3 files changed, 57 insertions(+), 16 deletions(-) rename media-sound/pulseaudio-modules-bt/{pulseaudio-modules-bt-1.3.ebuild => pulseaudio-modules-bt-1.3-r1.ebuild} (76%) diff --git a/media-sound/pulseaudio-modules-bt/metadata.xml b/media-sound/pulseaudio-modules-bt/metadata.xml index c6a40a7b9cb4..ecdf5fddd6d7 100644 --- a/media-sound/pulseaudio-modules-bt/metadata.xml +++ b/media-sound/pulseaudio-modules-bt/metadata.xml @@ -1,10 +1,27 @@ - - zx2c4@gentoo.org - - - pacho@gentoo.org - + + zx2c4@gentoo.org + + + pacho@gentoo.org + + + + AAC encoding support using media-libs/fdk-aac + + + APTX, APTX-HD encoding support + + + LDAC encoding support, using media-libs/libldac + + + Build with native HSP (Headset Profile) headset for bluez 5 + + + Build with oFono HFP (Hands Free Profile) headset for bluez 5, requires net-misc/ofono. + + diff --git a/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-1.3.ebuild b/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-1.3-r1.ebuild similarity index 76% rename from media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-1.3.ebuild rename to media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-1.3-r1.ebuild index 72132d0bcd33..22faf22ec86d 100644 --- a/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-1.3.ebuild +++ b/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-1.3-r1.ebuild @@ -16,16 +16,16 @@ SRC_URI=" LICENSE="GPL-3" SLOT="0" KEYWORDS="~amd64" -IUSE="" +IUSE="fdk +ffmpeg +ldac +native-headset ofono-headset" DEPEND=" - media-libs/fdk-aac:0= - virtual/ffmpeg + fdk? ( media-libs/fdk-aac:0= ) + ffmpeg? ( virtual/ffmpeg ) media-libs/sbc - media-libs/libldac + ldac? ( media-libs/libldac ) >=net-wireless/bluez-5 >=sys-apps/dbus-1.0.0 - >=net-misc/ofono-1.13 + ofono-headset? ( >=net-misc/ofono-1.13 ) >=media-sound/pulseaudio-${PULSE_VER}[-bluetooth] " # Ordinarily media-libs/libldac should be in DEPEND too, but for now upstream repo is using a ldac submodule instead. @@ -53,6 +53,18 @@ load-module module-bluetooth-discover .endif " +src_configure() { + local mycmakeargs=( + -DCODEC_AAC_FDK=$(usex fdk "ON" "OFF") + -DCODEC_APTX_FF=$(usex ffmpeg "ON" "OFF") + -DCODEC_APTX_HD_FF=$(usex ffmpeg "ON" "OFF") + -DCODEC_LDAC=$(usex ldac "ON" "OFF") + -DNATIVE_HEADSET=$(usex native-headset "ON" "OFF") + -DOFONO_HEADSET=$(usex ofono-headset "ON" "OFF") + ) + cmake-utils_src_configure +} + src_prepare() { cmake-utils_src_prepare diff --git a/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-9999.ebuild b/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-9999.ebuild index 4dbb99143961..8b8e74ca04f7 100644 --- a/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-9999.ebuild +++ b/media-sound/pulseaudio-modules-bt/pulseaudio-modules-bt-9999.ebuild @@ -17,16 +17,16 @@ EGIT_OVERRIDE_COMMIT_PULSEAUDIO_PULSEAUDIO="v13.0" LICENSE="GPL-3" SLOT="0" KEYWORDS="" -IUSE="" +IUSE="fdk +ffmpeg +ldac +native-headset ofono-headset" DEPEND=" - media-libs/fdk-aac:0= - virtual/ffmpeg + fdk? ( media-libs/fdk-aac:0= ) + ffmpeg? ( virtual/ffmpeg ) media-libs/sbc - media-libs/libldac + ldac? ( media-libs/libldac ) >=net-wireless/bluez-5 >=sys-apps/dbus-1.0.0 - >=net-misc/ofono-1.13 + ofono-headset? ( >=net-misc/ofono-1.13 ) >=media-sound/pulseaudio-13[-bluetooth] " # Ordinarily media-libs/libldac should be in DEPEND too, but for now upstream repo is using a ldac submodule instead. @@ -55,6 +55,18 @@ load-module module-bluetooth-discover .endif " +src_configure() { + local mycmakeargs=( + -DCODEC_AAC_FDK=$(usex fdk "ON" "OFF") + -DCODEC_APTX_FF=$(usex ffmpeg "ON" "OFF") + -DCODEC_APTX_HD_FF=$(usex ffmpeg "ON" "OFF") + -DCODEC_LDAC=$(usex ldac "ON" "OFF") + -DNATIVE_HEADSET=$(usex native-headset "ON" "OFF") + -DOFONO_HEADSET=$(usex ofono-headset "ON" "OFF") + ) + cmake-utils_src_configure +} + src_install() { cmake-utils_src_install readme.gentoo_create_doc -- 2.26.2