Building DRC on Linux
From DRC
To use Denis Sbragion's DRC on linux, you need to download the source package and build it.
Unpack the source package to any convenient folder. You get a directory structure like this:
drc-2.6.2 ... /doc ... /sample ... /source (and various subdirectories).
Open a terminal window and cd drc-2.6.2/source.
Building with default settings
Building with the default settings is really easy: just type make.
Building and installing with double precision
But it's worth spending a little extra effort to enable double-precision math: this makes drc slower, but since you don't need to run drc very often, it's worth trading a little performance for the extra accuracy.
(Note: The author of DRC disagrees that double-precision will make a noticable difference, but Ed Wildgoose has experienced some compiler bugs which caused a slight overflow and harmonic distortion when using single precision, hence double precision is probably still preferred if speed is not an issue)
To build with double-precision, first set the makefile flag to enable it:
- open makefile with a text editor.
- Find the line beginning CFLAGS=...
- At the end of the line, add: -DUseDouble (that's a space, then one dash, then DUseDouble)
- Save makefile.
Then, instead of just 'make', we'll use the option to build drc and install it in its final destination. At the terminal prompt:
- sudo make install
or (if you don't have sudo), su root then make install.
The build only takes a few seconds, and finally installs all the components of drc into /usr/local/bin/ (the executables) and /usr/local/share/drc/ (the configuration files, targets, and so on). Now you can open a terminal prompt anywhere in the system and just type drc to run.
