GDL on Linux

Packages Compilation script build_gdl.sh cmake

packages:

Check the packaged version before installing! Most packages are always well beyond the current evoloution of the code. It may be better to use the releases on Github (including the weekly ones), even if it means installing by hand.

  • Fedora: https://src.fedoraproject.org/rpms/gdl actively maintained.

  • Mageia: https://madb.mageia.org/package/show/application/0/arch/x86_64/name/gnudl

  • Debian:

    • https://packages.debian.org/stable/gnudatalanguage

    • https://packages.debian.org/unstable/gnudatalanguage

    • https://packages.debian.org/python3-gdl in ‘unstable’

  • Ubuntu:

    • http://packages.ubuntu.com/gnudatalanguage

    • https://packages.ubuntu.com/python3-gdl

  • Gentoo:

    • https://packages.gentoo.org/packages/dev-lang/gdl

  • Arch:

    • https://aur.archlinux.org/packages/gnudatalanguage

  • OpenSUSE:

    • https://software.opensuse.org//download.html?project=science&package=gdl-language

At the moment, you can

  • download the unstable weekly build binaries from https://github.com/gnudatalanguage/gdl/releases/tag/weekly-release, also see #957

Compilation:

or you can compile the code.

Two mains paths :

script:

Way 1 using the script scripts/build_gdl.sh (assuming you can be sudo)

  • Assuming you already have a c++ compiler , Cmake (version > 3.2), curl or wget, git

  • Download the gdl code, and run gdl/scripts/build_gdl.sh several times:

  • build_gdl.sh prep will install the required libraries. (If you are not sudoer you will get a list of libs. your admin. will installed for you.)

  • build_gdl.sh configure will run Cmake to prepare the Make file

  • build_gdl.sh build will build gdl in build.

  • build_gdl.sh install. This is the simplest way to be sure the paths and the links to the libs are OK.

A summary for Ubuntu/Debian (for RH/Fedora, just change apt-get by rpm …):

apt-get install git
apt-get install curl   // December 2021 because of Qhull ...
apt-get install cmake
apt-get install g++
mkdir GDL
cd GDL
git clone --recursive https://github.com/gnudatalanguage/gdl
cd gdl
./scripts/build_gdl.sh prep   <<-- need to be sudo to add set of official packages
./scripts/build_gdl.sh configure
./scripts/build_gdl.sh build
(./scripts/build_gdl.sh check)
./scripts/build_gdl.sh install  

then you should be able to start GDL by : ./install/bin/gdl

This efficient and simple way was successfully tested on : Ubuntu 16.04 LTS, 18.04 LTS (may have a glitch due to Magicks libs), 20.04 LTS, 22.04 LTS; Debian 9, 10, Sid; Fedora 28

cmake:

or, traditional way,Way 2 using CMake :

  • GDL is written in such a way you can compile it fully in user space, without being root, as long as all the mandatory packages (-dev/-devel) are around. If some packages are missing or outdated (e.g. Eigen3), yes, you can use a version in your user space, giving the path as a parameter to CMake (e.g. -DEIGEN3DIR=/path/to/local/Eigen3)

  • GDL can be compiled with : GCC (GNU C Compiler), Clang (LLVM), icc (Intel C compiler)

  • GDL now requests CMake 3+. On some old systems (Debian 9, U 14.04) you have access to CMake 3+ with package cmake3 or equivalent module (on HPC with module)

  • The wxWidgets library is mandatory (unless you know how to tweak the cmake). X11 will be supported in parallel if option -DX11=ON is set when calling cmake. GDL starts with the X11 interface (for plots, not widgets!) when called as “gdl -X”.

  • When compiling the first time, you may be blocked because one package is missing. After installing it, it is mandatory to clean the cache before running again cmake (rm -f CMakeCache.txt)

  • Compilation. Once all the packages are around, it is quite fast on multi-cores :)

git clone --recursive https://github.com/gnudatalanguage/gdl
cd gdl
mkdir build
cd build
cmake ..
make -j N  (N depending the number of cores you have)
make test

(on my old laptop with N=4, less than 5 minutes)