about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/audio
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/audio')
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/libbass/default.nix66
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/libbs2b/default.nix23
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/libgme/default.nix31
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/libinstpatch/default.nix29
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/libmysofa/default.nix26
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/libsmf/default.nix21
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/lilv/default.nix25
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/lilv/lilv-pkgconfig.patch6
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/lv2/default.nix24
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/lvtk/default.nix34
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/mbelib/default.nix29
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/ntk/default.nix26
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/qm-dsp/default.nix53
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/raul/default.nix27
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/rtaudio/default.nix65
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix71
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/sratom/default.nix22
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/suil/default.nix36
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/vamp-plugin-sdk/default.nix29
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/zita-alsa-pcmi/default.nix64
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/zita-convolver/default.nix36
-rw-r--r--nixpkgs/pkgs/development/libraries/audio/zita-resampler/default.nix33
22 files changed, 776 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/audio/libbass/default.nix b/nixpkgs/pkgs/development/libraries/audio/libbass/default.nix
new file mode 100644
index 000000000000..ab97090e8899
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/libbass/default.nix
@@ -0,0 +1,66 @@
+{ lib, stdenv, unzip, fetchurl }:
+
+# Upstream changes files in-place, to update:
+# 1. Check latest version at http://www.un4seen.com/
+# 2. Update `version`s and `sha256` sums.
+# See also http://www.un4seen.com/forum/?topic=18614.0
+
+let
+  allBass = {
+    bass = {
+      h = "bass.h";
+      version = "2.4.15";
+      so = {
+        i686_linux = "libbass.so";
+        x86_64-linux = "x64/libbass.so";
+      };
+      urlpath = "bass24-linux.zip";
+      sha256 = "1lmysxfhy727zskavml3ibg5w876ir88923bm17c21s59w5lh7l8";
+    };
+
+    bass_fx = {
+      h = "C/bass_fx.h";
+      version = "2.4.12.1";
+      so = {
+        i686_linux = "libbass_fx.so";
+        x86_64-linux = "x64/libbass_fx.so";
+      };
+      urlpath = "z/0/bass_fx24-linux.zip";
+      sha256 = "1q0g74z7iyhxqps5b3gnnbic8v2jji1r0mkvais57lsx8y21sbin";
+    };
+  };
+
+  dropBass = name: bass: stdenv.mkDerivation {
+    pname = "lib${name}";
+    inherit (bass) version;
+
+    src = fetchurl {
+      url = "https://www.un4seen.com/files/${bass.urlpath}";
+      inherit (bass) sha256;
+    };
+    unpackCmd = ''
+      mkdir out
+      ${unzip}/bin/unzip $curSrc -d out
+    '';
+
+    lpropagatedBuildInputs = [ unzip ];
+    dontBuild = true;
+    installPhase =
+      let so =
+            if bass.so ? ${stdenv.hostPlatform.system} then bass.so.${stdenv.hostPlatform.system}
+            else throw "${name} not packaged for ${stdenv.hostPlatform.system} (yet).";
+      in ''
+        mkdir -p $out/{lib,include}
+        install -m644 -t $out/lib/ ${so}
+        install -m644 -t $out/include/ ${bass.h}
+      '';
+
+    meta = with lib; {
+      description = "Shareware audio library";
+      homepage = "https://www.un4seen.com/";
+      license = licenses.unfreeRedistributable;
+      platforms = builtins.attrNames bass.so;
+    };
+  };
+
+in lib.mapAttrs dropBass allBass
diff --git a/nixpkgs/pkgs/development/libraries/audio/libbs2b/default.nix b/nixpkgs/pkgs/development/libraries/audio/libbs2b/default.nix
new file mode 100644
index 000000000000..11135b14fd48
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/libbs2b/default.nix
@@ -0,0 +1,23 @@
+{ lib, stdenv, fetchurl, pkg-config, libsndfile }:
+
+stdenv.mkDerivation rec {
+  pname = "libbs2b";
+  version = "3.1.0";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/bs2b/${pname}-${version}.tar.bz2";
+    sha256 = "0vz442kkjn2h0dlxppzi4m5zx8qfyrivq581n06xzvnyxi5rg6a7";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ libsndfile ];
+
+  hardeningDisable = [ "format" ];
+
+  meta = {
+    homepage = "http://bs2b.sourceforge.net/";
+    description = "Bauer stereophonic-to-binaural DSP library";
+    license = lib.licenses.mit;
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/libgme/default.nix b/nixpkgs/pkgs/development/libraries/audio/libgme/default.nix
new file mode 100644
index 000000000000..2761eaf3753a
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/libgme/default.nix
@@ -0,0 +1,31 @@
+{ lib, stdenv, fetchFromBitbucket, cmake, removeReferencesTo }:
+
+stdenv.mkDerivation rec {
+  pname = "libgme";
+  version = "0.6.3";
+
+  meta = with lib; {
+    description = "A collection of video game music chip emulators";
+    homepage = "https://bitbucket.org/mpyne/game-music-emu/overview";
+    license = licenses.lgpl21;
+    platforms = platforms.all;
+    maintainers = with maintainers; [ lheckemann ];
+  };
+
+  src = fetchFromBitbucket {
+    owner = "mpyne";
+    repo = "game-music-emu";
+    rev = version;
+    sha256 = "100ahb4n4pvgcry9xzlf2fr4j57n5h9x7pvyhhxys4dcy8axqqsy";
+  };
+
+  nativeBuildInputs = [ cmake removeReferencesTo ];
+
+  # It used to reference it, in the past, but thanks to the postFixup hook, now
+  # it doesn't.
+  disallowedReferences = [ stdenv.cc.cc ];
+
+  postFixup = lib.optionalString stdenv.isLinux ''
+    remove-references-to -t ${stdenv.cc.cc} "$(readlink -f $out/lib/libgme.so)"
+  '';
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/libinstpatch/default.nix b/nixpkgs/pkgs/development/libraries/audio/libinstpatch/default.nix
new file mode 100644
index 000000000000..670dee26b2bf
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/libinstpatch/default.nix
@@ -0,0 +1,29 @@
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, glib, libsndfile }:
+
+stdenv.mkDerivation rec {
+  pname = "libinstpatch";
+  version = "1.1.6";
+
+  src = fetchFromGitHub {
+    owner = "swami";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-OU6/slrPDgzn9tvXZJKSWbcFbpS/EAsOi52FtjeYdvA=";
+  };
+
+  nativeBuildInputs = [ cmake pkg-config ];
+
+  propagatedBuildInputs = [ glib libsndfile ]; # Both are needed for includes.
+
+  cmakeFlags = [
+    "-DLIB_SUFFIX=" # Install in $out/lib.
+  ];
+
+  meta = with lib; {
+    homepage = "http://www.swamiproject.org/";
+    description = "MIDI instrument patch files support library";
+    license = licenses.lgpl21;
+    maintainers = with maintainers; [ orivej ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/libmysofa/default.nix b/nixpkgs/pkgs/development/libraries/audio/libmysofa/default.nix
new file mode 100644
index 000000000000..821a9ea9226a
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/libmysofa/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchFromGitHub, cmake, zlib }:
+
+stdenv.mkDerivation rec {
+  pname = "libmysofa";
+  version = "1.2";
+
+  src = fetchFromGitHub {
+    owner = "hoene";
+    repo = "libmysofa";
+    rev = "v${version}";
+    sha256 = "sha256-f+1CIVSxyScyNF92cPIiZwfnnCVrWfCZlbrIXtduIdY=";
+  };
+
+  nativeBuildInputs = [ cmake ];
+  buildInputs = [ zlib ];
+
+  cmakeFlags = [ "-DBUILD_TESTS=OFF" "-DCODE_COVERAGE=OFF" ];
+
+  meta = with lib; {
+    description = "Reader for AES SOFA files to get better HRTFs";
+    homepage = "https://github.com/hoene/libmysofa";
+    license = licenses.bsd3;
+    platforms = platforms.all;
+    maintainers = with maintainers; [ jfrankenau ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/libsmf/default.nix b/nixpkgs/pkgs/development/libraries/audio/libsmf/default.nix
new file mode 100644
index 000000000000..0c173a6a99e0
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/libsmf/default.nix
@@ -0,0 +1,21 @@
+{ lib, stdenv, fetchurl, autoreconfHook, glib, pkg-config }:
+
+stdenv.mkDerivation rec {
+  version = "1.3";
+  pname = "libsmf";
+  src = fetchurl {
+    url = "https://github.com/stump/libsmf/archive/${pname}-${version}.tar.gz";
+    sha256 = "1527pcc1vd0l5iks2yw8m0bymcrnih2md5465lwpzw0wgy4rky7n";
+  };
+
+  nativeBuildInputs = [ autoreconfHook pkg-config ];
+  buildInputs = [ glib ];
+
+  meta = with lib; {
+    description = "A C library for reading and writing Standard MIDI Files";
+    homepage = "https://github.com/stump/libsmf";
+    license = licenses.bsd2;
+    maintainers = [ maintainers.goibhniu ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/lilv/default.nix b/nixpkgs/pkgs/development/libraries/audio/lilv/default.nix
new file mode 100644
index 000000000000..f074287ab163
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/lilv/default.nix
@@ -0,0 +1,25 @@
+{ lib, stdenv, fetchurl, lv2, pkg-config, python3, serd, sord, sratom, wafHook }:
+
+stdenv.mkDerivation rec {
+  pname = "lilv";
+  version = "0.24.12";
+
+  src = fetchurl {
+    url = "https://download.drobilla.net/${pname}-${version}.tar.bz2";
+    sha256 = "sha256-JqN3kIkMnB+DggO0f1sjIDNP6SwCpNJuu+Jmnb12kGE=";
+  };
+
+  patches = [ ./lilv-pkgconfig.patch ];
+
+  nativeBuildInputs = [ pkg-config python3 wafHook ];
+  buildInputs = [ serd sord sratom ];
+  propagatedBuildInputs = [ lv2 ];
+
+  meta = with lib; {
+    homepage = "http://drobilla.net/software/lilv";
+    description = "A C library to make the use of LV2 plugins";
+    license = licenses.mit;
+    maintainers = [ maintainers.goibhniu ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/lilv/lilv-pkgconfig.patch b/nixpkgs/pkgs/development/libraries/audio/lilv/lilv-pkgconfig.patch
new file mode 100644
index 000000000000..a5a8c6007e43
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/lilv/lilv-pkgconfig.patch
@@ -0,0 +1,6 @@
+--- a/lilv.pc.in
++++ b/lilv.pc.in
+@@ -9 +9,2 @@ Description: Simple C library for hosting LV2 plugins
+-Requires: @LILV_PKG_DEPS@
++Requires: lv2
++Requires.private: @LILV_PKG_DEPS@
diff --git a/nixpkgs/pkgs/development/libraries/audio/lv2/default.nix b/nixpkgs/pkgs/development/libraries/audio/lv2/default.nix
new file mode 100644
index 000000000000..616ad5b0c892
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/lv2/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchurl, gtk2, libsndfile, pkg-config, python3, wafHook }:
+
+stdenv.mkDerivation rec {
+  pname = "lv2";
+  version = "1.18.2";
+
+  src = fetchurl {
+    url = "https://lv2plug.in/spec/${pname}-${version}.tar.bz2";
+    sha256 = "sha256-TokfvHRMBYVb6136gugisUkX3Wbpj4K4Iw29HHqy4F4=";
+  };
+
+  nativeBuildInputs = [ pkg-config wafHook ];
+  buildInputs = [ gtk2 libsndfile python3 ];
+
+  wafConfigureFlags = lib.optionals stdenv.isDarwin [ "--lv2dir=${placeholder "out"}/lib/lv2" ];
+
+  meta = with lib; {
+    homepage = "https://lv2plug.in";
+    description = "A plugin standard for audio systems";
+    license = licenses.mit;
+    maintainers = [ maintainers.goibhniu ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/lvtk/default.nix b/nixpkgs/pkgs/development/libraries/audio/lvtk/default.nix
new file mode 100644
index 000000000000..cecae743da05
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/lvtk/default.nix
@@ -0,0 +1,34 @@
+{ lib, stdenv, fetchurl, boost, gtkmm2, lv2, pkg-config, python, wafHook }:
+
+stdenv.mkDerivation rec {
+  pname = "lvtk";
+  version = "1.2.0";
+
+  src = fetchurl {
+    url = "https://github.com/lvtk/lvtk/archive/${version}.tar.gz";
+    sha256 = "03nbj2cqcklqwh50zj2gwm07crh5iwqbpxbpzwbg5hvgl4k4rnjd";
+  };
+
+  nativeBuildInputs = [ pkg-config python wafHook ];
+  buildInputs = [ boost gtkmm2 lv2 ];
+
+  enableParallelBuilding = true;
+
+  # Fix including the boost libraries during linking
+  postPatch = ''
+    sed -i '/target[ ]*= "ttl2c"/ ilib=["boost_system"],' tools/wscript_build
+  '';
+
+  wafConfigureFlags = [
+    "--boost-includes=${boost.dev}/include"
+    "--boost-libs=${boost.out}/lib"
+  ];
+
+  meta = with lib; {
+    description = "A set C++ wrappers around the LV2 C API";
+    homepage = "https://lvtk.org/";
+    license = licenses.gpl3;
+    maintainers = [ maintainers.goibhniu ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/mbelib/default.nix b/nixpkgs/pkgs/development/libraries/audio/mbelib/default.nix
new file mode 100644
index 000000000000..f13f6d7063cb
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/mbelib/default.nix
@@ -0,0 +1,29 @@
+{ lib, stdenv, fetchFromGitHub, cmake }:
+
+stdenv.mkDerivation rec {
+  pname = "mbelib";
+  version = "1.3.0";
+
+  src = fetchFromGitHub {
+    owner = "szechyjs";
+    repo = "mbelib";
+    rev = "v${version}";
+    sha256 = "0v6b7nf8fgxy7vzgcwffqyql5zhldrz30c88k1ylbjp78hwh4rif";
+  };
+
+  nativeBuildInputs = [ cmake ];
+
+  doCheck = true;
+  preCheck = ''
+    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH''${LD_LIBRARY_PATH:+:}$PWD
+    export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH''${DYLD_LIBRARY_PATH:+:}$PWD
+  '';
+
+  meta = with lib; {
+    description = "P25 Phase 1 and ProVoice vocoder";
+    homepage = https://github.com/szechyjs/mbelib;
+    license = licenses.isc;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ andrew-d ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/ntk/default.nix b/nixpkgs/pkgs/development/libraries/audio/ntk/default.nix
new file mode 100644
index 000000000000..ecb0215a2287
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/ntk/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchFromGitHub, cairo, libjpeg, libXft, pkg-config, python2, wafHook }:
+
+stdenv.mkDerivation rec {
+  pname = "ntk";
+  version = "1.3.1000";
+  src = fetchFromGitHub {
+    owner = "original-male";
+    repo = "ntk";
+    rev = "v${version}";
+    sha256 = "0j38mhnfqy6swcrnc5zxcwlqi8b1pgklyghxk6qs1lf4japv2zc0";
+  };
+
+  nativeBuildInputs = [ pkg-config wafHook ];
+  buildInputs = [
+    cairo libjpeg libXft python2
+  ];
+
+  meta = {
+    description = "Fork of FLTK 1.3.0 with additional functionality";
+    version = version;
+    homepage = "http://non.tuxfamily.org/";
+    license = lib.licenses.lgpl21;
+    maintainers = with lib.maintainers; [ magnetophon nico202 ];
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/qm-dsp/default.nix b/nixpkgs/pkgs/development/libraries/audio/qm-dsp/default.nix
new file mode 100644
index 000000000000..3d8e15f97cdb
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/qm-dsp/default.nix
@@ -0,0 +1,53 @@
+{ lib, stdenv
+, fetchFromGitHub
+, fetchpatch
+, kissfft
+}:
+
+stdenv.mkDerivation rec {
+  pname = "qm-dsp";
+  version = "1.7.1";
+
+  src = fetchFromGitHub {
+    owner = "c4dm";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "1vkb1xr2hjcaw88gig7rknlwsx01lm0w94d2z0rk5vz9ih4fslvv";
+  };
+
+  patches = [
+    # Make installable
+    (fetchpatch {
+      url = "https://src.fedoraproject.org/rpms/qm-dsp/raw/6eb385e2f970c4150f9c8eba73b558318475ed15/f/qm-dsp-install.patch";
+      sha256 = "071g30p17ya0pknzqa950pb93vrgp2024ray8axn22c44gvy147c";
+    })
+    (fetchpatch {
+      url = "https://src.fedoraproject.org/rpms/qm-dsp/raw/6eb385e2f970c4150f9c8eba73b558318475ed15/f/qm-dsp-flags.patch";
+      sha256 = "127n6j5bsp94kf2m1zqfvkf4iqk1h5f7w778bk7w02vi45nm4x6q";
+      postFetch = ''
+        sed -i 's~/Makefile~/build/linux/Makefile.linux32~g' "$out"
+      '';
+    })
+  ];
+
+  buildInputs = [
+    kissfft
+  ];
+
+  makefile = "build/linux/Makefile.linux32";
+
+  makeFlags = [
+    "PREFIX=${placeholder "out"}"
+    "LIBDIR=${placeholder "out"}/lib"
+  ];
+
+  NIX_CFLAGS_COMPILE = "-I${kissfft}/include/kissfft";
+
+  meta = with lib; {
+    description = "A C++ library of functions for DSP and Music Informatics purposes";
+    homepage = "https://code.soundsoftware.ac.uk/projects/qm-dsp";
+    license = licenses.gpl2Plus;
+    maintainers = [ maintainers.goibhniu ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/raul/default.nix b/nixpkgs/pkgs/development/libraries/audio/raul/default.nix
new file mode 100644
index 000000000000..b1a8288c5f04
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/raul/default.nix
@@ -0,0 +1,27 @@
+{ lib, stdenv, fetchgit, boost, gtk2, pkg-config, python3, wafHook }:
+
+stdenv.mkDerivation rec {
+  pname = "raul";
+  version = "unstable-2019-12-09";
+  name = "${pname}-${version}";
+
+  src = fetchgit {
+    url = "https://gitlab.com/drobilla/raul.git";
+    fetchSubmodules = true;
+    rev = "e87bb398f025912fb989a09f1450b838b251aea1";
+    sha256 = "1z37jb6ghc13b8nv8a8hcg669gl8vh4ni9djvfgga9vcz8rmcg8l";
+  };
+
+  nativeBuildInputs = [ pkg-config wafHook python3 ];
+  buildInputs = [ boost gtk2 ];
+
+  strictDeps = true;
+
+  meta = with lib; {
+    description = "A C++ utility library primarily aimed at audio/musical applications";
+    homepage = "http://drobilla.net/software/raul";
+    license = licenses.gpl3;
+    maintainers = [ maintainers.goibhniu ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/rtaudio/default.nix b/nixpkgs/pkgs/development/libraries/audio/rtaudio/default.nix
new file mode 100644
index 000000000000..4f2f78f20cf0
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/rtaudio/default.nix
@@ -0,0 +1,65 @@
+{ stdenv
+, lib
+, config
+, fetchFromGitHub
+, fetchpatch
+, cmake
+, pkg-config
+, alsaSupport ? stdenv.hostPlatform.isLinux
+, alsa-lib
+, pulseaudioSupport ? config.pulseaudio or stdenv.hostPlatform.isLinux
+, libpulseaudio
+, jackSupport ? true
+, jack
+, coreaudioSupport ? stdenv.hostPlatform.isDarwin
+, CoreAudio
+}:
+
+stdenv.mkDerivation rec {
+  version = "5.1.0";
+  pname = "rtaudio";
+
+  src = fetchFromGitHub {
+    owner = "thestk";
+    repo = "rtaudio";
+    rev = version;
+    sha256 = "1pglnjz907ajlhnlnig3p0sx7hdkpggr8ss7b3wzf1lykzgv9l52";
+  };
+
+  patches = [
+    # Fixes missing headers & install location
+    # Drop with version > 5.1.0
+    (fetchpatch {
+      name = "RtAudio-Adjust-CMake-public-header-installs-to-match-autotools.patch";
+      url = "https://github.com/thestk/rtaudio/commit/4273cf7572b8f51b5996cf6b42e3699cc6b165da.patch";
+      sha256 = "1p0idll0xsfk3jwjg83jkxkaf20gk0wqa7l982ni389rn6i4n26p";
+    })
+  ];
+
+  postPatch = ''
+    substituteInPlace rtaudio.pc.in \
+      --replace 'Requires:' 'Requires.private:'
+  '';
+
+  nativeBuildInputs = [ cmake pkg-config ];
+
+  buildInputs = lib.optional alsaSupport alsa-lib
+    ++ lib.optional pulseaudioSupport libpulseaudio
+    ++ lib.optional jackSupport jack
+    ++ lib.optional coreaudioSupport CoreAudio;
+
+  cmakeFlags = [
+    "-DRTAUDIO_API_ALSA=${if alsaSupport then "ON" else "OFF"}"
+    "-DRTAUDIO_API_PULSE=${if pulseaudioSupport then "ON" else "OFF"}"
+    "-DRTAUDIO_API_JACK=${if jackSupport then "ON" else "OFF"}"
+    "-DRTAUDIO_API_CORE=${if coreaudioSupport then "ON" else "OFF"}"
+  ];
+
+  meta = with lib; {
+    description = "A set of C++ classes that provide a cross platform API for realtime audio input/output";
+    homepage = "https://www.music.mcgill.ca/~gary/rtaudio/";
+    license = licenses.mit;
+    maintainers = with maintainers; [ magnetophon ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix b/nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix
new file mode 100644
index 000000000000..6c75b9866e89
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/rtmidi/default.nix
@@ -0,0 +1,71 @@
+{ stdenv
+, lib
+, fetchFromGitHub
+, fetchpatch
+, cmake
+, pkg-config
+, alsaSupport ? stdenv.hostPlatform.isLinux
+, alsa-lib
+, jackSupport ? true
+, jack
+, coremidiSupport ? stdenv.hostPlatform.isDarwin
+, CoreMIDI
+, CoreAudio
+, CoreServices
+}:
+
+stdenv.mkDerivation rec {
+  version = "4.0.0";
+  pname = "rtmidi";
+
+  src = fetchFromGitHub {
+    owner = "thestk";
+    repo = "rtmidi";
+    rev = version;
+    sha256 = "1g31p6a96djlbk9jh5r4pjly3x76lhccva9hrw6xzdma8dsjzgyq";
+  };
+
+  patches = [
+    # PR #230, fix CMake problems
+    (fetchpatch {
+      name = "RtMidi-Fix-JACK_HAS_PORT_RENAME-define.patch";
+      url = "https://github.com/thestk/rtmidi/pull/230/commits/768a30a61b60240b66cc2d43bc27a544ff9f1622.patch";
+      sha256 = "1sym4f7nb2qyyxfhi1l0xsm2hfh6gddn81y36qvfq4mcs33vvid0";
+    })
+    (fetchpatch {
+      name = "RtMidi-Add-prefix-define-for-pkgconfig.patch";
+      url = "https://github.com/thestk/rtmidi/pull/230/commits/7a32e23e3f6cb43c0d2d58443ce205d438e76f44.patch";
+      sha256 = "06im8mb05wah6bnkadw2gpkhmilxb8p84pxqr50b205cchpq304w";
+    })
+    (fetchpatch {
+      name = "RtMidi-Adjust-public-header-installs-to-match-autotools.patch";
+      url = "https://github.com/thestk/rtmidi/pull/230/commits/892fe5492f0e787484fa4a37027b08c265ce001f.patch";
+      sha256 = "0ca9m42xa3gmycimzvzvl67wa266xq9pfp1b4v555rh2fp52kbcj";
+    })
+  ];
+
+  postPatch = ''
+    substituteInPlace rtmidi.pc.in \
+      --replace 'Requires:' 'Requires.private:'
+  '';
+
+  nativeBuildInputs = [ cmake pkg-config ];
+
+  buildInputs = lib.optional alsaSupport alsa-lib
+    ++ lib.optional jackSupport jack
+    ++ lib.optionals coremidiSupport [ CoreMIDI CoreAudio CoreServices ];
+
+  cmakeFlags = [
+    "-DRTMIDI_API_ALSA=${if alsaSupport then "ON" else "OFF"}"
+    "-DRTMIDI_API_JACK=${if jackSupport then "ON" else "OFF"}"
+    "-DRTMIDI_API_CORE=${if coremidiSupport then "ON" else "OFF"}"
+  ];
+
+  meta = with lib; {
+    description = "A set of C++ classes that provide a cross platform API for realtime MIDI input/output";
+    homepage = "https://www.music.mcgill.ca/~gary/rtmidi/";
+    license = licenses.mit;
+    maintainers = with maintainers; [ magnetophon ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/sratom/default.nix b/nixpkgs/pkgs/development/libraries/audio/sratom/default.nix
new file mode 100644
index 000000000000..bc8dc70f9b47
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/sratom/default.nix
@@ -0,0 +1,22 @@
+{ lib, stdenv, fetchurl, lv2, pkg-config, python3, serd, sord, wafHook }:
+
+stdenv.mkDerivation rec {
+  pname = "sratom";
+  version = "0.6.8";
+
+  src = fetchurl {
+    url = "https://download.drobilla.net/${pname}-${version}.tar.bz2";
+    sha256 = "sha256-Ossysa3Forf6za3i4IGLzWxx8j+EoevBeBW7eg0tAt8=";
+  };
+
+  nativeBuildInputs = [ pkg-config wafHook python3 ];
+  buildInputs = [ lv2 serd sord ];
+
+  meta = with lib; {
+    homepage = "http://drobilla.net/software/sratom";
+    description = "A library for serialising LV2 atoms to/from RDF";
+    license = licenses.mit;
+    maintainers = [ maintainers.goibhniu ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/suil/default.nix b/nixpkgs/pkgs/development/libraries/audio/suil/default.nix
new file mode 100644
index 000000000000..1c978a18f8f9
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/suil/default.nix
@@ -0,0 +1,36 @@
+{ stdenv, lib, fetchurl, gtk2, lv2, pkg-config, python3, serd, sord, sratom
+, wafHook
+, withQt4 ? true, qt4 ? null
+, withQt5 ? false, qt5 ? null }:
+
+# I haven't found an XOR operator in nix...
+assert withQt4 || withQt5;
+assert !(withQt4 && withQt5);
+
+stdenv.mkDerivation rec {
+  pname = "suil";
+  version = "0.10.6";
+  name = "${pname}-qt${if withQt4 then "4" else "5"}-${version}";
+
+  src = fetchurl {
+    url = "https://download.drobilla.net/${pname}-${version}.tar.bz2";
+    sha256 = "0z4v01pjw4wh65x38w6icn28wdwxz13ayl8hvn4p1g9kmamp1z06";
+  };
+
+  nativeBuildInputs = [ pkg-config wafHook python3 ];
+  buildInputs = [ gtk2 lv2 serd sord sratom ]
+    ++ (lib.optionals withQt4 [ qt4 ])
+    ++ (lib.optionals withQt5 (with qt5; [ qtbase qttools ]));
+
+  dontWrapQtApps = true;
+
+  strictDeps = true;
+
+  meta = with lib; {
+    homepage = "http://drobilla.net/software/suil";
+    description = "A lightweight C library for loading and wrapping LV2 plugin UIs";
+    license = licenses.mit;
+    maintainers = with maintainers; [ goibhniu ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/vamp-plugin-sdk/default.nix b/nixpkgs/pkgs/development/libraries/audio/vamp-plugin-sdk/default.nix
new file mode 100644
index 000000000000..4d033d99d295
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/vamp-plugin-sdk/default.nix
@@ -0,0 +1,29 @@
+# set VAMP_PATH ?
+# plugins availible on sourceforge and http://www.vamp-plugins.org/download.html (various licenses)
+
+{ lib, stdenv, fetchFromGitHub, pkg-config, libsndfile }:
+
+stdenv.mkDerivation rec {
+  pname = "vamp-plugin-sdk";
+  version = "2.10";
+
+  src = fetchFromGitHub {
+    owner = "c4dm";
+    repo = "vamp-plugin-sdk";
+    rev = "vamp-plugin-sdk-v${version}";
+    sha256 = "1lhmskcyk7qqfikmasiw7wjry74gc8g5q6a3j1iya84yd7ll0cz6";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ libsndfile ];
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    description = "Audio processing plugin system for plugins that extract descriptive information from audio data";
+    homepage = "https://vamp-plugins.org/";
+    license = licenses.bsd3;
+    maintainers = [ maintainers.goibhniu maintainers.marcweber ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/zita-alsa-pcmi/default.nix b/nixpkgs/pkgs/development/libraries/audio/zita-alsa-pcmi/default.nix
new file mode 100644
index 000000000000..afecd561b727
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/zita-alsa-pcmi/default.nix
@@ -0,0 +1,64 @@
+{ lib, stdenv, fetchurl , alsa-lib, }:
+
+stdenv.mkDerivation rec {
+  pname = "zita-alsa-pcmi";
+  version = "0.3.2";
+  src = fetchurl {
+    url = "http://kokkinizita.linuxaudio.org/linuxaudio/downloads/${pname}-${version}.tar.bz2";
+    sha256 = "12d7vdg74yh21w69qi0wg57iz4876j94qbiq09bvscih6xz9y78s";
+  };
+
+  buildInputs = [ alsa-lib ];
+
+  buildPhase = ''
+    cd source
+    make PREFIX="$out"
+
+    # create lib link for building apps
+    ln -s libzita-alsa-pcmi.so.$version libzita-alsa-pcmi.so
+
+    # apps
+    cd ../apps
+    CXXFLAGS+=" -I../source" \
+    LDFLAGS+=" -L../source" \
+    make PREFIX="$out"
+  '';
+
+  installPhase = ''
+    mkdir "$out"
+    mkdir "$out/lib"
+    mkdir "$out/include"
+    mkdir "$out/bin"
+
+    cd ../source
+
+    # source
+    install -Dm755 libzita-alsa-pcmi.so.$version \
+      "$out/lib/libzita-alsa-pcmi.so.$version"
+
+    # link
+    ln -s libzita-alsa-pcmi.so.$version \
+      "$out/lib/libzita-alsa-pcmi.so"
+    ln -s libzita-alsa-pcmi.so.$version \
+      "$out/lib/libzita-alsa-pcmi.so.0"
+
+    # header
+    install -Dm644 zita-alsa-pcmi.h \
+      "$out/include/zita-alsa-pcmi.h"
+
+    # apps
+    install -Dm755 ../apps/alsa_delay \
+      "$out/bin/alsa_delay"
+    install -Dm755 ../apps/alsa_loopback \
+      "$out/bin/alsa_loopback"
+  '';
+
+  meta = {
+    description = "The successor of clalsadrv, provides easy access to ALSA PCM devices";
+    version = version;
+    homepage = "http://kokkinizita.linuxaudio.org/linuxaudio/downloads/index.html";
+    license = lib.licenses.gpl3;
+    maintainers = [ lib.maintainers.magnetophon ];
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/zita-convolver/default.nix b/nixpkgs/pkgs/development/libraries/audio/zita-convolver/default.nix
new file mode 100644
index 000000000000..3b77bf549ca6
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/zita-convolver/default.nix
@@ -0,0 +1,36 @@
+{ lib, stdenv, fetchurl, fftwFloat }:
+
+stdenv.mkDerivation rec {
+  pname = "zita-convolver";
+  version = "4.0.3";
+  src = fetchurl {
+    url = "http://kokkinizita.linuxaudio.org/linuxaudio/downloads/${pname}-${version}.tar.bz2";
+    sha256 = "0prji66p86z2bzminywkwchr5bfgxcg2i8y803pydd1hzf2198cs";
+  };
+
+  buildInputs = [ fftwFloat ];
+
+  patchPhase = ''
+    cd source
+    sed -e "s@ldconfig@@" -i Makefile
+  '';
+
+  makeFlags = [
+    "PREFIX=$(out)"
+    "SUFFIX="
+  ];
+
+  postInstall = ''
+    # create lib link for building apps
+    ln -s $out/lib/libzita-convolver.so.${version} $out/lib/libzita-convolver.so.${lib.versions.major version}
+  '';
+
+  meta = {
+    description = "Convolution library by Fons Adriaensen";
+    version = version;
+    homepage = "http://kokkinizita.linuxaudio.org/linuxaudio/downloads/index.html";
+    license = lib.licenses.gpl2;
+    maintainers = [ lib.maintainers.magnetophon ];
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/libraries/audio/zita-resampler/default.nix b/nixpkgs/pkgs/development/libraries/audio/zita-resampler/default.nix
new file mode 100644
index 000000000000..3b3c005a015b
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/audio/zita-resampler/default.nix
@@ -0,0 +1,33 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  pname = "zita-resampler";
+  version = "1.8.0";
+  src = fetchurl {
+    url = "http://kokkinizita.linuxaudio.org/linuxaudio/downloads/${pname}-${version}.tar.bz2";
+    sha256 = "sha256-5XRPI8VN0Vs/eDpoe9h57uKmkKRUWhW0nEzwN6pGSqI=";
+  };
+
+  makeFlags = [
+    "PREFIX=$(out)"
+    "SUFFIX="
+  ];
+
+  patchPhase = ''
+    cd source
+    sed -e "s@ldconfig@@" -i Makefile
+  '';
+
+  fixupPhase = ''
+    ln -s $out/lib/libzita-resampler.so.$version $out/lib/libzita-resampler.so.1
+  '';
+
+  meta = {
+    description = "Resample library by Fons Adriaensen";
+    version = version;
+    homepage = "http://kokkinizita.linuxaudio.org/linuxaudio/downloads/index.html";
+    license = lib.licenses.gpl2;
+    maintainers = [ lib.maintainers.magnetophon ];
+    platforms = lib.platforms.linux;
+  };
+}