Back to CERTI Installation Documentation index

# Building CERTI

CERTI comes as either as an installer (binary) or compressed tar source archives.

This section describes how to build CERTI executables from the source code.

The primary distribution format is gzip compressed tar source archive (.tar.gz) or ZIP archive (.zip) and may be found on Savannah CERTI download area: http://download.savannah.nongnu.org/releases/certi/ .

CERTI build system uses CMake, http://www.cmake.org/ which is a cross-platform build system generator. CMake should be used to compile CERTI SDK on a variety of platform/compiler combination like:

- Linux x86 / gcc
- Linux x86_64 / gcc
- Solaris Sparc / Sun Studio
- Windows / Visual Studio
- Windows / Code::Blocks+MinGW
- ...

You may follow generic CMake usage instruction for building CERTI on various platforms: Running CMake, http://www.cmake.org/cmake/help/runningcmake.html://www.cmake.org/ or you may try to follow the below CERTI CMake usage.

## Prerequisites

CERTI compilation requires a working C++ compiler and some development tools. You may have them already installed on your system or you may download and install the missing prerequisites. All used tools are free software.

CMake

- Windows installer
  - http://www.cmake.org/HTML/Download.html
- Fedora Linux

       yum install cmake

- Debian/Ubuntu Linux

       apt-get install cmake

Flex, Bison and m4

- Windows installer
  - http://gnuwin32.sourceforge.net/packages/flex.htm
  - http://gnuwin32.sourceforge.net/packages/bison.htm
  - http://gnuwin32.sourceforge.net/packages/m4.htm
- Fedora Linux

       yum install flex bison

- Debian/Ubuntu Linux

       apt-get install flex bison

NSIS (optionally, for building a Windows installer)

- Windows installer
  - http://nsis.sourceforge.net/Main_Page

libxml2 (optionally, to enable federation save and restore)

- Windows installer
  - http://www.zlatkovic.com/libxml.en.html
- Fedora Linux

       yum install libxml2-devel

- Debian/Ubuntu Linux

       apt-get install libxml2-devel

## Building CERTI on Unix with Makefile generator

If you get a tarball source CERTI distribution such as you may found in the download section of the Savannah project http://download.savannah.nongnu.org/releases/certi/, you should follow these steps:

1. untar the archive: tar zxvf certi-<version>-Source.tar.gz this should create a certi-<version>-Source directory

        tar zxvf certi-3.2.4-Source.tar.gz
        ... wait for tar ending ...

2. Prepare separate build directory and run CMake

        mkdir build_certi
        cd build_certi
        cmake -DCMAKE_INSTALL_PREFIX=/path/to/install /path/to/certi-\<version\>-Source
        ... wait for cmake run  ending ...

3. compile your certi

        make
        ... wait the compilation end ...

4. Then you may either install CERTI or build a binary package that will be usable for installation
   - install CERTI

          make install
          ... wait for make install end ...

   - build your binary package

          make package

After that you will have a compiled and usable CERTI package.

## Building CERTI on Unix (GUI)

CMake 2.6.0 and up comes with a nice and handy graphical user interface which may be invoked with the cmake-gui command.

## Building CERTI on Windows

Enter the Start menu and launch the CMake application. Enter the folder for the source code (e.g. `\certi`, created during the previous step). Enter the folder for building the programs (e.g. `\tempo`).

Hit the `Configure` button.

Choose the appropriate Generator.

Verify the the paths for the different tools (flex, bison) before hitting `Configure` again.

Repeat `Configure` until you get an enabled `OK` button.

You should get a `build` folder (e.g. \tempo) which looks like this:

Launch the `CERTI.sln` (e.g. using Microsoft Visual C++ 2005).

Select desired configuration (Debug or Release) and build the project (using Build All). Take a look at your folder: