about summary refs log tree commit diff
path: root/pkgs/applications/graphics
diff options
context:
space:
mode:
authorMario Rodas <marsam@users.noreply.github.com>2020-01-25 17:43:00 -0500
committerGitHub <noreply@github.com>2020-01-25 17:43:00 -0500
commitc4f1e93514ceef085bdee937557f2a61e2e6aaf6 (patch)
tree094dbe44fad52f9c183de50ecc513a3695f9dd42 /pkgs/applications/graphics
parent456992405ceaaa34b9302e199a3322b79e4cf048 (diff)
parent57092f7ef17adfca9817f0ad9d713e1c5114ddff (diff)
downloadnixlib-c4f1e93514ceef085bdee937557f2a61e2e6aaf6.tar
nixlib-c4f1e93514ceef085bdee937557f2a61e2e6aaf6.tar.gz
nixlib-c4f1e93514ceef085bdee937557f2a61e2e6aaf6.tar.bz2
nixlib-c4f1e93514ceef085bdee937557f2a61e2e6aaf6.tar.lz
nixlib-c4f1e93514ceef085bdee937557f2a61e2e6aaf6.tar.xz
nixlib-c4f1e93514ceef085bdee937557f2a61e2e6aaf6.tar.zst
nixlib-c4f1e93514ceef085bdee937557f2a61e2e6aaf6.zip
Merge pull request #78264 from brainrape/init-fluxus
fluxus: init at 0.19
Diffstat (limited to 'pkgs/applications/graphics')
-rw-r--r--pkgs/applications/graphics/fluxus/default.nix96
-rw-r--r--pkgs/applications/graphics/fluxus/fix-build.patch16
2 files changed, 112 insertions, 0 deletions
diff --git a/pkgs/applications/graphics/fluxus/default.nix b/pkgs/applications/graphics/fluxus/default.nix
new file mode 100644
index 000000000000..a80940711013
--- /dev/null
+++ b/pkgs/applications/graphics/fluxus/default.nix
@@ -0,0 +1,96 @@
+{ stdenv
+, fetchFromGitLab
+, alsaLib
+, bzip2
+, fftw
+, freeglut
+, freetype
+, glew
+, libjack2
+, libGL
+, libGLU
+, libjpeg
+, liblo
+, libpng
+, libsndfile
+, libtiff
+, ode
+, openal
+, openssl
+, racket
+, scons
+, zlib
+}:
+let
+  libs = [
+    alsaLib
+    bzip2
+    fftw
+    freeglut
+    freetype
+    glew
+    libjack2
+    libGL
+    libGLU
+    libjpeg
+    liblo
+    libpng
+    libsndfile
+    libtiff
+    ode
+    openal
+    openssl
+    zlib
+  ];
+in
+stdenv.mkDerivation rec {
+  pname = "fluxus";
+  version = "0.19";
+  src = fetchFromGitLab {
+    owner = "nebogeo";
+    repo = "fluxus";
+    rev = "ba9aee218dd4a9cfab914ad78bdb6d59e9a37400";
+    hash = "sha256:0mwghpgq4n1khwlmgscirhmcdhi6x00c08q4idi2zcqz961bbs28";
+  };
+
+  buildInputs = [
+    alsaLib
+    fftw
+    freeglut.dev
+    freetype
+    glew
+    libjack2
+    libjpeg.dev
+    liblo
+    libsndfile.dev
+    libtiff.dev
+    ode
+    openal
+    openssl.dev
+    racket
+  ];
+  nativeBuildInputs = [ scons ];
+
+  patches = [ ./fix-build.patch ];
+  sconsFlags = [
+    "RacketPrefix=${racket}"
+    "RacketInclude=${racket}/include/racket"
+    "RacketLib=${racket}/lib/racket"
+    "LIBPATH=${stdenv.lib.makeLibraryPath libs}"
+    "DESTDIR=build"
+  ];
+  configurePhase = ''
+    sconsFlags+=" Prefix=$out"
+  '';
+  installPhase = ''
+    mkdir -p $out
+    cp -r build$out/* $out/
+  '';
+
+  meta = with stdenv.lib; {
+    description = "Livecoding environment for 3D graphics, sound, and games";
+    license = licenses.gpl2;
+    homepage = http://www.pawfal.org/fluxus/;
+    maintainers = [ maintainers.brainrape ];
+  };
+}
diff --git a/pkgs/applications/graphics/fluxus/fix-build.patch b/pkgs/applications/graphics/fluxus/fix-build.patch
new file mode 100644
index 000000000000..7810dd59e357
--- /dev/null
+++ b/pkgs/applications/graphics/fluxus/fix-build.patch
@@ -0,0 +1,16 @@
+diff --git a/SConstruct b/SConstruct
+index 32cb644..0b3a208 100644
+--- a/SConstruct
++++ b/SConstruct
+@@ -225,6 +225,11 @@ if env['PLATFORM'] == 'posix':
+                     ["asound", "alsa/asoundlib.h"],
+                     ["openal", "AL/al.h"]]
+
++env.Append(ENV={'PATH': ' ' + os.environ['PATH'], })
++env.Append(LIBPATH=ARGUMENTS.get('LIBPATH', '').split(':'))
++env.Append(CCFLAGS=' ' + os.environ.get('NIX_CFLAGS_COMPILE',''))
++env.Append(CCFLAGS=' -DNULL=0')
++
+ ################################################################################
+ # Make sure we have these libraries availible
+