summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin.mock/packages/extension1/package.py
diff options
context:
space:
mode:
authorscheibelp <scheibel1@llnl.gov>2017-01-25 20:43:12 -0800
committerTodd Gamblin <tgamblin@llnl.gov>2017-01-25 21:43:12 -0700
commite4d2d747ce247f726551e9207f6bedb7c68f2162 (patch)
tree5996524b2b590d0b4eee656c46771dd04a611df3 /var/spack/repos/builtin.mock/packages/extension1/package.py
parent596190c83cd10111b35565bd19e0bcf6cdd58f96 (diff)
downloadspack-e4d2d747ce247f726551e9207f6bedb7c68f2162.tar.gz
spack-e4d2d747ce247f726551e9207f6bedb7c68f2162.tar.bz2
spack-e4d2d747ce247f726551e9207f6bedb7c68f2162.tar.xz
spack-e4d2d747ce247f726551e9207f6bedb7c68f2162.zip
Spec.satisfies accesses Spec.concrete as property (#2928)
* Spec.satisfies accesses Spec.concrete as property Fixes #2760 When copying a spec, _concrete is always set to False for each dependency. "Spec.satisfies" was accessing the member "_concrete" directly instead of using the property "concrete". This means that if you copy a spec, the dependencies will be considered equal, but did not necessarily satisfy one another. Spec.satisfies is a prerequisite for a package to be considered an extension; as a consequence, an extension with run-time dependencies that were also extensions did not activate those extensions. This updates Spec.satisfies to avoid checking the cached member "_concrete" directly. * Added test to check for activation of dependency extension * Added test to check for transitive satisfiability between a spec and its copy
Diffstat (limited to 'var/spack/repos/builtin.mock/packages/extension1/package.py')
-rw-r--r--var/spack/repos/builtin.mock/packages/extension1/package.py39
1 files changed, 39 insertions, 0 deletions
diff --git a/var/spack/repos/builtin.mock/packages/extension1/package.py b/var/spack/repos/builtin.mock/packages/extension1/package.py
new file mode 100644
index 0000000000..d3babc6ce4
--- /dev/null
+++ b/var/spack/repos/builtin.mock/packages/extension1/package.py
@@ -0,0 +1,39 @@
+##############################################################################
+# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
+# Produced at the Lawrence Livermore National Laboratory.
+#
+# 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/llnl/spack
+# Please also see the LICENSE file 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
+##############################################################################
+from spack import *
+
+
+class Extension1(Package):
+ """A package which extends another package"""
+
+ homepage = "http://www.example.com"
+ url = "http://www.example.com/extension1-1.0.tar.gz"
+
+ extends('extendee')
+
+ version('1.0', 'hash-extension1-1.0')
+
+ def install(self, spec, prefix):
+ pass