Skip to content

[MPC] [package list]

MPC/1.3.1-cpeGNU-24.03 (MPC-1.3.1-cpeGNU-24.03.eb)

To access module help and find out for which stacks and partitions the module is installed, use module spider MPC/1.3.1-cpeGNU-24.03.

EasyConfig:

easyblock = 'ConfigureMake'

local_GMP_version =          '6.3.0'         # https://ftp.gnu.org/gnu/gmp/
local_MPFR_version =         '4.2.0'         # https://ftp.gnu.org/gnu/mpfr/
local_MPC_version =          '1.3.1'         # https://ftp.gnu.org/gnu/mpc/

name =    'MPC'
version = local_MPC_version

homepage = 'http://www.multiprecision.org/mpc/'

whatis = [
    'Description: GNU MPC is a C library for arbitrary precision arithmetic of complex numbers',
]

description = """
GNU MPC is a C library for the arithmetic of complex numbers with arbitrarily
high precision and correct rounding of the result. It extends the principles of
the IEEE-754 standard for fixed precision real floating point numbers to complex
numbers, providing well-defined semantics for every operation. At the same time,
speed of operation at high precision is a major design goal.

The library is built upon and follows the same principles as GNU MPFR.
"""

docurls = [
    'PDF manual downloadable at http://www.multiprecision.org/mpc/documentation.html',
    'Support for the info command (info mpc)'
]

software_license_urls = [
    f'https://gitlab.inria.fr/mpc/mpc/-/blob/{version}/COPYING.LESSER?ref_type=tags',
]

toolchain = {'name': 'cpeGNU', 'version': '24.03'}
toolchainopts = {'pic': True}

source_urls = ['http://ftpmirror.gnu.org/gnu/mpc/']
sources =     [SOURCELOWER_TAR_GZ]
checksums =   ['ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8']

builddependencies = [ # Create a reproducible build environment.
    ('buildtools', '%(toolchain_version)s', '', True),
]

dependencies = [
    ('GMP',  local_GMP_version),
    ('MPFR', local_MPFR_version),
]

# Doesn't need MPI, ROCm or BLAS, and module unload never fails so this is safe.
preconfigopts = 'module unload cray-libsci cray-mpich rocm xpmem && '
prebuildopts = preconfigopts
pretestopts = preconfigopts
preinstallopts = preconfigopts

# The configopts below are not really needed as they are either the defaults or the
# libraries are found in other ways.
configopts = '--enable-static --enable-shared --with-gmp="$EBROOTGMP" --with-mpfr="$EBROOTMPFR"'

runtest = 'check' # Takes roughly 5 times the time of configure/build.

postinstallcmds = [
    'mkdir -p %(installdir)s/share/licenses/%(name)s',
    'cp AUTHORS COPYING.LESSER NEWS README %(installdir)s/share/licenses/%(name)s',   
]

sanity_check_paths = {
    'files': ['lib/libmpc.%s' % x for x in ['a', 'la', SHLIB_EXT]] +
             ['include/mpc.h', f'share/licenses/{name}/COPYING.LESSER'],
    'dirs':  []
}

modextrapaths = {
    'INFOPATH' : 'share/info',
}

moduleclass = 'math'

[MPC] [package list]