From 7b0c099438e99a8c86175487dbf78d9edc4c67a7 Mon Sep 17 00:00:00 2001 From: adisbladis Date: Sat, 6 Jun 2020 22:46:39 +0200 Subject: [PATCH] pulseaudio-modules-bt: 1.3 -> 1.4 --- .../audio/pulseaudio-modules-bt/default.nix | 9 ++++++--- .../pulseaudio-modules-bt/fix-aac-defaults.patch | 15 --------------- 2 files changed, 6 insertions(+), 18 deletions(-) delete mode 100644 pkgs/applications/audio/pulseaudio-modules-bt/fix-aac-defaults.patch diff --git a/pkgs/applications/audio/pulseaudio-modules-bt/default.nix b/pkgs/applications/audio/pulseaudio-modules-bt/default.nix index 2511cf0f20a5..49cc83189359 100644 --- a/pkgs/applications/audio/pulseaudio-modules-bt/default.nix +++ b/pkgs/applications/audio/pulseaudio-modules-bt/default.nix @@ -24,18 +24,17 @@ let in stdenv.mkDerivation rec { pname = "pulseaudio-modules-bt"; - version = "1.3"; + version = "1.4"; src = fetchFromGitHub { owner = "EHfive"; repo = "pulseaudio-modules-bt"; rev = "v${version}"; - sha256 = "00xmidcw4fvpbmg0nsm2gk5zw26fpyjbc0pjk6mzr570zbnyqqbn"; + sha256 = "0bzg6x405j39axnkvc6n6vkl1hv1frk94y1i9sl170081bk23asd"; }; patches = [ ./fix-install-path.patch - ./fix-aac-defaults.patch ]; nativeBuildInputs = [ @@ -63,6 +62,10 @@ in stdenv.mkDerivation rec { # Pulseaudio version is detected with a -rebootstrapped suffix which build system assumptions substituteInPlace config.h.in --replace PulseAudio_VERSION ${pulseaudio.version} substituteInPlace CMakeLists.txt --replace '${"\${PulseAudio_VERSION}"}' ${pulseaudio.version} + + # Fraunhofer recommends to enable afterburner but upstream has it set to false by default + substituteInPlace src/modules/bluetooth/a2dp/a2dp_aac.c \ + --replace "info->aac_afterburner = false;" "info->aac_afterburner = true;" ''; postFixup = '' diff --git a/pkgs/applications/audio/pulseaudio-modules-bt/fix-aac-defaults.patch b/pkgs/applications/audio/pulseaudio-modules-bt/fix-aac-defaults.patch deleted file mode 100644 index c94c5dd61f26..000000000000 --- a/pkgs/applications/audio/pulseaudio-modules-bt/fix-aac-defaults.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff --git a/src/modules/bluetooth/a2dp/a2dp_aac.c b/src/modules/bluetooth/a2dp/a2dp_aac.c -index 394a7a0..cf5abaf 100644 ---- a/src/modules/bluetooth/a2dp/a2dp_aac.c -+++ b/src/modules/bluetooth/a2dp/a2dp_aac.c -@@ -90,8 +90,8 @@ pa_aac_encoder_init(pa_a2dp_source_read_cb_t read_cb, pa_a2dp_source_read_buf_fr - info->read_pcm = read_cb; - info->read_buf_free = free_cb; - info->aacenc_handle_opened = false; -- info->aac_enc_bitrate_mode = 5; -- info->aac_afterburner = false; -+ info->aac_enc_bitrate_mode = 0; -+ info->aac_afterburner = true; - info->force_pa_fmt = PA_SAMPLE_INVALID; - return true; - }