Skip to content

[GDAL] [package list]

GDAL/3.5.3-cpeGNU-23.09-cray-python-3.10.10 (GDAL-3.5.3-cpeGNU-23.09-cray-python-3.10.10.eb)

Install with the EasyBuild-user module:

eb GDAL-3.5.3-cpeGNU-23.09-cray-python-3.10.10.eb -r
To access module help after installation and get reminded for which stacks and partitions the module is installed, use module spider GDAL/3.5.3-cpeGNU-23.09-cray-python-3.10.10.

EasyConfig:

easyblock = 'ConfigureMake'

local_Blosc_version =        '1.21.5'        # https://github.com/Blosc/c-blosc/releases
local_cURL_version =         '8.0.1'         # https://curl.haxx.se/download/
local_expat_version =        '2.5.0'         # https://github.com/libexpat/libexpat/releases
local_JasPer_version =       '4.0.0'         # https://github.com/jasper-software/jasper/releases
local_SQLite_version =       '3.42.0'        # https://www.sqlite.org/
local_libdeflate_version =   '1.18'          # https://github.com/ebiggers/libdeflate/releases
local_giflib_version =       '5.2.1'         # https://sourceforge.net/projects/giflib/files/
local_libjpegturbo_version = '2.1.5.1'       # https://github.com/libjpeg-turbo/libjpeg-turbo/releases
local_libxml2_version =      '2.11.4'        # http://xmlsoft.org/sources/
local_libpng_version =       '1.6.39'        # http://www.libpng.org/pub/png/libpng.html
local_libtiff_version =      '4.5.0'         # https://download.osgeo.org/libtiff/
local_libwebp_version =      '1.3.2'         # https://github.com/webmproject/libwebp/releases
local_lz4_version =          '1.9.4'         # https://github.com/lz4/lz4/releases
local_PCRE2_version =        '10.42'         # https://ftp.pcre.org/pub/pcre/
local_PROJ_version =         '9.2.0'         # https://proj.org/download.html
local_Xerces_version =       '3.2.5'         # https://xerces.apache.org/xerces-c/releases.html
local_XZ_version =           '5.4.2'         # https://tukaani.org/xz/
local_zlib_version =         '1.2.13'        # https://zlib.net/
local_zstd_version =         '1.5.5'         # https://github.com/facebook/zstd/releases

local_GEOS_version =         '3.12.1'        # https://github.com/libgeos/geos/releases
local_HDF_version =          '4.2.16-2'      # https://support.hdfgroup.org/ftp/HDF/releases/
local_libgeotiff_version =   '1.7.1'         # https://github.com/OSGeo/libgeotiff/releases

name =          'GDAL'
version =       '3.5.3'
versionsuffix = '-cray-python-3.10.10'

homepage = 'https://www.gdal.org'

whatis = [
    'Description: translator library for raster geospatial data formats',
    'This module provides the command line utilities and shared libraries',
]

description = """
GDAL is a translator library for raster geospatial data formats that is released
under an X/MIT style Open Source license by the Open Source Geospatial
Foundation. As a library, it presents a single abstract data model to the 
alling application for all supported formats. It also comes with a variety of
useful commandline utilities for data translation and processing.

This module contains a number of command line tools and shared libraries.
It is built without support for Python. GDAL does have a lot more features
than are enabled in this build however. This module was installed through
EasyBuild, so users experienced with EasyBuild may further extend the
build recipe to enable additional options in GDAL.
"""

docurls = [
   'Web-based documentation on the package home page http://www.gdal.org/',
]


toolchain = {'name': 'cpeGNU', 'version': '23.09'}
toolchainopts = {'usempi': True}

source_urls = ['https://download.osgeo.org/gdal/%(version)s/']
sources =     [SOURCELOWER_TAR_XZ]
#patches =     ['GDAL-3.0.0_fix-python-CC-CXX.patch']
checksums = [
    'd32223ddf145aafbbaec5ccfa5dbc164147fb3348a3413057f9b1600bb5b3890',  # gdal-3.5.3.tar.xz
#    '223a0ed1afb245527d546bb19e4f80c00f768516ab106d82e53cf36b5a1a2381',  # GDAL-3.0.0_fix-python-CC-CXX.patch
]

builddependencies = [
    ('buildtools', '%(toolchain_version)s', '', True),
]

