Compiling libgretl

Compiling libgretl — How to compile libgretl itself

Building the Library on UNIX

Building libgretl is part and parcel of building the whole gretl package.

On UNIX, gretl employs the standard GNU build system, using autoconf for package configuration and resolving portability issues and libtool for building shared libraries on multiple platforms. The normal sequence for compiling and installing gretl (including libgretl) is thus:


          ./configure
          make
          make install
        

The standard options provided by GNU autoconf may be passed to the configure script. Please see the autoconf documentation or run ./configure --help for information about the standard options.

The Gretl User's Guide contains further details about the build process and ways to influence it; see sourceforge.net.

Dependencies

Before you can compile libgretl, you need to have various other tools and libraries installed on your system. The two tools needed during the build process itself are pkg-config and GNU make.

  • pkg-config is a tool for tracking the compilation flags needed for libraries that are used by libgretl. (For each library, a small .pc text file is installed in a standard location that contains the compilation flags needed for that library along with version number information.)

  • The gretl makefiles will mostly work with different versions of make. However, there is the possibility of a few incompatibilities so we recommend installing GNU make if you don't already have it on your system. (It may be called gmake rather than make.)

Libgretl depends on a number of other libraries.