Документ взят из кэша поисковой машины. Адрес оригинального документа : http://www.mrao.cam.ac.uk/~bn204/alma/sweng/libairbuild.html
Дата изменения: Mon Apr 4 13:47:51 2016
Дата индексирования: Sun Apr 10 09:47:56 2016
Кодировка: ISO8859-5

Поисковые слова: cepheid
Building libAIR — Bojan Nikolic web pages (r. 329)

Building libAIRТЖ

Quick-start for V0.18ТЖ

Note

These simplest instructions do not bind against CASA and therefore do not build the wvrgcal program. (I.e., the –disable-casawvr option is used to turn-off building against CASA). If you want wvrgcal look at the next subsection

Assuming dependencies, etc are all OK on your computer, this is all you should need to do:

# Obviously change this to approriate directory for your computer
export INSTALLDIR=/home/bnikolic/temp/libairtest

export BNMINVER=bnmin1-1.11
export LIBAIRVER=libair-0.18

# Install BNMin1 
wget http://www.mrao.cam.ac.uk/~bn204/soft/${BNMINVER}.tar.bz2
tar xjvf ${BNMINVER}.tar.bz2
cd ${BNMINVER}
LD_LIBRARY_PATH=$INSTALLDIR/lib:$PREREQPATH/lib \
PATH=$INSTALLDIR/bin:$PREREQPATH/bin:$PATH \
./configure --disable-pybind --prefix=$INSTALLDIR --with-boost=$PREREQPATH
make && make install && cd ..


# Install libAIR
wget -nc http://www.mrao.cam.ac.uk/~bn204/soft/${LIBAIRVER}.tar.bz2
tar xjvf ${LIBAIRVER}.tar.bz2
cd ${LIBAIRVER}
PKG_CONFIG_PATH=$INSTALLDIR/lib/pkgconfig:$PREREQPATH/lib/pkgconfig \
./configure --prefix=$INSTALLDIR --with-boost=$PREREQPATH --disable-pybind
make && make install && cd ..

Doesn’t work? Consult below for answers

Quick-start for ALMAТЖ

I have installed libAIR on the sco-red and osf-red computers at ALMA. Here are the notes on how to do that.

# First, if suitable versions are not present, we need to install GSL
# and Boost. This takes a while but is entirely automated.  Please
# look at the page:
# http://www.mrao.cam.ac.uk/~bn204/galevol/speca/build.html#dependencies

# Install CASA if needed: (see http://casa.nrao.edu/casa_obtaining.shtml for version info)
wget -c https://svn.cv.nrao.edu/casa/linux_distro/stable/casapy-stable-31.0.13362-001-64b.tar.gz
tar xzvf casapy-stable-31.0.13362-001-64b.tar.gz

export CASAPATH=/users/bnikolic/p/bnmain/casapy-stable-31.0.13362-001-64b/

# This is where all the pre-requists go
export PREREQPATH=/users/bnikolic/p/prereqs

# Except boost which is now separate
export BOOSTPATH=/users/bnikolic/p/prereqs

# Setup the installation directory -- all pre-requisites and the
# package itself will go there.



export BNMINVER=bnmin1-1.11
export LIBAIRVERNO=1.0
export LIBAIRVER=libair-${LIBAIRVERNO}

export INSTALLDIR=/users/bnikolic/p/wvr-${LIBAIRVERNO}

# Next up the actual software used by WVRGCAL

cd /users/bnikolic/p
mkdir $INSTALLDIR-src
cd $INSTALLDIR-src

# Install BNMin1 
wget http://www.mrao.cam.ac.uk/~bn204/soft/${BNMINVER}.tar.bz2
tar xjvf ${BNMINVER}.tar.bz2
(cd ${BNMINVER} &&
 LD_LIBRARY_PATH=$INSTALLDIR/lib:$PREREQPATH/lib \
 PATH=$INSTALLDIR/bin:$PREREQPATH/bin:$PATH \
 ./configure --disable-pybind --prefix=$INSTALLDIR --with-boost=$BOOSTPATH &&
 make && make install && cd ..)


