summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin.mock/packages/bzip2/package.py
diff options
context:
space:
mode:
authorRicharda Butler <39577672+RikkiButler20@users.noreply.github.com>2023-11-07 12:04:41 -0800
committerGitHub <noreply@github.com>2023-11-07 21:04:41 +0100
commit5774df6b7a295a397e30a843f5ef14b339535b64 (patch)
tree31b116612d7899565e591606b5dd1364c198f7d4 /var/spack/repos/builtin.mock/packages/bzip2/package.py
parent3a5c1eb5f370cc532629f70b28067a6711aa24e3 (diff)
downloadspack-5774df6b7a295a397e30a843f5ef14b339535b64.tar.gz
spack-5774df6b7a295a397e30a843f5ef14b339535b64.tar.bz2
spack-5774df6b7a295a397e30a843f5ef14b339535b64.tar.xz
spack-5774df6b7a295a397e30a843f5ef14b339535b64.zip
Propagate variant across nodes that don't have that variant (#38512)
Before this PR, variant were not propagated to leaf nodes that could accept the propagated value, if some intermediate node couldn't accept it. This PR fixes that issue by marking nodes as "candidate" for propagation and by setting the variant only if it can be accepted by the node. Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
Diffstat (limited to 'var/spack/repos/builtin.mock/packages/bzip2/package.py')
-rw-r--r--var/spack/repos/builtin.mock/packages/bzip2/package.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/var/spack/repos/builtin.mock/packages/bzip2/package.py b/var/spack/repos/builtin.mock/packages/bzip2/package.py
new file mode 100644
index 0000000000..326533ac5e
--- /dev/null
+++ b/var/spack/repos/builtin.mock/packages/bzip2/package.py
@@ -0,0 +1,19 @@
+# Copyright 2013-2023 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)
+
+
+from spack.package import *
+
+
+class Bzip2(Package):
+ """This packagae has the variants shared
+ defaulted to True"""
+
+ homepage = "https://example.com"
+ url = "https://example.com/bzip2-1.0.8tar.gz"
+
+ version("1.0.8", sha256="ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269")
+
+ variant("shared", default=True, description="Enables the build of shared libraries.")