# IT4Innovations 2020
# !!! --include-easyblocks /apps/easybuild/it4i-easyblocks/easyblocks/a/allineabase.py !!!
# LK

easyblock = 'AllineaBase'

name = 'Forge'
version = "20.1.1"

homepage = 'http://www.allinea.com/products/develop-allinea-forge'
description = """Allinea Forge is the local_complete toolsuite for software development
- with everything needed to debug, profile, optimize, edit and build C, C++
and FORTRAN applications on Linux for high performance - from single threads through
to local_complex parallel HPC codes with MPI, OpenMP, threads or CUDA.
"""

toolchain = SYSTEM

source_urls = [
    # Use manually downloaded sources
    # http://content.allinea.com/downloads/allinea-reports-latest-Redhat-6.0-x86_64.tar
    # and rename it to format %(namelower)s-%(version)s.tar, so
    # forge-7.0.4.tar.
]
sources = ['arm-forge-20.1.1-Redhat-7.0-x86_64.tar']

skipsteps = ['configure', 'build']

postinstallcmds = [
    'ln -s /apps/licenses/Arm/Licence %(installdir)s/licences/Licence.16312',
    'ln -s /apps/licenses/PerformanceReports/Licence %(installdir)s/licences/Licence.16313',
]

sanity_check_paths = {
    'files': [
        'bin/ddt-client',
        'bin/map',
        'bin/ddt',
        #'bin/ddt-debugger',
        #'bin/ddt-debugger-ll',
        #'bin/ddt-debugger-mps',
        'bin/ddt-mpirun',
        'bin/forge',
        'bin/make-profiler-libraries'],
    'dirs': ['lib'],
}

moduleclass = 'debugger'
