# IT4Innovations
# LK 2024

name = 'netCDF-Fortran'
version = '4.6.1'

homepage = 'https://www.unidata.ucar.edu/software/netcdf/'
description = """NetCDF (network Common Data Form) is a set of software libraries
 and machine-independent data formats that support the creation, access, and sharing of array-oriented
 scientific data."""

toolchain = {'name': 'iimpi', 'version': '2023b'}
import os
if os.environ.get("CLUSTERNAME") in ["KAROLINA"]:
   toolchainopts = {'usempi': True, 'opt': True, 'optarch': 'march=core-avx2'}
else:
   toolchainopts = {'usempi': True, 'opt': True}

source_urls = ['https://github.com/Unidata/netcdf-fortran/archive/']
sources = ['v%(version)s.tar.gz']
checksums = ['40b534e0c81b853081c67ccde095367bd8a5eead2ee883431331674e7aa9509f']

builddependencies = [
    ('M4', '1.4.19'),
]

dependencies = [
    ('netCDF', '4.9.2'),
    ('bzip2', '1.0.8'),
]

# (too) parallel build fails, but single-core build is fairly quick anyway (~1min)
parallel = 1

moduleclass = 'data'
