easyblock = "Toolchain"

name = 'gmpolf'
version = '1.4.8'

homepage = '(none)'
description = """gcc and GFortran based compiler toolchain,
 MPICH for MPI support, OpenBLAS (BLAS and LAPACK support), FFTW and ScaLAPACK."""

toolchain = {'name': 'dummy', 'version': 'dummy'}

comp_name = 'GCC'
comp_version = '4.8.1'
comp = (comp_name, comp_version)

blaslib = 'OpenBLAS'
blasver = '0.2.6'
blas = '%s-%s' % (blaslib, blasver)
blassuff = '-LAPACK-3.4.2'

# toolchain used to build  dependencies
comp_mpi_tc_name = 'gmpich'
comp_mpi_tc_ver = version
comp_mpi_tc = (comp_mpi_tc_name, comp_mpi_tc_ver)

# compiler toolchain dependencies
dependencies = [
    comp,
    ('MPICH', '3.0.4', '', comp),  # part of gmpich toolchain
    (blaslib, blasver, blassuff, comp_mpi_tc),
    ('FFTW', '3.3.3', '', comp_mpi_tc),
    ('ScaLAPACK', '2.0.2', '-%s%s' % (blas, blassuff), comp_mpi_tc),
]

moduleclass = 'toolchain'
