summary refs log tree commit diff
path: root/pkgs/applications/audio
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/applications/audio')
-rw-r--r--pkgs/applications/audio/bs1770gain/default.nix4
-rw-r--r--pkgs/applications/audio/clementine/default.nix5
-rw-r--r--pkgs/applications/audio/pulseaudio-modules-bt/default.nix37
-rw-r--r--pkgs/applications/audio/pulseaudio-modules-bt/fix-install-path.patch11
-rw-r--r--pkgs/applications/audio/sonic-pi/default.nix10
5 files changed, 48 insertions, 19 deletions
diff --git a/pkgs/applications/audio/bs1770gain/default.nix b/pkgs/applications/audio/bs1770gain/default.nix
index 2401a6101566..edf7a313ff5f 100644
--- a/pkgs/applications/audio/bs1770gain/default.nix
+++ b/pkgs/applications/audio/bs1770gain/default.nix
@@ -2,11 +2,11 @@
 
 stdenv.mkDerivation rec {
   name = "bs1770gain-${version}";
-  version = "0.4.12";
+  version = "0.5.0";
 
   src = fetchurl {
     url = "mirror://sourceforge/bs1770gain/${name}.tar.gz";
-    sha256 = "0n9skdap1vnl6w52fx0gsrjlk7w3xgdwi62ycyf96h29rx059z6a";
+    sha256 = "0vd7320k7s2zcn2vganclxbr1vav18ghld27rcwskvcc3dm8prii";
   };
 
   buildInputs = [ ffmpeg sox ];
diff --git a/pkgs/applications/audio/clementine/default.nix b/pkgs/applications/audio/clementine/default.nix
index 611828753e46..a28125d24d4f 100644
--- a/pkgs/applications/audio/clementine/default.nix
+++ b/pkgs/applications/audio/clementine/default.nix
@@ -69,7 +69,8 @@ let
     name = "clementine-free-${version}";
     inherit src patches nativeBuildInputs postPatch;
 
-    buildInputs = buildInputs ++ [ makeWrapper ];
+    # gst_plugins needed for setup-hooks
+    buildInputs = buildInputs ++ [ makeWrapper gst_plugins ];
 
     cmakeFlags = [ "-DUSE_SYSTEM_PROJECTM=ON" ];
 
@@ -101,7 +102,7 @@ let
       ./clementine-spotify-blob.patch
     ];
 
-    buildInputs = buildInputs ++ [ libspotify makeWrapper gst_plugins ];
+    buildInputs = buildInputs ++ [ libspotify makeWrapper ];
     # Only build and install the Spotify blob
     preBuild = ''
       cd ext/clementine-spotifyblob
diff --git a/pkgs/applications/audio/pulseaudio-modules-bt/default.nix b/pkgs/applications/audio/pulseaudio-modules-bt/default.nix
index e3d07fcc2457..b377db65c0c9 100644
--- a/pkgs/applications/audio/pulseaudio-modules-bt/default.nix
+++ b/pkgs/applications/audio/pulseaudio-modules-bt/default.nix
@@ -1,14 +1,16 @@
 { stdenv
 , runCommand
 , fetchFromGitHub
-, libpulseaudio
 , pulseaudio
 , pkgconfig
+, ffmpeg_4
+, patchelf
 , libtool
 , cmake
 , bluez
 , dbus
 , sbc
+, lib
 }:
 
 let
