##
# This is an easyconfig file for EasyBuild, see https://github.com/easybuilders/easybuild
#
# Copyright:: Copyright 2013-2015 Juelich Supercomputing Centre, Germany
# Authors::   Bernd Mohr <b.mohr@fz-juelich.de>
#             Markus Geimer <m.geimer@fz-juelich.de>
# License::   3-clause BSD
#
# This work is based on experiences from the UNITE project
# http://apps.fz-juelich.de/unite/
##

easyblock = 'ConfigureMake'

name = "Cube"
version = "3.4.3"

homepage = 'http://www.scalasca.org/software/cube-3.x'
description = """Cube, which is used as performance report explorer for Scalasca-1.X
 is a generic tool for displaying a multi-dimensional performance space
 consisting of the dimensions (i) performance metric, (ii) call path, and (iii) system
 resource. Each dimension can be represented as a tree, where non-leaf nodes of the tree
 can be collapsed or expanded to achieve the desired level of granularity."""

toolchain = {'name': 'gompi', 'version': '1.4.12-no-OFED'}

sources = [SOURCELOWER_TAR_GZ]
source_urls = ['http://apps.fz-juelich.de/scalasca/releases/cube/%(version_major_minor)s/dist']

checksums = [
    '703d4681851a5abf50946868f05e8f9e',    # cube-3.4.3.tar.gz
]

dependencies = [('Qt', '4.8.4')]

configopts = "--with-qmake=$EBROOTQT/bin/qmake"

sanity_check_paths = {
    'files': ["bin/cube3%s" % x for x in ["", "-qt", "_clean", "_cmp", "_cut", "_diff", "_mean", "_merge",
                                          "_part", "_remap", "_score", "_stat", "_topoassist"]] +
             ["bin/cube-config", "bin/tau2cube3", "include/cube3/Cube.h", "include/cube3/cube_error.h",
              "include/stats/P2Statistic.h", "lib/libcube3.a", "lib/libcubew3.a", "lib/libstats.a"],
    'dirs': ["include/cubew3"],
}

moduleclass = 'perf'
