From 63ade2da5d76272818f2c0e287087a8e6439e324 Mon Sep 17 00:00:00 2001 From: Adam Avramov Date: Thu, 12 Mar 2020 00:38:21 +0100 Subject: [PATCH 1/2] airwave: use vstsdk366_27_06_2016_build_61 * The currently required version (`vstsdk368_08_11_2017_build_121.zip`) seems to have fallen off the Internet. * The latest version (`vst-sdk_3.6.14_build-24_2019-11-29.zip`) can be automatically downloaded from Steinberg's servers, however it does not contain the VST2 SDK headers needed by Airwave. * I've raised an issue on the [Steinberg VST SDK GitHub](https://github.com/steinbergmedia/vst3sdk/issues/51) to make the VST2 SDK easily available. * In the meantime, I propose this fix. It's the only way I've managed to build Airwave from nixpkgs; caveat, I am yet to test it with any real Windows VSTs. --- pkgs/applications/audio/airwave/default.nix | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/audio/airwave/default.nix b/pkgs/applications/audio/airwave/default.nix index 1d91ad4d2be19..6b6930d00e244 100644 --- a/pkgs/applications/audio/airwave/default.nix +++ b/pkgs/applications/audio/airwave/default.nix @@ -1,5 +1,5 @@ { stdenv, multiStdenv, cmake, fetchFromGitHub, file, libX11, makeWrapper -, qt5, requireFile, unzip, wine +, qt5, fetchurl, unzip, wine }: let @@ -14,13 +14,12 @@ let }; vst-sdk = stdenv.mkDerivation rec { - name = "vstsdk368_08_11_2017_build_121"; - src = requireFile { - name = "${name}.zip"; - url = "http://www.steinberg.net/en/company/developers.html"; - sha256 = "e0f235d8826d70f1ae0ae5929cd198acae1ecff74612fde5c60cbfb45c2f4a70"; - }; + name = "vstsdk366_27_06_2016_build_61"; nativeBuildInputs = [ unzip ]; + src = fetchurl { + url = "https://www.steinberg.net/sdk_downloads/${name}.zip"; + sha256 = "05gsr13bpi2hhp34rvhllsvmn44rqvmjdpg9fsgfzgylfkz0kiki"; + }; installPhase = "cp -r . $out"; meta.license = stdenv.lib.licenses.unfree; }; @@ -63,7 +62,7 @@ multiStdenv.mkDerivation { # Cf. https://github.com/phantom-code/airwave/issues/57 hardeningDisable = [ "format" ]; - cmakeFlags = [ "-DVSTSDK_PATH=${vst-sdk}/VST2_SDK" ]; + cmakeFlags = [ "-DVSTSDK_PATH=${vst-sdk}" ]; postInstall = '' mv $out/bin $out/libexec From 1a43ed49dac5419e146d0c6f6da1b678c1fbf388 Mon Sep 17 00:00:00 2001 From: Adam Avramov Date: Thu, 12 Mar 2020 01:50:08 +0100 Subject: [PATCH 2/2] airwave: add qt5.wrapQtAppsHook * Replacing `multiStdenv.mkDerivation` with `qt5.makeDerivation` is not an option, making this one out of 2 derivations in nixpkgs to depend on `multiStdenv`. * However, adding `qt5.wrapQtAppsHook` to `nativeBuildInputs` is enough for the derivation to build; the resulting `airwave-manager` binary finds its runtime dependencies successfully. * Next: let's try bridging an actual plugin. --- pkgs/applications/audio/airwave/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/applications/audio/airwave/default.nix b/pkgs/applications/audio/airwave/default.nix index 6b6930d00e244..0bf1fa658f8f6 100644 --- a/pkgs/applications/audio/airwave/default.nix +++ b/pkgs/applications/audio/airwave/default.nix @@ -41,7 +41,7 @@ multiStdenv.mkDerivation { src = airwave-src; - nativeBuildInputs = [ cmake makeWrapper ]; + nativeBuildInputs = [ cmake makeWrapper qt5.wrapQtAppsHook ]; buildInputs = [ file libX11 qt5.qtbase wine-xembed ];