Download & building of the radiospec package

Quick-start for V1.0

Assuming dependencies, etc are all OK on your computer, the following script should be all you need to do. Note however that the radiospec is built in the “build” sub-directory of the directory you installed it to and is not installed – this is because you must modify at least some of the scripts to derive any new results with it.

# Destination directory, obviously adjust 
export INSTALLDIR=/home/bnikolic/temp/rsbuildtest

# Install BNMin1 
tar xjvf bnmin1-1.11.tar.bz2
cd bnmin1-1.11
LD_LIBRARY_PATH=$INSTALLDIR/lib PATH=$INSTALLDIR/bin:$PATH ./configure --prefix=$INSTALLDIR  --with-boost=/home/bn204/d/p/boost_1_35_0bin 
make && make install && cd ..

# Get PyHLP
tar xvzf pyhlp-0.2.tar.gz
cd pyhlp-0.2
python install --home=$INSTALLDIR
cd ..

# Build radiospec
tar --strip-components=1  -xzvf radiospec-1.0.tar.gz

You should then start python as:


Doesn’t work? Consult below for possible answers.


You will need a reasonably complete system with C++ development tools installed. Some of the dependencies at the time of writing are:

  • GCC/g++ and friends
  • Boost C++ libraries
  • GSL
  • Python 2.5 or 2.6 (including the development headers) (note Python 3.0 is not compatible with 2.x)
    • You will at least also need the numpy package for Python
  • SWIG – this generates the bindings to Python
  • PyX – this is the graphing library
  • PyHLP: Python routines for plotting built on PyX
  • SCons (version 1.2 or later)

FAQ & Answers

Problems installing BNMin1?

See also the BNMin1 page.

Problem installing GSL/BOOST/SWIG/SCons?

Here is a quick script that will install all of these to a location specified by you (but note this will involve a large amount of data download and will be processor intensive):

# Destination directory, obviously adjust 
export INSTALLDIR=/home/bnikolic/temp/rsbuildtest

# First install GSL
tar xzvf gsl-1.13.tar.gz
cd gsl-1.13
./configure --prefix=$INSTALLDIR
make && make install && cd ..

# Install swig. 
wget ""
tar xzvf swig-1.3.40.tar.gz
cd swig-1.3.40
./configure --prefix=$INSTALLDIR
make && make install && cd ..

# Install SCons
wget ""
tar xzvf scons-1.2.0.tar.gz
cd scons-1.2.0
python install --home=$INSTALLDIR
cd ..

# Install Boost
wget ""
tar xjvf "boost_1_41_0.tar.bz2"
cd boost_1_41_0/tools/jam/src/
cp bin.*/bjam ../../../
cd ../../../
./bjam --prefix=$INSTALLDIR install
cd ..

# Install NumPy
(wget "" &&
tar xzvf numpy-1.4.1.tar.gz  &&
cd numpy-1.4.1 &&
python install --home=$INSTALLDIR &&
cd ..

# Install Scipy
(wget "" &&
tar xzvf scipy-0.8.0.tar.gz &&
cd scipy-0.8.0 &&
PYTHONPATH=${INSTALLDIR}/lib64/python:$PYTHONPATH python install --home=$INSTALLDIR)

#install hdf5
(wget &&
tar xzvf hdf5-1.8.5-patch1.tar.gz &&
cd hdf5-1.8.5-patch1 &&
./configure --prefix=$INSTALLDIR &&
make install &&
cd ..)

#install Cython
(wget &&
 tar xzvf Cython-0.13.tar.gz &&
 cd Cython-0.13 &&
 PYTHONPATH=${INSTALLDIR}/lib64/python:$PYTHONPATH python install --home=$INSTALLDIR && 
 cd ..)

#install pytables
( wget
  tar xzvf tables-2.2.1.tar.gz &&
  cd tables-2.2.1 &&
  PYTHONPATH=${INSTALLDIR}/lib64/python:$PYTHONPATH python install --home=$INSTALLDIR --hdf5=$INSTALLDIR &&
  cd ..)

( wget &&
  tar xzvf numexpr-1.4.1.tar.gz &&
  cd numexpr-1.4.1 &&
  cd ..)

# Building bnmin1 -- See also other scipts
PKG_CONFIG_PATH=${INSTALLDIR}/lib/pkgconfig  \
./configure --prefix=${INSTALLDIR} --with-boost=${INSTALLDIR}

# PyX
(wget ""
tar xzvf PyX-0.10.tar.gz
cd PyX-0.10
PYTHONPATH=${INSTALLDIR}/lib64/python:$PYTHONPATH python install --home=$INSTALLDIR && 

Important note regarding boost: If you installed boost using this script you must specify its location to BNMin1 by changing the following lines in the simple installation script from:

cd bnmin1-1.9

to the following:

cd bnmin1-1.9

This is because the boost installation is not detected by a program in path but rather using a more complicated algorithm.

SCons version problem

If you have problem running the build script with an output similar to:

scons: Reading SConscript files ...
NameError: name 'Variables' is not defined:
  File "/tmp/SConstruct", line 8:
Exit 2

then the most likely reason is that your version of SCons is too old. You need to use version 1.2 or newer.