about summary refs log tree commit diff
path: root/nixpkgs/pkgs/by-name/ys
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2024-02-20 12:16:56 +0100
committerAlyssa Ross <hi@alyssa.is>2024-02-20 12:16:56 +0100
commitb24d64b3b1ef897f07cd072a88a9881cb330aa7f (patch)
treea87bb2eed9af3ef1efd51dd65221d91f0c949041 /nixpkgs/pkgs/by-name/ys
parent73338df7473bb3810e70a16b8b0cba4f0f606f2b (diff)
parentfa15b53dbea5028db38d6e09b4cef6eba42aeebb (diff)
downloadnixlib-b24d64b3b1ef897f07cd072a88a9881cb330aa7f.tar
nixlib-b24d64b3b1ef897f07cd072a88a9881cb330aa7f.tar.gz
nixlib-b24d64b3b1ef897f07cd072a88a9881cb330aa7f.tar.bz2
nixlib-b24d64b3b1ef897f07cd072a88a9881cb330aa7f.tar.lz
nixlib-b24d64b3b1ef897f07cd072a88a9881cb330aa7f.tar.xz
nixlib-b24d64b3b1ef897f07cd072a88a9881cb330aa7f.tar.zst
nixlib-b24d64b3b1ef897f07cd072a88a9881cb330aa7f.zip
Merge branch 'nixos-unstable-small' of https://github.com/NixOS/nixpkgs
Diffstat (limited to 'nixpkgs/pkgs/by-name/ys')
-rw-r--r--nixpkgs/pkgs/by-name/ys/ysfx/package.nix63
1 files changed, 63 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/by-name/ys/ysfx/package.nix b/nixpkgs/pkgs/by-name/ys/ysfx/package.nix
new file mode 100644
index 000000000000..ac7807df8cd5
--- /dev/null
+++ b/nixpkgs/pkgs/by-name/ys/ysfx/package.nix
@@ -0,0 +1,63 @@
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config
+, freetype, juce, libX11, libXcursor, libXext, libXinerama, libXrandr, libglvnd
+}:
+
+stdenv.mkDerivation rec {
+  pname = "ysfx";
+  version = "0-unstable-2022-07-31";
+
+  src = fetchFromGitHub {
+    owner = "jpcima";
+    repo = "ysfx";
+    rev = "8077347ccf4115567aed81400281dca57acbb0cc";
+    hash = "sha256-pObuOb/PA9WkKB2FdMDCOd9TKmML+Sj2MybLP0YwT+8=";
+  };
+
+  # Provide latest dr_libs.
+  dr_libs = fetchFromGitHub {
+    owner = "mackron";
+    repo = "dr_libs";
+    rev = "e4a7765e598e9e54dc0f520b7e4416359bee80cc";
+    hash = "sha256-rWabyCP47vd+EfibBWy6iQY/nFN/OXPNhkuOTSboJaU=";
+  };
+
+  prePatch = ''
+    rmdir thirdparty/dr_libs
+    ln -s ${dr_libs} thirdparty/dr_libs
+  '';
+
+  nativeBuildInputs = [ cmake pkg-config ];
+
+  buildInputs = [
+    freetype
+    juce
+    libX11
+    libXcursor
+    libXext
+    libXinerama
+    libXrandr
+    libglvnd
+  ];
+
+  cmakeFlags = [
+    "-DYSFX_PLUGIN_COPY=OFF"
+    "-DYSFX_PLUGIN_USE_SYSTEM_JUCE=ON"
+  ];
+
+  installPhase = ''
+    runHook preInstall
+
+    mkdir -p $out/lib
+    cp -r ysfx_plugin_artefacts/Release/VST3 $out/lib/vst3
+
+    runHook postInstall
+  '';
+
+  meta = with lib; {
+    description = "Hosting library for JSFX";
+    homepage = "https://github.com/jpcima/ysfx";
+    license = licenses.asl20;
+    maintainers = with maintainers; [ orivej ];
+    platforms = platforms.linux;
+  };
+}