@@ -20,37 +22,52 @@ let
 
 in stdenv.mkDerivation rec {
   name = "pulseaudio-modules-bt-${version}";
-  version = "unstable-2018-09-11";
+  version = "unstable-2018-10-16";
 
   src = fetchFromGitHub {
     owner = "EHfive";
     repo = "pulseaudio-modules-bt";
-    rev = "9c6ad75382f3855916ad2feaa6b40e37356d80cc";
-    sha256 = "1iz4m3y6arsvwcyvqc429w252dl3apnhvl1zhyvfxlbg00d2ii0h";
+    rev = "552c2b48c0cc7dd44d0746b261f7c7d5559e8e30";
+    sha256 = "052jb1hjx1in7bafx4zpn78s7r6f2y7djriwi36dzqy9wmalmyjy";
     fetchSubmodules = true;
   };
 
+  patches = [
+    ./fix-install-path.patch
+  ];
+
   nativeBuildInputs = [
     pkgconfig
+    patchelf
     cmake
   ];
 
   buildInputs = [
-    libpulseaudio
     pulseaudio
+    ffmpeg_4
     libtool
     bluez
     dbus
     sbc
   ];
 
-  NIX_CFLAGS_COMPILE = [
-    "-L${pulseaudio}/lib/pulseaudio"
-  ];
-
-  prePatch = ''
+  postPatch = ''
+    # Upstream bundles pulseaudio as a submodule
     rm -r pa
     ln -s ${pulseSources} pa
+
+    # 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}
+  '';
+
+  postFixup = ''
+    for so in $out/lib/pulse-${pulseaudio.version}/modules/*.so; do
+      orig_rpath=$(patchelf --print-rpath "$so")
+      patchelf \
+        --set-rpath "${lib.getLib ffmpeg_4}/lib:$out/lib/pulse-${pulseaudio.version}/modules:$orig_rpath" \
+        "$so"
+    done
   '';
 
   meta = with stdenv.lib; {
diff --git a/pkgs/applications/audio/pulseaudio-modules-bt/fix-install-path.patch b/pkgs/applications/audio/pulseaudio-modules-bt/fix-install-path.patch
new file mode 100644
index 000000000000..2b4ff86ab71b
--- /dev/null
+++ b/pkgs/applications/audio/pulseaudio-modules-bt/fix-install-path.patch
@@ -0,0 +1,11 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0f5baa0..1f35cce 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -122,5 +121,4 @@ INSTALL(TARGETS
+         module-bluez5-device
+         module-bluetooth-discover
+         module-bluetooth-policy
+-        LIBRARY DESTINATION ${PulseAudio_modlibexecdir})
+-
++        LIBRARY DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/pulse-${PulseAudio_VERSION}/modules/)
diff --git a/pkgs/applications/audio/sonic-pi/default.nix b/pkgs/applications/audio/sonic-pi/default.nix
index d1c48ce44ed8..ee72b6cdb1a4 100644
--- a/pkgs/applications/audio/sonic-pi/default.nix
+++ b/pkgs/applications/audio/sonic-pi/default.nix
@@ -20,14 +20,14 @@ let
   };
 
 in stdenv.mkDerivation rec {
-  version = "3.0.1";
+  version = "3.1.0";
   name = "sonic-pi-${version}";
 
   src = fetchFromGitHub {
     owner = "samaaron";
     repo = "sonic-pi";
     rev = "v${version}";
-    sha256 = "1l1892hijp1dj2h799sfjr699q6xp660n0siibab5kv238521a81";
+    sha256 = "0gi4a73szaa8iz5q1gxgpsnyvhhghcfqm6bfwwxbix4m5csbfgh9";
   };
 
   buildInputs = [
@@ -58,21 +58,21 @@ in stdenv.mkDerivation rec {
     export SONIC_PI_HOME=$TMPDIR
     export AUBIO_LIB=${aubio}/lib/libaubio.so
 
-    pushd app/server/bin
+    pushd app/server/ruby/bin
       ./compile-extensions.rb
       ./i18n-tool.rb -t
     popd
 
     pushd app/gui/qt
       cp -f ruby_help.tmpl ruby_help.h
-      ../../server/bin/qt-doc.rb -o ruby_help.h
+      ../../server/ruby/bin/qt-doc.rb -o ruby_help.h
 
       substituteInPlace SonicPi.pro \
         --replace "LIBS += -lrt -lqt5scintilla2" \
                   "LIBS += -lrt -lqscintilla2 -lqwt"
 
       lrelease SonicPi.pro
-      qmake SonicPi.pro 
+      qmake SonicPi.pro
 
       make
     popd