# IT4Innovations 2021
# LK

name = 'HDF5'
version = '1.12.1'
versionsuffix = '-parallel'

homepage = 'http://www.hdfgroup.org/HDF5/'
description = """HDF5 is a unique technology suite that makes possible the management of
 extremely large and local_complex data collections."""

toolchain = {'name': 'intel', 'version': '2021b'}
toolchainopts = {'pic': True, 'usempi': True}

source_urls = [
    'https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-%(version_major_minor)s/hdf5-%(version)s/src']
sources = [SOURCELOWER_TAR_GZ]
checksums = ['79c66ff67e666665369396e9c90b32e238e501f345afd2234186bfb8331081ca']

# AMD/intel cpu
import os
if os.environ.get("CLUSTERNAME") in ["KAROLINA"]:
  prebuildopts = "echo %(builddir)s && while read i; do echo $i; sed 's|-xHost|-avx2|g' -i $i; done < <(grep xHost %(builddir)s -R | cut -d ':' -f 1 | sort -u) && "

configopts = '--enable-fortran --enable-fortran 2003 --enable-cxx'

dependencies = [
    ('zlib', '1.2.11'),
    ('Szip', '2.1.1'),
]

moduleclass = 'data'
