diff --git a/pkgs/applications/video/vlc/default.nix b/pkgs/applications/video/vlc/default.nix index ce9a72aebf9a..5ef62ff6b466 100644 --- a/pkgs/applications/video/vlc/default.nix +++ b/pkgs/applications/video/vlc/default.nix @@ -7,8 +7,8 @@ , mpeg2dec, systemd, gnutls, avahi, libcddb, libjack2, SDL, SDL_image , libmtp, unzip, taglib, libkate, libtiger, libv4l, samba, libssh2, liboggz , libass, libva, libdvbpsi, libdc1394, libraw1394, libopus -, libvdpau, libsamplerate, live555, fluidsynth, wayland, wayland-protocols -, ncurses, srt +, libvdpau, libsamplerate, libspatialaudio, live555, fluidsynth +, wayland, wayland-protocols, ncurses, srt , onlyLibVLC ? false , withQt5 ? true, qtbase, qtsvg, qtx11extras, wrapQtAppsHook , jackSupport ? false @@ -43,7 +43,7 @@ stdenv.mkDerivation rec { libkate libtiger libv4l samba libssh2 liboggz libass libdvbpsi libva xorg.xlibsWrapper xorg.libXv xorg.libXvMC xorg.libXpm xorg.xcbutilkeysyms libdc1394 libraw1394 libopus libebml libmatroska libvdpau libsamplerate - fluidsynth wayland wayland-protocols ncurses srt + libspatialaudio fluidsynth wayland wayland-protocols ncurses srt ] ++ optional (!stdenv.hostPlatform.isAarch64 && !stdenv.hostPlatform.isAarch32) live555 ++ optionals withQt5 [ qtbase qtsvg qtx11extras ] ++ optionals skins2Support (with xorg; [ libXpm freetype libXext libXinerama ]) @@ -101,6 +101,12 @@ stdenv.mkDerivation rec { sed -i 's|^#define CONFIGURE_LINE.*$|#define CONFIGURE_LINE ""|g' config.h ''; + # Add missing SOFA files + # Given in EXTRA_DIST, but not in install-data target + postInstall = '' + cp -R share/hrtfs $out/share/vlc + ''; + meta = with lib; { description = "Cross-platform media player and streaming server"; homepage = "http://www.videolan.org/vlc/"; diff --git a/pkgs/development/libraries/libspatialaudio/default.nix b/pkgs/development/libraries/libspatialaudio/default.nix new file mode 100644 index 000000000000..9f3453d51308 --- /dev/null +++ b/pkgs/development/libraries/libspatialaudio/default.nix @@ -0,0 +1,21 @@ +{ lib, stdenv, fetchFromGitHub, cmake, libmysofa, zlib }: +stdenv.mkDerivation { + name = "libspatialaudio"; + src = fetchFromGitHub { + owner = "videolabs"; + repo = "libspatialaudio"; + rev = "0.3.0"; + hash = "sha256-sPnQPD41AceXM4uGqWXMYhuQv0TUkA6TZP8ChxUFIoI="; + }; + buildInputs = [ cmake libmysofa zlib ]; + configurePhase = "cmake -DCMAKE_INSTALL_PREFIX=$out ."; + + meta = { + description = + "Ambisonic encoding / decoding and binauralization library in C++"; + homepage = "https://github.com/videolabs/libspatialaudio"; + license = lib.licenses.lgpl21Plus; + platforms = lib.platforms.linux; + }; +} + diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 884890c46ac9..4848e0fab438 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -18324,6 +18324,8 @@ with pkgs; libstrophe = callPackage ../development/libraries/libstrophe { }; + libspatialaudio = callPackage ../development/libraries/libspatialaudio { }; + libspatialindex = callPackage ../development/libraries/libspatialindex { }; libspatialite = callPackage ../development/libraries/libspatialite { };