about summary refs log tree commit diff
path: root/pkgs/applications/audio
diff options
context:
space:
mode:
authorAaron Andersen <aaron@fosslib.net>2019-05-19 09:10:53 -0400
committerGitHub <noreply@github.com>2019-05-19 09:10:53 -0400
commita0f36ab87de6aeb486cdd8a151b8ac7319203001 (patch)
tree59bf7f40d0232581509b045c976fa12d5465e6a5 /pkgs/applications/audio
parent65f30263b9cabc999d47bb69f60cfdf4479ed7c0 (diff)
parent5f253add01594de59c672ccc200f7f57bb29985d (diff)
downloadnixlib-a0f36ab87de6aeb486cdd8a151b8ac7319203001.tar
nixlib-a0f36ab87de6aeb486cdd8a151b8ac7319203001.tar.gz
nixlib-a0f36ab87de6aeb486cdd8a151b8ac7319203001.tar.bz2
nixlib-a0f36ab87de6aeb486cdd8a151b8ac7319203001.tar.lz
nixlib-a0f36ab87de6aeb486cdd8a151b8ac7319203001.tar.xz
nixlib-a0f36ab87de6aeb486cdd8a151b8ac7319203001.tar.zst
nixlib-a0f36ab87de6aeb486cdd8a151b8ac7319203001.zip
Merge pull request #61464 from fgaz/sfxr/init
sfxr: init at 1.2.1
Diffstat (limited to 'pkgs/applications/audio')
-rw-r--r--pkgs/applications/audio/sfxr/default.nix56
1 files changed, 56 insertions, 0 deletions
diff --git a/pkgs/applications/audio/sfxr/default.nix b/pkgs/applications/audio/sfxr/default.nix
new file mode 100644
index 000000000000..fbd0f3c5def3
--- /dev/null
+++ b/pkgs/applications/audio/sfxr/default.nix
@@ -0,0 +1,56 @@
+{ stdenv
+, fetchurl
+, pkgconfig
+, desktop-file-utils
+, SDL
+, gtk3
+, gsettings-desktop-schemas
+, wrapGAppsHook
+}:
+
+stdenv.mkDerivation rec {
+  pname = "sfxr";
+  version = "1.2.1";
+
+  src = fetchurl {
+    url = "http://www.drpetter.se/files/sfxr-sdl-${version}.tar.gz";
+    sha256 = "0dfqgid6wzzyyhc0ha94prxax59wx79hqr25r6if6by9cj4vx4ya";
+  };
+
+  postPatch = ''
+    substituteInPlace Makefile --replace "usr/" ""
+    substituteInPlace sdlkit.h --replace \
+      "/usr/share/sfxr/sfxr.bmp" \
+      "$out/share/sfxr/sfxr.bmp"
+    substituteInPlace main.cpp \
+      --replace \
+      "/usr/share/sfxr/font.tga" \
+      "$out/share/sfxr/font.tga" \
+      --replace \
+      "/usr/share/sfxr/ld48.tga" \
+      "$out/share/sfxr/ld48.tga"
+  '';
+
+  nativeBuildInputs = [
+    pkgconfig
+    desktop-file-utils
+  ];
+
+  buildInputs = [
+    SDL
+    gtk3
+    gsettings-desktop-schemas
+    wrapGAppsHook
+  ];
+
+  makeFlags = [ "DESTDIR=$(out)" ];
+
+  meta = with stdenv.lib; {
+    homepage = "http://www.drpetter.se/project_sfxr.html";
+    description = "A videogame sound effect generator";
+    license = licenses.mit;
+    maintainers = with maintainers; [ fgaz ];
+    platforms = platforms.unix;
+  };
+}
+