summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin/packages/scr/package.py
diff options
context:
space:
mode:
Diffstat (limited to 'var/spack/repos/builtin/packages/scr/package.py')
-rw-r--r--var/spack/repos/builtin/packages/scr/package.py40
1 files changed, 14 insertions, 26 deletions
diff --git a/var/spack/repos/builtin/packages/scr/package.py b/var/spack/repos/builtin/packages/scr/package.py
index 1f49f34969..cffbcd8a12 100644
--- a/var/spack/repos/builtin/packages/scr/package.py
+++ b/var/spack/repos/builtin/packages/scr/package.py
@@ -1,31 +1,11 @@
-##############################################################################
-# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
-# Produced at the Lawrence Livermore National Laboratory.
+# Copyright 2013-2018 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
-# This file is part of Spack.
-# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
-# LLNL-CODE-647188
-#
-# For details, see https://github.com/spack/spack
-# Please also see the NOTICE and LICENSE files for our notice and the LGPL.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License (as
-# published by the Free Software Foundation) version 2.1, February 1999.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and
-# conditions of the GNU Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-##############################################################################
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
from spack import *
import os
-import shutil
class Scr(CMakePackage):
@@ -34,13 +14,16 @@ class Scr(CMakePackage):
capability for MPI codes"""
homepage = "http://computation.llnl.gov/projects/scalable-checkpoint-restart-for-mpi"
+ url = "https://github.com/LLNL/scr/archive/v1.2.0.tar.gz"
+ git = "https://github.com/llnl/scr.git"
# NOTE: scr-v1.1.8 is built with autotools and is not properly build here.
# scr-v1.1.8 will be deprecated with the upcoming release of v1.2.0
# url = "https://github.com/LLNL/scr/releases/download/v1.1.8/scr-1.1.8.tar.gz"
# version('1.1.8', '6a0f11ad18e27fcfc00a271ff587b06e')
- version('master', git='https://github.com/llnl/scr.git', branch='master')
+ version('master', branch='master')
+ version('1.2.0', '060e9e9c7604c1765f3991f9cd6e9d2d')
depends_on('pdsh+static_modules', type=('build', 'run'))
depends_on('zlib')
@@ -89,6 +72,8 @@ class Scr(CMakePackage):
variant('cntl_base', default='/tmp',
description='Compile time default location for control directory.')
+ conflicts('platform=bgq')
+
def get_abs_path_rel_prefix(self, path):
# Return path if absolute, otherwise prepend prefix
if os.path.isabs(path):
@@ -100,6 +85,9 @@ class Scr(CMakePackage):
spec = self.spec
args = []
+ if 'platform=cray' in spec:
+ args.append('-DSCR_LINK_STATIC=ON')
+
args.append('-DENABLE_FORTRAN={0}'.format('+fortran' in spec))
conf_path = self.get_abs_path_rel_prefix(
@@ -143,4 +131,4 @@ class Scr(CMakePackage):
if spec.variants['copy_config'].value:
dest_path = self.get_abs_path_rel_prefix(
spec.variants['scr_config'].value)
- shutil.copyfile(spec.variants['copy_config'].value, dest_path)
+ install(spec.variants['copy_config'].value, dest_path)