# IT4Innovations
# LK 2024

name = 'NVHPC'
version = '24.3'

homepage = 'https://developer.nvidia.com/hpc-sdk/'
description = """C, C++ and Fortran compilers included with the NVIDIA HPC SDK (previously: PGI)"""

toolchain = SYSTEM

local_tarball_tmpl = 'nvhpc_2024_%%(version_major)s%%(version_minor)s_Linux_%s_cuda_multi.tar.gz'
# By downloading, you accept the HPC SDK Software License Agreement
# https://docs.nvidia.com/hpc-sdk/eula/index.html
# accept_eula = True
source_urls = ['https://developer.download.nvidia.com/hpc-sdk/%(version)s/']
sources = [local_tarball_tmpl % '%(arch)s']
checksums = [
    {
        local_tarball_tmpl % 'aarch64':
            '6385847de5f8725e5c56d2abf70c90fed5490f2e71a7bd13d3f4ada8720ef036',
        local_tarball_tmpl % 'ppc64le':
            'e7330eb35e23dcd9b0b3bedc67c0d5443c4fd76b59caa894a76ecb0d17f71f43',
        local_tarball_tmpl % 'x86_64':
            '6385847de5f8725e5c56d2abf70c90fed5490f2e71a7bd13d3f4ada8720ef036',
    }
]

local_gccver = '12.2.0'
dependencies = [
    ('GCCcore', local_gccver),
    ('binutils', '2.39', '', ('GCCcore', local_gccver)),
    # This is necessary to avoid cases where just libnuma.so.1 is present in the system and -lnuma fails
    ('numactl', '2.0.16', '', ('GCCcore', local_gccver)),
]

module_add_cuda = False

moduleclass = 'compiler'