easyblock = 'ConfigureMake'

name = 'arpack-ng'
version = '3.1.3'
versionsuffix = '-mt'

homepage = 'http://forge.scilab.org/index.php/p/arpack-ng/'
description = """ARPACK is a collection of Fortran77 subroutines designed to solve large scale eigenvalue problems."""

toolchain = {'name': 'ictce', 'version': '5.3.0'}
toolchainopts = {'opt': True, 'optarch': True, 'pic': True, 'usempi': False}

source_urls = ['http://forge.scilab.org/index.php/p/arpack-ng/downloads/get/']
sources = [SOURCELOWER_TAR_GZ]

# do not change the order of the patches or things will break
patches = [
    'arpack-ng-3.1.3-update-to-head.patch',
    'arpack-ng-3.1.3-pkgconfig.patch',
]

configopts = '--with-pic --with-blas="$LIBBLAS_MT" --with-lapack="$LIBLAPACK_MT"'

sanity_check_paths = {
    'files': ["lib/libarpack.a", "lib/libarpack.%s" % SHLIB_EXT],
    'dirs': []
}

moduleclass = 'numlib'