##
# This file is an EasyBuild reciPY as per https://github.com/hpcugent/easybuild
#
# Copyright:: Copyright 2012-2014 Uni.Lu/LCSB, NTUA
# Authors::   Fotis Georgatos <fotis@cern.ch>
# License::   MIT/GPL
# $Id$
##

name = 'Chapel'
version = '1.7.0'

homepage = 'http://chapel.cray.com'
description = """ Chapel is an emerging parallel programming language whose design and development
 is being led by Cray Inc. Chapel is designed to improve the productivity of high-end computer users
 while also serving as a portable parallel programming model that can be used on commodity clusters
 or desktop multicore systems. Chapel strives to vastly improve the programmability of large-scale
 parallel computers while matching or beating the performance and portability of current programming
 models like MPI."""

toolchain = {'name': 'goolf', 'version': '1.4.10'}
toolchainopts = {'optarch': True, 'pic': True}

sources = [SOURCELOWER_TAR_GZ]
source_urls = [('http://sourceforge.net/projects/%(namelower)s/files/%(namelower)s/%(version)s/', 'download')]

unpack_options = '--strip-components=1'

# parallel build fails
parallel = 1

libpath = 'lib/linux64/gnu/comm-none/substrate-none/seg-none/'
libpath += 'mem-default/tasks-fifo/threads-pthreads/atomics-intrinsics/'

sanity_check_paths = {
    'files': ['bin/linux64/chpl', 'bin/linux64/chpldoc', '%s/libchpl.a' % libpath, '%s/main.o' % libpath],
    'dirs': [],
}

modextrapaths = {
    'PATH': 'util',
    'CHPL_HOME': '',
}

moduleclass = 'lang'
