Links to official instructions for building AIPS++ are given below in (A) and (B).
(A) Basic instructions for a generic
clean installation can be found at the bottom of the ALMA offline twiki CVS use page.
(B) Instructions on how to setup CVS to create and maintain/update
an
External Developer's Release can be found in the
AIPS++ System Manual. The rpm versions listed there are a bit
outdated.
I have not strictly followed the official build instructions
and cannot guarantee that they are up to date or work as is. What
follows is a description of how I built a clean installation of AIPS++
on FC4
Building AIPS++ on Fedora Core 4
A step by step procedure of how to build a clean installation of AIPS++ for FC4 (based on instructions in A) is given below. cvsup (based on instructions in B) was used only to get the documentation and co-ordinate system data information.
Software Prerequisites
[CV] : ftp://ftp.cv.nrao.edu/casa/rpms/fedora/
[FC4 extras] : http://rpmfind.net/linux/RPM/fedora/4/i386/ByName.html
[RPMfind] : http://rpmfind.net/linux/RPM/ByName.html
- PgPlot
pgplot-5.2.2-4ds.i386.rpm - CV
pgplot-devel-5.2.2-4ds.i386.rpm - CV
pgplot-motif-5.2.2-4ds.i386.rpm - CV
- Tcl/Tk
FC4 installs tclx8.3 and tcl/tk8.4.
tcl-devel-8.4.9-3.i386.rpm - RPMfind
tk-devel-8.4.9-3.i386.rpm - RPMfind
Check (make) the following symbolic links
/usr/bin/tclsh -> /usr/bin/tclsh8.4
/usr/lib/libtcl.so -> /usr/lib/libtcl8.4.so
/usr/lib/libtclx.so -> /usr/lib/libtclx8.3.so
/usr/lib/libtk.so -> /usr/lib/libtk8.4.so
/usr/lib/libtkx.so -> /usr/lib/libtkx8.3.so
- X11 - FC4 installation
- LessTif/OpenMotif - openmotif - FC4 installation.
[lesstif-0.93.94-3.i386.rpm - RPMfind] - required only if openmotif is not available.
- Xpm - FC4 installation
- Lapack -
lapack-3.0-29 - FC4 extras
- Blas -
blas-3.0-29 - FC4 extras
- cfitsio
libg2c-3.4.3-4.i386.rpm - RPMfind
cfitsio-2.510-20ds.i386.rpm - CV
- rpfits -
rpfits-2.8-2ds.i386.rpm - CV
- fftw -
fftw3-3.0.1-3 - FC4 extras
- cvsup -
cvsup-16.1h-10ds.i386.rpm - CV
- gcc-3.4.3
From http://gcc.gnu.org
(ftp://mirrors.rcn.net/pub/sourceware/gcc/releases/gcc-3.4.3/),
Download file: gcc-3.4.3.tar.gz - includes c,c++,fortran77
Untar in /usr/local/share and follow instructions in /usr/local/share/gcc-3.4.3/INSTALL/index.html....
cd /usr/local/share/gcc-3.4.3/
./configure --enable-languages=c,c++,f77
gmake
gmake install (will go into /usr/local by default)
If you already have a version of gcc, then do not do "gmake bootstrap".
The --enable-languages option is required only if the 'ada' build complains.
This language support is not required to compile AIPS++.
- latex2html
latex2html-2002.2.1-3.noarch.rpm (FC4 for i386)
www.rpmfind.net/linux/RPM/fedora/4/i386/latex2html-2002.2.1-3.noarch.html
(may not be correct version for AIPS++)
Download AIPS++ Source
Make an AIPS++ root directory and 'inhale' all the code from the CV anonymous ftp site.
mkdir /usr/local/aips++
cd /usr/local/aips++
cvs -d :pserver:anonymous@cvs.cv.nrao.edu:/home/cvs -r checkout -d code casa/code
Configure AIPS++
-
Run the configure.cvs script. It will ask a few questions about the AIPS++ root directory
and desired names (xxx) for the current build.
cd code
chmod u+x install/configure.cvs
./install/configure.cvs
-
When asked to edit the /usr/local/aips++/linux_gnu/xxx/aipsrc , modify the printer defaults
for paper size and default printer name/command. To ignore, delete these two lines completely.
-
When asked to edit the /usr/local/aips++/linux_gnu/xxx/makedefs, first check the settings of
all variables in /usr/local/aips++/linux_gnu/makedefs.
Some root paths to packages may not be defined or may not point to
where the package actually is, on your system.
Any paths that need to be changed (or defined), need
to be defined in /usr/local/aips++/linux_gnu/xxx/makedefs.
Check ROOT/INCD/LIBD paths for various packages, and some compiler flags.
Please refer to this sample makedefs
file to modify your own. Please use exactly the same compiler flags.
(This installation was done with the CVS daily distribution of
17 Aug 2005. The root AIPS++ directory in this installation was /aips++).
-
When the settings in makedefs are verified, check all the output messages for packages
and libraries not found, set the correct paths in the makedefs file and reverify.
You can safely ignore most warnings about things not found under the /usr/local/aips++ tree,
as these libraries will be built later. All but the following
need to be set correctly.
GLISHxxx : nothing found - ignore - will be built later into AIPS++ tree.
WCSLIBLIB /usr/local/aips++/linux_gnu/lib/libwcs.so not found - ignore - will
be built later into AIPS++ tree
DVRROOT, DVRINCD, DVRLIBD, DVRLIB warnings.... ignore !
MIRLIBLIB - not found in /usr/local/aips++.... ignore.. will build
GSDLIBLIB - libgsd.* not found in /usr/local/aips++.... ignore.. will build
HDS* not found... ignore !
"aips must be last" ADVISORY/WARNING/SERIOUS -- ignore
PGMRPTRD - no directory.... ignore
AIPSMSTR, AIPSLAVE - no directory.... ignore
AIPSDOCS - no directory.... ignore for now - will deal with documentation later - that's another story..for another day....
CODEINCD - no directory - ignore - will appear later
LIBICOND - no directory - ignore - will appear later
BINTESTD - no directory - ignore - will appear later
AUXILIARY - warnings about auxiliary package - ignore.
Build glish
Glish does not get built automatically with 'sneeze', so has to be done by hand before
building the rest of the installation.
cd /usr/local/aips++/code/aips/glish
source /usr/local/aips++/aipsinit.sh
./configure
gmake allsys
Note : source /usr/local/aips++/aipsinit.$SHELL.
If there are problems with GlishTk not being rebuilt - or any such thing,
"gmake cleansys" followed by "rm /usr/local/aips++/linux_gnu/bin/glish* " and then
" touch force.rebuild " - will reset glish to be built from scratch.
After build completes (few minutes), glish will start - but will complain abt not finding .glishrc or .aips++init.g
-- that is okay - it'll appear after the rest of the installation is built.
Build AIPS++
Configure again and check that the GLISH vars find what they want now (since glish has been built)
cd /usr/local/aips++/code
./install/configure.cvs
And sneeze !!
source /usr/local/aips++/aipsinit.sh
sneeze -l -m cumulative &
tail -f /usr/local/aips++/linux_gnu/sneeze.log
It will begin with a 'cleansys' and will complain about directories not found. ignore.
Go away for a few hours (or sit back and watch some compiler warnings).
If you do go away, return once every hour to check for error messages...
There may be errors in some programs' builds - ignore as long as it is confined to just
that program.
If there are a very large number of 'undefined reference' or template related errors, recheck
the compiler flags. Check for header files and libraries not found.
If you stop the build before it completes (errors in makedefs resulting in files not found),
to prevent rebuilding everything from scratch, use sneeze -l -m incremental & . If however
you change compiler flags, you'll need to rebuild as cumulative after running
gmake cleansys. Make sure that all .o files are removed before starting the cumulative build.
This does not happen automatically (!!)
A few hours later, AIPS++ should be installed and working.
(I tested the sequence of instructions listed here by re-inhaling the
entire source tree, and starting from scratch by following these
instructions and it worked.)
To use AIPS++, initialize the environment variables with source /usr/local/aips++/aipsinit.sh
To do a preliminary check - start glish and
load the viewer with include 'viewer.g' followed by dv.gui() to check the
graphics display. If anything appears broken, go to that sub-system under /usr/local/aips++/code
and do gmake and try to debug from there.
Setup a .aipsrc file in your home area.
Build Documentation
Comment out the last two settings in the local makedefs..
#DOCSYS :=
#DOCEXTR :=
cd /usr/local/aips++/code
./install/configure.cvs
cd doc
source /usr/local/aips++/aipsinit.sh
gmake
Wish yourself good luck.
After several iterations of trying to build the documentation, I gave up and copied the document tree from the 'daily' installation and used that. I used cvsup as follows.
(Detailed CVS use instructions to get the entire distribution can be
found in the AIPS++ System Manual)
cd /usr/local/aips++
mkdir docs
mkdir -p sup/files
echo "*default host=aips2.nrao.edu compress
*default base=/usr/local/aips++
*default delete use-rel-suffix
docs release=daily" > sup/files/docs
cvsup sup/files/docs
Note : The host name is "aips2.nrao.edu". If this hostname is not resolved, use "host=146.88.10.7".
This will pull all documents into /usr/local/aips++/docs. The "/sup/files/docs" file can be generated automatically (along with code,data,etc..) by following the instructions in the documentation for an External Developer's Release to fetch the entire tree. The above script will setup and fetch only the "docs" directory.
Get Data files
This is required by AIPS++ for co-ordinate system information, etc..
cd /usr/local/aips++
mkdir data
echo "*default host=aips2.nrao.edu compress
*default base=/usr/local/aips++/data
*default delete use-rel-suffix
data release=core" > sup/files/data
cvsup sup/files/data
The data directory should now contain directories "ephemerides", "geodetic", etc...