# Install libAIR

wget -nc http://www.mrao.cam.ac.uk/~bn204/soft/${LIBAIRVER}.tar.bz2
tar xjvf ${LIBAIRVER}.tar.bz2
(cd ${LIBAIRVER} &&
 PKG_CONFIG_PATH=$INSTALLDIR/lib/pkgconfig:$PREREQPATH/lib/pkgconfig \
 ./configure --prefix=$INSTALLDIR --with-boost=$BOOSTPATH --disable-pybind --with-casa=$CASAPATH \
 --with-hdf5=$PREREQPATH &&
 make && make install && cd ..)

(rm /users/bnikolic/p/wvr-latest; ln -s $INSTALLDIR /users/bnikolic/p/wvr-latest)

More detailed notesТЖ

DependenciesТЖ

libAIR currently has only one dependency, BNMin1 which a minimisation/inference library.

BNMin1ТЖ

Please see the page BNMin1 for general information about BNMin1, where to download it and how to build it.

With the current configuration of the appcd computer in Cambridge, there are two depenencies of BNMin1 which are not satisfied:

  • GSL – no version is installed
  • SWIG – installed version is too old

The script below shows how to build these dependencies and BNMin1 itself:

# Destination directory -- you can place all components into a single
# tree OR separate them if you wish. In this example everything goes
# into $INSTALLDIR.
export INSTALLDIR=/users/bnikolic/p/bnmain

# First install GSL -- obviously this is only necessary if a
# reasonably recent version of GSL is not already available on the
# system
wget http://www.mirrorservice.org/sites/ftp.gnu.org/gnu/gsl/gsl-1.13.tar.gz
tar xzvf gsl-1.13.tar.gz
cd gsl-1.13
./configure --prefix=$INSTALLDIR
make && make install && cd ..

# Install swig. 
wget "http://downloads.sourceforge.net/project/swig/swig/swig-1.3.40/swig-1.3.40.tar.gz?use_mirror=kent"
tar xzvf swig-1.3.40.tar.gz
cd swig-1.3.40
./configure --prefix=$INSTALLDIR
make && make install && cd ..

# Install BNMin1 proper
wget http://www.mrao.cam.ac.uk/~bn204/soft/bnmin1-1.10.tar.bz2
tar xjvf bnmin1-1.10.tar.bz2
cd bnmin1-1.10
LD_LIBRARY_PATH=$INSTALLDIR/lib PATH=$INSTALLDIR/bin:$PATH ./configure --prefix=$INSTALLDIR
make && make install && cd ..

libAIRТЖ

Maintainer buildТЖ

This is what you need to do if you access the source code repository directly rather than downloading a tar-ball.

The command to get the source code using bzr is:

bzr branch sftp://appcs/home/bn204/public_bzr/libair

The sequence of commands to do the actual build of the main library is:

export INSTALLDIR=/home/bnikolic/d/p/bnmain

# Only needed after making a fresh checkout from the source code
# repository
autoreconf -i
# Only needed after big changes to the makefiles, or on first checkout
LD_LIBRARY_PATH=$INSTALLDIR/lib PATH=$INSTALLDIR/bin:$PATH \
PKG_CONFIG_PATH=$INSTALLDIR/lib/pkgconfig \
./configure --prefix=$INSTALLDIR
make 

Accessing MS & MSDumpТЖ

LibAIR has an experimental program to access the measurement set, extract information relevant for testing of phase correction and save it a file in HDF5 format. The propose of this program is to avoid CASA as a dependency in the normal development cycle of phase correction algorithms.

The program named “msdump” and is located in the casawvr/test directory. It is not built by default. Instead, it is separately with using the ‘’scons’’ system (scons also being used to make casa-core and hopefully casa...).

The invoication to build the msdump program is:

scons CASACOREROOT=/home/bnikolic/d/p/cs

where CASACOREROOT is set to whatever the directory tree root is where casa core and supporting libraries were installed.