A client needed help today in compiling this application on Red Hat Enterprise Linux (RHEL) 5. This blog posting is intended to provide a brief outline of getting CCP4 running on that platform.
Here's what not to try:
- download source
- use yum to get all of your prerequisites such as an old gcc compiler for c++ and fortran
- source the includes/ccp4.setup file after editing some of its variables
- set the CC and CXX environment variables to /usr/bin/gcc34
- ./configure linux
One requirement of CCP4 is that it needs Tcl, Tk, and BLT. Tcl and Tk are not well supported in RHEL5 and BLT is non-existent. By not "well supported" I mean that the tk-devel and tcl-devel rpm packages do not exist from the main Red Hat repositories.
To get around this show-stopper, I turned to my CentOS 5.2 box. CentOS is a clone of RHEL. It has a few packages that RHEL does not, especially, the Tcl and Tk libraries and header files.
Here's the recipe of what actually worked:
- on a CentOS 5 box, use yum to install tk-devel and tcl-devel
- download the Tk/Tcl/BLT tarball from the CCP4 site linked above
- unpack the tarball and cd into it
- run ./configure (perhaps with --prefix=_____)
- note carefully the directories that it says that it will write to
- make; make install
- create a tar file with the files and locations listed in the configure output
- copy the resultant tar file to the RHEL box
- extract the files from the tar file into the same directory locations and overwrite, if necessary
- The trick is not to compile from source but, instead, to download the linux binaries. They claim to be known to compile under the ancient RH 8/9. Grab it anyway.
- Unpack the binaries, edit and source the includes/ccp4.setup file, and run the BINARY.setup file.