Help:Doc CCA Install Fedora

From CSDMS
Revision as of 11:15, 18 March 2009 by Huttone (talk | contribs) (Add link back to general install page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Installing CCA Tools on Fedora

The CCA tools have been successfully built and installed on Fedora 8 and 9. Installation on other versions should also be possible.

Before starting, please read over the generic install instructions.

Fedora 8

Unlike installing on Fedora 9, the CCA tools install process is fairly painless on Fedora 8. Before starting, make sure that you have the following programs installed on you machine,

gcc 4.1.2
g++ 4.1.2
python 2.5.1
java 1.7.0
gfortran 4.1.2

In addition, you should have a version of tclsh in your path.

Fedora 9

Fedora 9 comes with gcc 4.3 which causes problems with the CCA build. In particular with the packages: spec_neo, spec_babel, and ccaffeine. With version 4.3, the GNU folks cleaned-up many of the include files, by removing unnecessary includes. For instance cstring is no longer included within string. This generates errors that look something like, <geshi> error: 'strcmp' was not declared in this scope </geshi> There are two fixes:

  1. Use an older (but not too old) version of gcc. 4.1 is a good choice, but 3.4 is too old (the babel build uses options that are apparently not available in 3.4).
  2. Add the appropriate include directives to the offending files. Note that there is a long list of offending files. I will provide a fixed version of the packages, and an updated contractor that knows to download these packages.

For this build I used the following:

gcc 4.3.0
g++ 4.3.0
python 2.5.1
java 1.6.0
gfortran 4.3.0

If you don't have tclsh (I didn't), install it now. Finally, after unpacking the cca-tools-contractor.tar.gz, you will need to edit two files: packages/libxml2.py, and packages/ccafe_gui.py. The versions of these packages need to be updated, as neither of the indicated versions are available. The libxml2 version should be, <geshi lang=python> libxml2_version = "2.6.31" </geshi> If you already have libxml2 installed on your system, don't bother updating this as contractor should realize this and so won't try to build it. The ccafe_gui version should be set as: <geshi lang=python> ccafe_gui_default_version = "0.5.6" </geshi>

Below is my install script for the Fedora build. This should be run from within the cca-tools-contractor at the same level as contract.py. <geshi lang=bash>

  1. !/bin/sh
  1. Location to put the CCA tools

PREFIX=$HOME/cca

  1. Define the compilers

CC=/usr/bin/gcc CXX=/usr/bin/g++ PYTHON=/usr/bin/python JAVA=/usr/bin/java F77=/usr/bin/gfortran F90=/usr/bin/gfortran

  1. Configure contractor to build the CCA tools

./contract.py --configure \

             prefix=$PREFIX \
             cc=$CC \
             cxx=$CXX \
             java=$JAVA \
             f77=$F77 \
             f90=$F90
  1. Build the CCA toolchain

./contract.py </geshi>