Difference between revisions of "ApCoCoALib:CompilationInstructions"
(add initial version of build instructions, surely some refinement is needed)
Revision as of 18:08, 18 July 2007
This page describes how to compile the ApCoCoALib as of 0.99.08.
You need the following libraries:
- CoCoALib 0.98.2 (or later), we use 0.99.07 at the moment
- GMP 4.2.1 is recommended, you need at least release 4.1.4 due to bugs in earlier releases. CoCoALib will not work correctly with 4.1.3 or earlier
Optional are BLAS and Lapack libraries, but those are needed for ABM and the numerical functions.
Step by Step build instructions
Get a copy of CoCoALib and build it. You should consult the CoCoALib documentation in case of problems.
Get a copy of ApCoCoALib. Unpack the tarball in the same directory as CoCoALib. This is the default location that ApCoCoALib will look for. You can change it but at the moment this requires editing the Makefiles. We will offer the location of CoCoALib as a config option in the libconfig file in a later release. Now run configure:
[mabshoff@dhcp75 ApCoCoALib-0.99]$ ./configure ERROR: Specified config file is not a readable file: "" Please specify a config file for the external numerical libraries via --with-libconfig
You get an error because ApCoCoALib needs to be told where to find several external libraries and options. One option is to create a file called lib.config and add the following text:
# we don't want to compile in any numerical libraries NUMFLAGS=-DUSENoLapack # empty NUMLIBS NUMLIBS=
With this config file you deactivate all numerical methods provided by ApCoCoALib. Chances are you do not want to do this. But since building the numerical libraries can be a little complicated we provide precompiled libraries and config examples at http://apcocoa.org/hg/NumLibs/ FIXME: Add more details and tarballs.
With with a working set of libraries we rerun configure and get:
[mabshoff@dhcp75 ApCoCoALib-0.99]$ ./configure --with-libconfig=../NumLibs/lib.config.USEF77Lapack The C++ compiler is g++ 4.1.1 20070105 (Red Hat 4.1.1-51) The C++ optimized compilation flags are "-Wall -pedantic -fPIC -O2" Using GMP library version 4.2.1 found in "/usr/local/gmp-4.2.1-static/lib/libgmp.a". and GMP header file found in "/usr/local/gmp-4.2.1-static/include/gmp.h" Configuration process complete: info saved in configuration/autoconf.mk -----------------------------------------------------------------------
Everything is fine now. Just enter
and the ApCoCoAServer as well as the ApCoCoALib should be build.
In case of problems please complain in the forum.