This is an SCons tool for compiling FAUST programs. It adds various builders to
your construction environment: Faust
, FaustXML
, FaustSVG
, FaustSC
, and
FaustHaskell
. Their behaviour can be modified by changing various
construction variables (see "Usage" below).
This tool is based on a FAUST tool I found here, but has been heavily modified to behave more nicely and to also work with FAUST2 (e.g., don’t force architecture files to end with ".cpp").
The SCons FAUST tool depends on the obvious:
-
Python (2.5 or newer)
-
SCons
-
FAUST (along with all the dependencies of architecture files you use)
If your project uses git, you might consider adding this repository as a git
submodule in the site_scons/site_tools
directory in faust
. Otherwise, you
can copy the repository into your projects site_scons/site_tools
directory
into a subdirectory named faust
. Alternatively, you could clone the
repository into $HOME/.scons/site_scons/site_tools
, again, into a subdirectory
named faust
.
Use this as you would any other SCons tool: add it to the tools
argument of
Environment(), for example:
env = Environment(tools = ['default', 'faust'])
or manually add it using env.Tool()
.
To compile a FAUST DSP, you use the Faust()
builder:
dsp = env.Faust(['some_dsp.dsp'])
To manipulate the behaviour of the builders, you can specify the following construction variables (variables for internal use are not listed here):
Variable name | Function |
---|---|
|
The name of the |
|
The FAUST backend (e.g., "cpp"). |
|
The architecture file to compile with. |
|
Miscellaneous flags passed to |
|
The FAUST library search path. |
|
The name of the |
|
The class or module prefix (FaustSC) |
|
The class or module prefix (FaustHaskell). |
Furthermore, you can inspect the version of faust
and faust2sc
with the
construction variables FAUST_VERSION
and FAUST2SC_VERSION
.