Documentation Contents Compiling Contents

Download and use the build script

If you are using Ubuntu or Red Hat/CentOS/Fedora you should be able to download and build CCP4MG and all of its dependencies using use this build script. This script will download the source for CCP4, Python, Qt, PyQt, Pixie and CCP4MG. It will also attempt to check on Ubuntu or Red Hat/CentOS/Fedora that you have all the required development packages installed before attempting to do anything.

This script uses CCP4 version 6.2.0, Python version 2.7.2, Qt version 4.7.4 (or 4.6.2 on systems with only gcc3) and the latest nightly CVS source snapshot of CCP4MG.

Alternatively you can follow/adapt the detailed instructions below. (The build script closely follows this scheme.)

Install some auxiliary stuff

Install some required OS packages.

Compile CCP4 libs with gcc/g++

Install Python2.6

Install some Python modules we need. (Some of these are required only by ccp4i version 2, but I build them in anyway).

Compile Qt 4.6

Install PyQt

Compile MG

The setting of environment variables on command line assumes Bourne type shell. You will need to do some setenv commands for csh type shells.

Compile Pixie

Compile PISA

PISA will have been built when CCP4 was built (it is part of it), unless you did make onlylib.

But we are still having to make some patches which we hope to agree with the PISA author Eugene Krissinel.

Download the patch: ccp4mg-2.5.1-pisa-patch.tar.gz

cd ccp4_dir/src/pisa/pisa
tar zxvf path to/ccp4mg-2.5.1-pisa-patch.tar.gz
rm -f pisa_interface.o pisa_view.o
make
cp pisa ccp4mg_dirccp4_suite/bin
cp -a sbase ccp4mg_dirccp4_suite/share

Do not do this if you plan to use this copy of PISA in any other way from with CCP4MG. Make a separate copy in that instance.

Install monomer library

cp -a ccp4_dir/lib/data/monomers/ ccp4mg_dir/data/monomer_library

Copy CCP4 libraries

If the CCP4 libraries were built as shared objects (.so files, you configured CCP4 with --with-shared-libs) rather than .a( configured with --non_shared),then you need to copy these libraries into the CCP4MG lib directory.

cp ccp4_dir/lib/libclipper*so* ccp4mg_dir/lib/
cp ccp4_dir/lib/lib*fftw*so* ccp4mg_dir/lib/
cp ccp4_dir/lib/lib*ccp4*so* ccp4mg_dir/lib

Run the program

ccp4mg_dir/bin/ccp4mg

Build release

cp /usr/local/Trolltech/Qt-4.6.2/lib/libQt*.so* ccp4mg_dir/lib
cp -a /usr/local/Trolltech/Qt-4.6.2/plugins ccp4mg_dir/QtPlugins
cp /usr/lib/lib{png,gif,ungif,tiff,jpeg,z}.so.* ccp4mg_dir/lib
cp -a <path to python2.6 installation> ccp4mg_dir/pythondist
cd ccp4mg_dir
make distrib