dependencies = [
    ('cray-hdf5', EXTERNAL_MODULE),
    ('cray-netcdf', EXTERNAL_MODULE),
    ('cray-python', EXTERNAL_MODULE),
    # Packages from the central software stack
    ('cURL',          local_cURL_version),
    ('expat',         local_expat_version),
    ('PCRE2',         local_PCRE2_version),
    ('SQLite',        local_SQLite_version),
    ('libxml2',       local_libxml2_version),
    ('giflib',        local_giflib_version),
    ('libpng',        local_libpng_version),
    ('libjpeg-turbo', local_libjpegturbo_version),
    ('JasPer',        local_JasPer_version),
    ('libwebp',       local_libwebp_version),
    ('LibTIFF',       local_libtiff_version),
    ('Blosc',         local_Blosc_version),
    ('lz4',           local_lz4_version),
    ('libdeflate',    local_libdeflate_version),
    ('zlib',          local_zlib_version),
    ('zstd',          local_zstd_version),
    ('PROJ',          local_PROJ_version),
    # Packages from the contributed repository
    ('HDF',           local_HDF_version),
    ('GEOS',          local_GEOS_version),
    ('libgeotiff',    local_libgeotiff_version),
    ('Xerces-C++',    local_Xerces_version),
]

preconfigopts  = "sed -e 's/-llapack//g' -i.eb configure && "
preconfigopts += "unset PYTHONPATH && "
configopts  = '--with-expat=$EBROOTEXPAT '
configopts += '--with-curl=$EBROOTCURL/bin ' # Path to curl-config
configopts += '--with-xml2=yes '
configopts += '--with-xerces=$EBROOTXERCESMINCPLUSPLUS '
configopts += '--with-pcre2=$EBROOTPCRE2 '
configopts += '--with-sqlite3=$EBROOTSQLITE '
# Computational geometry
configopts += '--with-geos=$EBROOTGEOS/bin/geos-config '
# File formats
configopts += '--with-hdf4=$EBROOTHDF '
configopts += '--with-hdf5=$EBROOTHDF5 '     # Alternative: Use $HDF5_ROOT
configopts += '--with-netcdf=$EBROOTNETCDF ' # Alternative: Use $NETCDF_DIR
# Compression libraries
configopts += '--with-blosc=$EBROOTBLOSC '
configopts += '--with-libdeflate=$EBROOTLIBDEFLATE '
configopts += '--with-libz=$EBROOTLIBZ '
configopts += '--with-lz4=$EBROOTLZ4 '
configopts += '--with-zstd=$EBROOTZSTD '
configopts += '--with-liblzma '   # Try with XZ, but the flag only accepts yes and no.
# Graphics libraries
configopts += '--with-gif==$EBROOTGIFLIB '
configopts += '--with-jpeg=$EBROOTLIBJPEGMINTURBO '
configopts += '--with-png=$EBROOTLIBPNG '
configopts += '--with-jasper=$EBROOTJASPER '
configopts += '--with-webp=$EBROOTLIBWEBP '
configopts += '--with-libtiff=$EBROOTLIBTIFF '
configopts += '--with-geotiff=$EBROOTLIBGEOTIFF '
# Python
configopts += '--with-python=$EBROOTPYTHON/bin/python '

prebuildopts = "unset PYTHONPATH && "

maxparallel = 1

postinstallcmds = [
    'mkdir -p %(installdir)s/share/licenses/%(name)s && ' +
    'cp LICENSE.TXT PROVENANCE.TXT NEWS.md %(installdir)s/share/licenses/%(name)s',
]

modextrapaths = {'PYTHONPATH': 'lib/python%(pyshortver)s/site-packages'}

sanity_check_paths = {
    'files': ['lib/libgdal.a', 'lib/libgdal.%s' % SHLIB_EXT, 'lib/pkgconfig/gdal.pc',
              'share/licenses/GDAL/LICENSE.TXT', 'share/licenses/GDAL/PROVENANCE.TXT'],
    'dirs':  ['bin', 'include']
}

sanity_check_commands = [ # Few commands to really test as almost all return error codes when no data file is given.
    'pkg-config --libs gdal',
    'gdal-config --version',
    "python -c 'import osgeo.gdal'",
]


moduleclass = 'data'

[GDAL] [package list]