GDL on Windows¶
Download the GDL Installer¶
Found in Weekly builds and all our Releases
It will install GDL on your machine automatically. For 64 bit builds, you can also choose whether to install GDL Workbench, an Eclipse-based IDE for GDL (for more information, visit https://github.com/gnudatalanguage/gdlde).
Do not panic, if the weekly release has no windows installer, you can still get one using the compilation method below.
Currently, there are three different types of builds:
mini: only includes mandatory libraries to run a very minimal and barely usable GDL.
full: includes all optional libraries except MPI. This is the one you should use.
full-msmpi: includes all optional libraries + MPI. This requires Microsoft MPI pre-installed (https://docs.microsoft.com/en-us/message-passing-interface/microsoft-mpi). This version of GDL is slightly slow at startup due to the initialization of MPI.
Automatic CI builds¶
Automatic builds of the master branch are available on the GitHub Actions page (64-bit and 32-bit, Debug and Release).
Compilation (build locally)¶
Choose your MSYS2 environment
GDL is built with MSYS2. MSYS2 provides several environments; each one has its own compiler and its own libraries (in its own folder), so always do every step in the same environment.
MSYS2 UCRT64 (
Platform=ucrt-x86_64): builds GDL for Windows x64, with gcc and the Universal CRT. Recommended (MSYS2’s default, all packages available).MSYS2 CLANGARM64 (
Platform=clang-aarch64): builds a native GDL for Windows ARM64 (Snapdragon PCs…), with clang. No MPI, no NSIS installer.MSYS2 MINGW64 (
Platform=x86_64): builds GDL for Windows x64, with gcc and msvcrt. Used by the CI. Some optional packages are no longer provided (wxWidgets, GraphicsMagick, eccodes, shapelib).MSYS2 MINGW32 (
Platform=i686): builds GDL for Windows x86 (32-bit), with gcc. Same missing packages as MINGW64.
Platformis also the prefix of the MSYS2 package names (mingw-w64-${Platform}-...).Windows on ARM: the x64 builds (MINGW64, UCRT64) also work on an ARM64 PC, through Windows’ built-in x64 emulation, but they run slower. Use CLANGARM64 for a native ARM64 GDL.
Download and install MSYS2. Then run the terminal of your environment from the Start menu (for example MSYS2 UCRT64 or MSYS2 CLANGARM64), and update MSYS2 (run it again if it asks you to close the terminal):
$ pacman -Syu
Set environment variables.
$ export ROOT_DIR=/path/to/store/everything $ export Platform=ucrt-x86_64 # x86_64, ucrt-x86_64, clang-aarch64 or i686 (see the list above) $ export DEPS=standard # or 'debug' or 'headless' $ export Configuration=Release # or 'Debug'. linking of GDL in 'Debug' is *extremely slow*
Platformis needed by thepacmancommand of step 3. If the packages of step 3 are already installed, it is optional:build_gdl.shthen deduces it from the terminal you opened ($MSYSTEM).Install packages needed to compile GDL.
$ pacman -S --needed mingw-w64-${Platform}-toolchain mingw-w64-${Platform}-cmake mingw-w64-${Platform}-nsis zip unzip tar zstd git base-develCLANGARM64:
nsisdoes not exist for ARM64, so use this command instead (it also installs thegcc/g++wrappers for clang, needed to build bsd-xdr):$ pacman -S --needed mingw-w64-clang-aarch64-toolchain mingw-w64-clang-aarch64-cmake mingw-w64-clang-aarch64-gcc-compat zip unzip tar zstd git base-devel
Check that the compiler and CMake come from your environment (
/ucrt64/bin,/clangarm64/bin, …):$ which gcc cmake
Change directory to
ROOT_DIRand clone GDL.$ cd $ROOT_DIR $ git clone --recursive https://github.com/gnudatalanguage/gdl
Build GDL.
$ gdl/scripts/build_gdl.sh prep # download libraries $ gdl/scripts/build_gdl.sh configure # run CMake to prepare the make file $ gdl/scripts/build_gdl.sh build # build GDL $ gdl/scripts/build_gdl.sh install # install GDL $ ls install # compiled results will be here
(Optional) Run the tests.
$ gdl/scripts/build_gdl.sh check
IMPORTANT: package GDL into a zip and an NSIS installer.
Not available with CLANGARM64 (NSIS does not exist for ARM64): run
gdlfrom the MSYS2 CLANGARM64 terminal instead (install/bin/gdl).$ export GDLDE_VERSION=v1.0.0 # replace this with any newer release $ gdl/scripts/build_gdl.sh pack $ ls package # packages will be here $ gdl/scripts/build_gdl.sh prep_deploy
Then use the installer freshly created in
gdl/.
It is recommended to use gdl/scripts/build_gdl.sh build (instead of just “make”) anytime you download a new version of GDL sources, as the script adds magic of its own.
IMPORTANT: You may be able to call directly $ gdl once step 5 is done, but we recommend to build and use the installer just made above (gdl/scripts/build_gdl.sh pack) to install the new GDL (more windows-like).