tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
chuck: cleanup
Matthew Bauer
7 years ago
ee92ab07
030760a9
+15
-17
1 changed file
expand all
collapse all
unified
split
pkgs
applications
audio
chuck
default.nix
+15
-17
pkgs/applications/audio/chuck/default.nix
···
1
-
{ stdenv, fetchurl, alsaLib, bison, flex, libsndfile, which
2
, AppKit, Carbon, CoreAudio, CoreMIDI, CoreServices, Kernel
0
3
}:
4
5
stdenv.mkDerivation rec {
···
11
sha256 = "02z7sglax3j09grj5s1skmw8z6wz7b21hjrm95nrrdpwbxabh079";
12
};
13
14
-
buildInputs = [ bison flex libsndfile which ]
15
-
++ stdenv.lib.optional (!stdenv.isDarwin) alsaLib
16
-
++ stdenv.lib.optional stdenv.isDarwin [ AppKit Carbon CoreAudio CoreMIDI CoreServices Kernel ];
0
0
17
18
patches = [ ./clang.patch ./darwin-limits.patch ];
19
20
-
NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.isDarwin "-Wno-missing-sysroot";
21
-
NIX_LDFLAGS = stdenv.lib.optionalString stdenv.isDarwin "-framework MultitouchSupport";
22
23
postPatch = ''
24
substituteInPlace src/makefile --replace "/usr/bin" "$out/bin"
25
-
substituteInPlace src/makefile.osx --replace "xcodebuild" "/usr/bin/xcodebuild"
26
-
substituteInPlace src/makefile.osx --replace "weak_framework" "framework"
27
-
substituteInPlace src/makefile.osx --replace "MACOSX_DEPLOYMENT_TARGET=10.5" "MACOSX_DEPLOYMENT_TARGET=$MACOSX_DEPLOYMENT_TARGET"
28
-
'';
29
-
30
-
buildPhase = ''
31
-
make -C src ${if stdenv.isDarwin then "osx" else "linux-alsa"}
32
'';
33
34
-
installPhase = ''
35
-
install -Dm755 ./src/chuck $out/bin/chuck
36
-
'';
37
38
-
meta = with stdenv.lib; {
39
description = "Programming language for real-time sound synthesis and music creation";
40
homepage = http://chuck.cs.princeton.edu;
41
license = licenses.gpl2;
···
1
+
{ stdenv, lib, fetchurl, alsaLib, bison, flex, libsndfile, which
2
, AppKit, Carbon, CoreAudio, CoreMIDI, CoreServices, Kernel
3
+
, xcbuild
4
}:
5
6
stdenv.mkDerivation rec {
···
12
sha256 = "02z7sglax3j09grj5s1skmw8z6wz7b21hjrm95nrrdpwbxabh079";
13
};
14
15
+
nativeBuildInputs = [ flex bison which ];
16
+
17
+
buildInputs = [ libsndfile ]
18
+
++ lib.optional (!stdenv.isDarwin) alsaLib
19
+
++ lib.optional stdenv.isDarwin [ AppKit Carbon CoreAudio CoreMIDI CoreServices Kernel ];
20
21
patches = [ ./clang.patch ./darwin-limits.patch ];
22
23
+
NIX_CFLAGS_COMPILE = lib.optional stdenv.isDarwin "-Wno-missing-sysroot";
24
+
NIX_LDFLAGS = lib.optional stdenv.isDarwin "-framework MultitouchSupport";
25
26
postPatch = ''
27
substituteInPlace src/makefile --replace "/usr/bin" "$out/bin"
28
+
substituteInPlace src/makefile.osx \
29
+
--replace "weak_framework" "framework" \
30
+
--replace "MACOSX_DEPLOYMENT_TARGET=10.5" "MACOSX_DEPLOYMENT_TARGET=$MACOSX_DEPLOYMENT_TARGET"
0
0
0
0
31
'';
32
33
+
makeFlags = [ "-C src" "DESTDIR=$(out)/bin" ];
34
+
buildFlags = [ (if stdenv.isDarwin then "osx" else "linux-alsa") ];
0
35
36
+
meta = with lib; {
37
description = "Programming language for real-time sound synthesis and music creation";
38
homepage = http://chuck.cs.princeton.edu;
39
license = licenses.gpl2;