summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin.mock/packages/impossible-concretization/package.py
diff options
context:
space:
mode:
authorMassimiliano Culpo <massimiliano.culpo@gmail.com>2020-11-27 20:53:39 +0100
committerGitHub <noreply@github.com>2020-11-27 20:53:39 +0100
commit8dd3797d32a62b379ffd8eb1cd08f38c2661613e (patch)
treead39988400e7da61d1b8b01bc800098af71ea3a7 /var/spack/repos/builtin.mock/packages/impossible-concretization/package.py
parente6641065af9078e2e50e99f657aa605d837d3976 (diff)
downloadspack-8dd3797d32a62b379ffd8eb1cd08f38c2661613e.tar.gz
spack-8dd3797d32a62b379ffd8eb1cd08f38c2661613e.tar.bz2
spack-8dd3797d32a62b379ffd8eb1cd08f38c2661613e.tar.xz
spack-8dd3797d32a62b379ffd8eb1cd08f38c2661613e.zip
concretizer: treat target ranges in directives correctly (#19988)
fixes #19981 This commit adds support for target ranges in directives, for instance: conflicts('+foo', when='target=x86_64:,aarch64:') If any target in a spec body is not a known target the following clause will be emitted: node_target_satisfies(Package, TargetConstraint) when traversing the spec and a definition of the clause will then be printed at the end similarly to what is done for package and compiler versions.
Diffstat (limited to 'var/spack/repos/builtin.mock/packages/impossible-concretization/package.py')
-rw-r--r--var/spack/repos/builtin.mock/packages/impossible-concretization/package.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/var/spack/repos/builtin.mock/packages/impossible-concretization/package.py b/var/spack/repos/builtin.mock/packages/impossible-concretization/package.py
new file mode 100644
index 0000000000..bb8ad02b49
--- /dev/null
+++ b/var/spack/repos/builtin.mock/packages/impossible-concretization/package.py
@@ -0,0 +1,15 @@
+# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+class ImpossibleConcretization(Package):
+ """Package that should be impossible to concretize due to a conflict
+ with target ranges. See Issue 19981.
+ """
+
+ homepage = "http://www.example.com"
+ url = "http://www.example.com/example-1.0.tar.gz"
+
+ version(1.0, 'foobarbaz')
+
+ conflicts('target=x86_64:')