##

easyblock = 'ConfigureMake'

name = 'UDUNITS'
version = '1.12.11'

homepage = 'http://www.unidata.ucar.edu/software/udunits/'
description = """UDUNITS supports conversion of unit specifications between formatted and binary forms,
 arithmetic manipulation of units, and conversion of values between compatible scales of measurement."""

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

source_urls = ['ftp://ftp.unidata.ucar.edu/pub/udunits']
sources = [SOURCELOWER_TAR_GZ]

buildopts = 'CFLAGS="-Df2cFortran -fPIC"'

builddependencies = [
    ('Bison', '3.0.5'),
    ('Perl', '5.28.0'),
]

sanity_check_paths = {
    'files': ['bin/udunits', 'etc/udunits.dat', 'include/udunits.inc', 'include/udunits.h',
              'lib/libudunits.a'],
    'dirs': [],
}

parallel = 1

moduleclass = 'phys'
