tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
Remove faust.
Patrick Mahoney
11 years ago
7f5dd21b
7811c409
-215
3 changed files
expand all
collapse all
unified
split
pkgs
applications
audio
faust
default.nix
faust-compiler
default.nix
top-level
all-packages.nix
-110
pkgs/applications/audio/faust-compiler/default.nix
···
1
1
-
{ fetchgit, stdenv, unzip, pkgconfig, makeWrapper, libsndfile, libmicrohttpd, vim }:
2
2
-
3
3
-
stdenv.mkDerivation rec {
4
4
-
5
5
-
version = "8-1-2015";
6
6
-
name = "faust-compiler-${version}";
7
7
-
src = fetchgit {
8
8
-
url = git://git.code.sf.net/p/faudiostream/code;
9
9
-
rev = "4db76fdc02b6aec8d15a5af77fcd5283abe963ce";
10
10
-
sha256 = "f1ac92092ee173e4bcf6b2cb1ac385a7c390fb362a578a403b2b6edd5dc7d5d0";
11
11
-
};
12
12
-
13
13
-
# this version has a bug that manifests when doing faust2jack:
14
14
-
/*version = "0.9.67";*/
15
15
-
/*name = "faust-compiler-${version}";*/
16
16
-
/*src = fetchurl {*/
17
17
-
/*url = "http://downloads.sourceforge.net/project/faudiostream/faust-${version}.zip";*/
18
18
-
/*sha256 = "068vl9536zn0j4pknwfcchzi90rx5pk64wbcbd67z32w0csx8xm1";*/
19
19
-
/*};*/
20
20
-
21
21
-
buildInputs = [ unzip pkgconfig makeWrapper libsndfile libmicrohttpd vim];
22
22
-
23
23
-
24
24
-
makeFlags="PREFIX = $(out)";
25
25
-
FPATH="$out"; # <- where to search
26
26
-
27
27
-
patchPhase = ''
28
28
-
sed -i 's@?= $(shell uname -s)@:= Linux@g' architecture/osclib/oscpack/Makefile
29
29
-
sed -i 's@faust/misc.h@../../architecture/faust/misc.h@g' tools/sound2faust/sound2faust.cpp
30
30
-
sed -i 's@faust/gui/@../../architecture/faust/gui/@g' architecture/faust/misc.h
31
31
-
'';
32
32
-
33
33
-
buildPhase = ''
34
34
-
make -C compiler -f Makefile.unix
35
35
-
make -C architecture/osclib
36
36
-
g++ -O3 tools/sound2faust/sound2faust.cpp `pkg-config --cflags --static --libs sndfile` -o tools/sound2faust/sound2faust
37
37
-
make httpd
38
38
-
39
39
-
'';
40
40
-
41
41
-
installPhase = ''
42
42
-
43
43
-
echo install faust itself
44
44
-
mkdir -p $out/bin/
45
45
-
mkdir -p $out/include/
46
46
-
mkdir -p $out/include/faust/
47
47
-
mkdir -p $out/include/faust/osc/
48
48
-
install compiler/faust $out/bin/
49
49
-
50
50
-
echo install architecture and faust library files
51
51
-
mkdir -p $out/lib/faust
52
52
-
cp architecture/*.lib $out/lib/faust/
53
53
-
cp architecture/*.cpp $out/lib/faust/
54
54
-
55
55
-
echo install math documentation files
56
56
-
cp architecture/mathdoctexts-*.txt $out/lib/faust/
57
57
-
cp architecture/latexheader.tex $out/lib/faust/
58
58
-
59
59
-
echo install additional binary libraries: osc, http
60
60
-
([ -e architecture/httpdlib/libHTTPDFaust.a ] && cp architecture/httpdlib/libHTTPDFaust.a $out/lib/faust/) || echo libHTTPDFaust not available
61
61
-
cp architecture/osclib/*.a $out/lib/faust/
62
62
-
cp -r architecture/httpdlib/html/js $out/lib/faust/js
63
63
-
([ -e architecture/httpdlib/src/hexa/stylesheet ] && cp architecture/httpdlib/src/hexa/stylesheet $out/lib/faust/js/stylesheet.js) || echo stylesheet not available
64
64
-
([ -e architecture/httpdlib/src/hexa/jsscripts ] && cp architecture/httpdlib/src/hexa/jsscripts $out/lib/faust/js/jsscripts.js) || echo jsscripts not available
65
65
-
66
66
-
echo install includes files for architectures
67
67
-
cp -r architecture/faust $out/include/
68
68
-
69
69
-
echo install additional includes files for binary libraries: osc, http
70
70
-
cp architecture/osclib/faust/faust/OSCControler.h $out/include/faust/gui/
71
71
-
cp architecture/osclib/faust/faust/osc/*.h $out/include/faust/osc/
72
72
-
cp architecture/httpdlib/src/include/*.h $out/include/faust/gui/
73
73
-
74
74
-
75
75
-
echo patch header and cpp files
76
76
-
find $out/include/ -name "*.h" -type f | xargs sed "s@#include \"faust/@#include \"$out/include/faust/@g" -i
77
77
-
find $out/lib/faust/ -name "*.cpp" -type f | xargs sed "s@#include \"faust/@#include \"$out/include/faust/@g" -i
78
78
-
sed -i "s@../../architecture/faust/gui/@$out/include/faust/gui/@g" $out/include/faust/misc.h
79
79
-
80
80
-
wrapProgram $out/bin/faust \
81
81
-
--set FAUSTLIB $out/lib/faust \
82
82
-
--set FAUST_LIB_PATH $out/lib/faust \
83
83
-
--set FAUSTINC $out/include/
84
84
-
'';
85
85
-
86
86
-
meta = with stdenv.lib; {
87
87
-
description = "A functional programming language for realtime audio signal processing";
88
88
-
longDescription = ''
89
89
-
FAUST (Functional Audio Stream) is a functional programming
90
90
-
language specifically designed for real-time signal processing
91
91
-
and synthesis. FAUST targets high-performance signal processing
92
92
-
applications and audio plug-ins for a variety of platforms and
93
93
-
standards.
94
94
-
The Faust compiler translates DSP specifications into very
95
95
-
efficient C++ code. Thanks to the notion of architecture,
96
96
-
FAUST programs can be easily deployed on a large variety of
97
97
-
audio platforms and plugin formats (jack, alsa, ladspa, maxmsp,
98
98
-
puredata, csound, supercollider, pure, vst, coreaudio) without
99
99
-
any change to the FAUST code.
100
100
-
This package has just the compiler. Install faust for the full
101
101
-
set of faust2somethingElse tools.
102
102
-
'';
103
103
-
homepage = http://faust.grame.fr/;
104
104
-
downloadPage = http://sourceforge.net/projects/faudiostream/files/;
105
105
-
license = licenses.gpl2;
106
106
-
platforms = platforms.linux;
107
107
-
maintainers = [ maintainers.magnetophon ];
108
108
-
};
109
109
-
}
110
110
-
-100
pkgs/applications/audio/faust/default.nix
···
1
1
-
{ fetchgit, stdenv, bash, alsaLib, atk, cairo, faust-compiler, fontconfig, freetype
2
2
-
, gcc, gdk_pixbuf, glib, gtk, jack2, makeWrapper, opencv, pango, pkgconfig, unzip
3
3
-
, gtkSupport ? true
4
4
-
, jackaudioSupport ? true
5
5
-
}:
6
6
-
7
7
-
stdenv.mkDerivation rec {
8
8
-
9
9
-
version = "8-1-2015";
10
10
-
name = "faust-${version}";
11
11
-
src = fetchgit {
12
12
-
url = git://git.code.sf.net/p/faudiostream/code;
13
13
-
rev = "4db76fdc02b6aec8d15a5af77fcd5283abe963ce";
14
14
-
sha256 = "f1ac92092ee173e4bcf6b2cb1ac385a7c390fb362a578a403b2b6edd5dc7d5d0";
15
15
-
};
16
16
-
17
17
-
# this version has a bug that manifests when doing faust2jack:
18
18
-
/*version = "0.9.67";*/
19
19
-
/*name = "faust-${version}";*/
20
20
-
/*src = fetchurl {*/
21
21
-
/*url = "http://downloads.sourceforge.net/project/faudiostream/faust-${version}.zip";*/
22
22
-
/*sha256 = "068vl9536zn0j4pknwfcchzi90rx5pk64wbcbd67z32w0csx8xm1";*/
23
23
-
/*};*/
24
24
-
25
25
-
buildInputs = [ bash unzip faust-compiler gcc makeWrapper pkgconfig ]
26
26
-
++ stdenv.lib.optionals gtkSupport [
27
27
-
alsaLib atk cairo fontconfig freetype gdk_pixbuf glib gtk pango
28
28
-
]
29
29
-
++ stdenv.lib.optional jackaudioSupport jack2
30
30
-
;
31
31
-
32
32
-
makeFlags="PREFIX=$(out)";
33
33
-
FPATH="$out"; # <- where to search
34
34
-
35
35
-
phases = [ "unpackPhase installPhase postInstall" ];
36
36
-
37
37
-
installPhase = ''
38
38
-
sed -i 23,24d tools/faust2appls/faust2jack
39
39
-
mkdir $out/bin
40
40
-
install tools/faust2appls/faust2alsaconsole $out/bin
41
41
-
install tools/faust2appls/faustpath $out/bin
42
42
-
install tools/faust2appls/faustoptflags $out/bin
43
43
-
install tools/faust2appls/faust2alsa $out/bin
44
44
-
install tools/faust2appls/faust2jack $out/bin
45
45
-
46
46
-
patchShebangs $out/bin
47
47
-
48
48
-
wrapProgram $out/bin/faust2alsaconsole \
49
49
-
--prefix PKG_CONFIG_PATH : ${alsaLib}/lib/pkgconfig \
50
50
-
--set FAUSTLIB ${faust-compiler}/lib/faust \
51
51
-
--set FAUSTINC ${faust-compiler}/include/
52
52
-
53
53
-
GTK_PKGCONFIG_PATHS=${gtk}/lib/pkgconfig:${pango}/lib/pkgconfig:${glib}/lib/pkgconfig:${cairo}/lib/pkgconfig:${gdk_pixbuf}/lib/pkgconfig:${atk}/lib/pkgconfig:${freetype}/lib/pkgconfig:${fontconfig}/lib/pkgconfig
54
54
-
55
55
-
wrapProgram $out/bin/faust2alsa \
56
56
-
--prefix PKG_CONFIG_PATH : ${alsaLib}/lib/pkgconfig:$GTK_PKGCONFIG_PATHS \
57
57
-
--set FAUSTLIB ${faust-compiler}/lib/faust \
58
58
-
--set FAUSTINC ${faust-compiler}/include/ \
59
59
-
60
60
-
61
61
-
wrapProgram $out/bin/faust2jack \
62
62
-
--prefix PKG_CONFIG_PATH : ${jack2}/lib/pkgconfig:${opencv}/lib/pkgconfig:$GTK_PKGCONFIG_PATHS \
63
63
-
--set FAUSTLIB ${faust-compiler}/lib/faust \
64
64
-
--set FAUSTINC ${faust-compiler}/include/ \
65
65
-
66
66
-
''
67
67
-
+ stdenv.lib.optionalString (!gtkSupport) "rm $out/bin/faust2alsa"
68
68
-
+ stdenv.lib.optionalString (!gtkSupport || !jackaudioSupport) "rm $out/bin/faust2jack"
69
69
-
;
70
70
-
postInstall = ''
71
71
-
sed -e "s@\$FAUST_INSTALL /usr/local /usr /opt /opt/local@${faust-compiler}@g" -i $out/bin/faustpath
72
72
-
sed -i "s@/bin/bash@${bash}/bin/bash@g" $out/bin/faustoptflags
73
73
-
find $out/bin/ -name "*faust2*" -type f | xargs sed "s@pkg-config@${pkgconfig}/bin/pkg-config@g" -i
74
74
-
find $out/bin/ -name "*faust2*" -type f | xargs sed "s@CXX=g++@CXX=${gcc}/bin/g++@g" -i
75
75
-
find $out/bin/ -name "*faust2*" -type f | xargs sed "s@faust -i -a @${faust-compiler}/bin/faust -i -a ${faust-compiler}/lib/faust/@g" -i
76
76
-
'';
77
77
-
78
78
-
meta = with stdenv.lib; {
79
79
-
description = "A functional programming language for realtime audio signal processing";
80
80
-
longDescription = ''
81
81
-
FAUST (Functional Audio Stream) is a functional programming
82
82
-
language specifically designed for real-time signal processing
83
83
-
and synthesis. FAUST targets high-performance signal processing
84
84
-
applications and audio plug-ins for a variety of platforms and
85
85
-
standards.
86
86
-
The Faust compiler translates DSP specifications into very
87
87
-
efficient C++ code. Thanks to the notion of architecture,
88
88
-
FAUST programs can be easily deployed on a large variety of
89
89
-
audio platforms and plugin formats (jack, alsa, ladspa, maxmsp,
90
90
-
puredata, csound, supercollider, pure, vst, coreaudio) without
91
91
-
any change to the FAUST code.
92
92
-
'';
93
93
-
homepage = http://faust.grame.fr/;
94
94
-
downloadPage = http://sourceforge.net/projects/faudiostream/files/;
95
95
-
license = licenses.gpl2;
96
96
-
platforms = platforms.linux;
97
97
-
maintainers = [ maintainers.magnetophon ];
98
98
-
};
99
99
-
}
100
100
-
-5
pkgs/top-level/all-packages.nix
···
13516
13516
13517
13517
fakenes = callPackage ../misc/emulators/fakenes { };
13518
13518
13519
13519
-
13520
13520
-
faust = callPackage ../applications/audio/faust { };
13521
13521
-
13522
13522
-
faust-compiler = callPackage ../applications/audio/faust-compiler { };
13523
13523
-
13524
13519
fceux = callPackage ../misc/emulators/fceux { };
13525
13520
13526
13521
foldingathome = callPackage ../misc/foldingathome { };