« FTP automatically | Main | Spectrophotometric Standards »

Casacore installation on Ubuntu

Here are some steps to install casacore on Ubuntu (specifically 10.04 LTS ran as a virtual machine with VirtualBox on Ubuntu 11.10). This posting uses provided packages where possible and avoids, if necessary the installation of packages from source. This is mostly meant as a reference for myself and hence includes a few things that I had to specifically do and probably won't work for anyone else, I hope it does, but we all know what computers are like! Of course, you should go and see the latest on the [google code casacore] page. This is using casacore version 1.3.0.

wget casacore (see link above) and unpack.

sudo apt-get install build-essential

sudo apt-get install scons fort77 subversion g++ cmake libblas-dev liblapack-dev libqdbm-dev libfftw3-dev libcfitsio3-dev libboost-python-dev slang-cfitsio flex bison gfortran libhdf5-serial-dev libreadline5-dev python-scipy python-matplotlib python-pyfits

Download wcslib - and run make, make install

wget ftp://ftp.atnf.csiro.au/pub/software/wcslib/wcslib.tar.bz2
tar -xf wcslib.tar.bz2
cd wcslib-4.8.2
./configure --prefix=/usr/local/include/wcslib/
make && make install && cd ..

When compiling casacore I had a specific problem where a header file couldn't be found from wcslib, so quick fix;

sudo cp -r wcsconfig.h /usr/local/include/wcslib #from the wcslib dir

and that seemed to fix it.

Now install casacore with scons:

scons --prefix=/usr/local --enable-shared
sudo scons install

There are many different options available for the compilation - all the above does is make the shared libraries too... you should look into this but remember that the options.cache file needs to be removed if you do another make.

TrackBack

TrackBack URL for this entry:
http://krioma.net/cgi-bin/MT-3.38/mt-tb.cgi/570

Listed below are links to weblogs that reference Casacore installation on Ubuntu:

» Creating FITS files in c++ from Krioma.net Blog
A simple example, very similar to that given in the CFITSIO guidebook, on how to create a FITS file using CFITSIO. In this case I'm also building against some casacore libraries, but these aren't going to be used in this... [Read More]

» Setting up a Virtual Webserver from Krioma.net Blog
This is a quick guide on how to setup a webserver in a virtual machine. This is based on using Virtualbox and Ubuntu, so it might not work with all version of linux and though the install instructions inside the... [Read More]

» Casacore installation: Addendum from Krioma.net Blog
So I was installing Casacore (as described here) on another machine and found I needed to do: sudo cp -r lib/libcasa_*.so /usr/lib sudo cp -r /usr/local/lib/libwcs*.so* /usr/lib/ To allow me to use some of the libraries. Bit odd but all... [Read More]

Comments (1)

krioma [TypeKey Profile Page]:

I recently had to reinstall this and thought it prudent to post a quick update based on this installation.

This time I did basically the same as above but with a few changes. Mostly due to some oddities with the installation of wcslib.

sudo apt-get install python-scipy python-matplotlib python-pyfits scons fort77 subversion g++ cmake libblas-dev liblapack-dev libqdbm-dev libfftw3-dev libcfitsio3-dev libboost-python1.42.0 slang-cfitsio flex bison gfortran libhdf5-serial-dev libreadline5-dev libboost-python-dev

#download wcslib

wget ftp://ftp.atnf.csiro.au/pub/software/wcslib/wcslib.tar.bz2
tar xfj wcslib.tar.bz2
cd wcslib-4.8.2 #this might vary.

#make it
make
make check
sudo make -n install
sudo ln -s /usr/local/include/wcslib-4.3 /usr/local/include/wcslib

#now more to the casacore directory
scons --enable-shared --disable-static

for me this failed to find one of the wcs headers, this was easily resolved by:

sudo cp -r wcslib-4.8.2/wcsconfig.h /usr/local/include/wcslib

#and try again:

scons --enable-shared --disable-static
sudo scons install

#all now worked.

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)

About

This page contains a single entry from the blog posted on November 1, 2011 3:02 PM.

The previous post in this blog was FTP automatically.

The next post in this blog is Spectrophotometric Standards.

Many more can be found on the main index page or by looking through the archives.

Get Firefox! Valid XHTML 1.0! Valid CSS! RSS Feed BlogUniverse - listed Powered by Apache Creative Commons License ringsofsaturnrock's Most Interesting Photos on Flickriver

Powered by
Movable Type 3.38