2015-07-30 12:47:16 +00:00
|
|
|
How to build and install ecCodes library/tools
|
|
|
|
================================================
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-07-30 12:47:16 +00:00
|
|
|
Building and installation has been tested on several platforms and with several compilers.
|
|
|
|
However for some platforms modifications to the installation engine may be required.
|
|
|
|
If you encounter any problems during the installation procedure please send an e-mail
|
|
|
|
with your problem to:
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-07-30 12:47:16 +00:00
|
|
|
Software.Support@ecmwf.int
|
2013-03-25 12:04:10 +00:00
|
|
|
|
|
|
|
|
2015-07-30 12:47:16 +00:00
|
|
|
Installation using CMake
|
|
|
|
------------------------
|
|
|
|
This is the recommended method of installation.
|
|
|
|
However it requires that cmake be installed on your system.
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-07-30 12:47:16 +00:00
|
|
|
1. Download ecCodes from https://software.ecmwf.int/wiki/display/ECC/Releases
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-07-30 12:47:16 +00:00
|
|
|
2. Unpack distribution:
|
|
|
|
> tar -xzf eccodes-x.y.z-Source.tar.gz
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-07-30 12:47:16 +00:00
|
|
|
3. Create a separate directory where to build ecCodes:
|
|
|
|
> mkdir build
|
|
|
|
> cd build
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-10-08 09:56:25 +00:00
|
|
|
4. Run cmake pointing to the source and specify the installation location:
|
2015-07-30 12:47:16 +00:00
|
|
|
> cmake ../eccodes-x.y.z-Source -DCMAKE_INSTALL_PREFIX=/path/to/where/you/install/eccodes
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-12-02 17:37:00 +00:00
|
|
|
It is recommended that you install into a clean directory
|
|
|
|
|
2015-10-08 09:56:25 +00:00
|
|
|
5. Compile, test and install:
|
2015-07-30 12:47:16 +00:00
|
|
|
> make
|
2015-10-08 09:56:25 +00:00
|
|
|
> ctest
|
2015-07-30 12:47:16 +00:00
|
|
|
> make install
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-12-09 18:15:38 +00:00
|
|
|
You can also pass options to the cmake command above. Some typical examples are:
|
|
|
|
|
|
|
|
-DBUILD_SHARED_LIBS=OFF Install static libraries, not shared
|
2016-08-25 12:11:05 +00:00
|
|
|
-DENABLE_ECCODES_THREADS=ON Enable POSIX threads
|
2015-12-09 18:15:38 +00:00
|
|
|
-DENABLE_JPG=ON Enable JPEG encoding/decoding (for GRIB packing)
|
|
|
|
-DCMAKE_Fortran_COMPILER=pgf90 Set Fortran compiler to Portland Group F90 compiler
|
|
|
|
-DCMAKE_C_FLAGS="-O2 -Wall" Prepend the specified flags at the front
|
|
|
|
of the compilation command for C source files
|
2013-03-25 12:04:10 +00:00
|
|
|
|
2015-07-30 12:47:16 +00:00
|
|
|
For more details, please see:
|
|
|
|
https://software.ecmwf.int/wiki/display/ECC/ecCodes+installation
|
2013-03-25 12:04:10 +00:00
|
|
|
|