* Add patch for py-netcdf4 so that we can build py-netcdf4 with ~mpi when netCDF was built with +mpi
* Address reviewer requests for py-netcdf4. Add conflict for 'pynetcdf4~mpi ^netcdf-c~mpi ^hdf5+mpi'
* Make py-netcdf4~mpi ^netcdf-c~mpi ^hdf5+mpi work
* Apply suggestions from code review
Co-authored-by: Sergey Kosukhin <skosukhin@gmail.com>
* Update var/spack/repos/builtin/packages/py-netcdf4/disable_parallel_support.patch
* Apply suggestions from code review
Co-authored-by: Sergey Kosukhin <skosukhin@gmail.com>
---------
Co-authored-by: Sergey Kosukhin <skosukhin@gmail.com>
* zoltan: add scotch library dependency
Due to the way the shared library is built it does not pick up
dependencies to other shared libraries correctly. This adds the library
dependency manually in the same way it is already done for parmetis.
* add tukss as maintainer for zoltan
This PR improves compatibility with specs installed before #45189, and with externals specifying a compiler, by using the annotated compiler to "satisfy" a spec query.
On top of that, the PR adds a new flag for:
```console
$ spack find --specfile-format -I %gcc
-- linux-ubuntu20.04-icelake / gcc@10.5.0 -----------------------
[+] [v4] ca-certificates-mozilla@2023-05-30 [e] [v4] cmake@3.31.6 [+] [v4] gcc-runtime@10.5.0 [e] [v4] glibc@2.31 [+] [v4] gmake@4.4.1 [+] [v4] hdf5@1.14.5 [+] [v4] pkgconf@2.2.0 [+] [v4] zlib-ng@2.2.1
==> 8 installed packages
```
which shows the specfile format of the specs being retrieved.
* actsvg: use Spack pybind11 package
This commit makes the actsvg package use the Spack-provided pybind11
package rather than having it download its own copy.
* Make pybind dependency more flexible
* mesa: add v23.3.3 and use py-packaging while python>=3.12
* miss mako>=0.8
* use py-packaging when python3.12+
Co-authored-by: Veselin Dobrev <v-dobrev@users.noreply.github.com>
* remove python depneds_on for differnent mesa version
* mesa require python3.6+ for build
* Update var/spack/repos/builtin/packages/mesa/package.py
---------
Co-authored-by: Veselin Dobrev <v-dobrev@users.noreply.github.com>
Fixes a logic bug where a -> b was assumed to imply not a -> not b
in conditional requirements.
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
* geomodel: depend on c
* hep: add geomodel
* hep: geomodel +fullsimlight
* geomodel: depends on virtual gl, not opengl
* soqt: depends on gl and glu instead of opengl
* geomodel: rm generated comments on language dependencies
* py-flit: add v3.10.0 and v3.10.1
* fixup! py-flit: add v3.10.0 and v3.10.1
* py-flit and py-flit-core: add v3.11.0
* py-flit and py-flit-core: add v3.12.0
* py-flit: some deps are runtime only
* py-flit-core: fix python dep for v3.12.0
* py-flit-core: correct versions for python dep
* update libcerf to use new URL and CMake for new versions but keep old URL and autoconf for 1.3
* add maintainer
* fix comment
---------
Co-authored-by: white238 <white238@users.noreply.github.com>
* MAINT: py-salib up to v1.5.1
* MAINT: black style requires trailing commas
* WIP: make pathos an optional dependency at the same version where salib upstream made it optional
* MAINT: fix run time requirements for older versions. Add build/run requirements for newere versions
* MAINT: spack style specs
* MAINT: spack package naming convention
* MAINT: match dependency order to version order
* Make petsc optional
* Add C dependency
* Add to cmake args
* Make petsc optional
* Add C dependency
* Add to cmake args
* Update var/spack/repos/builtin/packages/fenics-dolfinx/package.py
Co-authored-by: Alec Scott <hi@alecbcs.com>
* Fix duplicate line
---------
Co-authored-by: Alec Scott <hi@alecbcs.com>
When trying to use Spack to build Intel TBB on the EOS network file
system we use at CERN, I am facing the following error:
```
Launching the installer...
Installation directory is not empty.
The product cannot be installed into nonempty directory
'/eos/home-s/sswatman/spack/opt/spack/linux-x86_64_v2/...
intel-oneapi-tbb-2021.12.0-3jlx6hlr3z6di42f3qy35eizcse7u2tk'.
```
This error appears to happen because Spack tries to set `$HOME` to the
prefix of the package, into which the Intel installer is also trying to
install it's software. I've found that an easy fix is to set `$HOME` to
a directory in the build stage instead, as this can be guaranteed to
remain empty.
* add version 0.1.10
* add hpc-beeflow v0.1.10
* force typer version to 0.5.0
* add neo4j and redis dependencies
* add method that sets the path of neo4j and redis installations
---------
Co-authored-by: Todd Gamblin <tgamblin@llnl.gov>
* Kluge to support file-per-rank and multiple-rank-single-file read/write in CGNS, other CGNS-related changes.
* Catalyst changes
* Update to latest TriBITs
* Improved static library build
* EPU: Handle case where no elements, but add_processor_id specified
* CPUP: Handle decomp-created zgc between zones better
* IOSS: Add filessystem type function (lustre, gpfs, nfs, ...)
* CPUP: Fix handling of assemblies
* IOSS: fix io_shell compare of db with no changesets
* IOSS: Cgns - handle missing assemblies correctly
* IOSS: Clean up owning_processor calculation
* EXO2MAT: Add -i option to not transfer info records to mat file
* cudnn: aarch64 hash for several version
* Remove spurious newline
* Fix format
* [@spackbot] updating style on behalf of tehrengruber
* Fix cudnn 8.8 link derivation for aarch64
* Use sbsa for cudnn >= 8.3.1
* Fix typo
* Temporarily remove hashes
* Undo
* Use sbsa for cudnn >= 8.3.1
* Update hashes
---------
Co-authored-by: tehrengruber <tehrengruber@users.noreply.github.com>
Co-authored-by: Till Ehrengruber <tille@santis-ln001.cscs.ch>
* Automated deployment to update package flux-core 2025-04-04
* Add py-packaging
* Do not pin py-packaging
* flux-sched: build older flux-core
flux sched 0.38 was the first that required gcc
version 12 or higher, and flux-core continued to
build for some time, but eventually added
features that we are now seeing break with
sched 0.37 and the latest flux. This conflicts
should ensure that older flux-sched, which
is being built by having an older compiler,
only builds with flux-core up to 0.68.
Signed-off-by: vsoch <vsoch@users.noreply.github.com>
---------
Signed-off-by: vsoch <vsoch@users.noreply.github.com>
Co-authored-by: github-actions <github-actions@users.noreply.github.com>
Co-authored-by: vsoch <vsoch@users.noreply.github.com>
* py-gidgetlab: add v2.0.0-v2.1.0
1.1.0 doesn't work with Python 3.13.
See this commit (and the tags that contain it) for history on build
deps:
310bc109ba.
* group dependencies
Co-authored-by: Alec Scott <hi@alecbcs.com>
* set python version constraint
Co-authored-by: Alec Scott <hi@alecbcs.com>
---------
Co-authored-by: Alec Scott <hi@alecbcs.com>
* simple update of some of neovim deps
* switch to neovim fork for unibilium and add newer versions
* fix tree-sitter _DEFAULT_SOURCE vs _BSD_SOURCE
* oneliner for filter_file
* Remove hard-coded compiler
* Remove compiler flags
* Use spack functions
* Add a cxxstd variant
* Replace main branch of googletest with some random not too old version
building fenics-dolfinx resulted in the following error:
==> No patches needed for fenics-dolfinx
==> fenics-dolfinx: Executing phase: 'cmake'
==> Error: ProcessError: Command exited with status 1:
3 errors found in build log:
3 -- The C compiler identification is unknown
4 -- The CXX compiler identification is GNU 12.2.0
5 -- Detecting C compiler ABI info
6 -- Detecting C compiler ABI info - failed
7 -- Check for working C compiler: /opt/spack/[...]libexec/spack/cc
8 -- Check for working C compiler: /opt/spack/[...]libexec/spack/cc - broken
>> 9 CMake Error at /opt/spack/opt/spack/[...]/CMakeTestCCompiler.cmake:67 (message):
10 The C compiler
11
12 "/opt/spack/opt/spack/[...]/libexec/spack/cc"
13
14 is not able to compile a simple test program.
15
...
Thanks to @amd-toolchain-support issue #50021, this is easily fixed
by adding the one-liner for the missing dependency for the C compiler.
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* `x=*` constrained by `+x` now produces a boolean valued variant instead of a multi-valued variant.
* Values are now always stored as a tuple internally, whether bool, single or multi-valued.
* Value assignment has a stricter api to prevent ambiguity / type issues related to
`variant.value = "x"` / `variant.value = ["x"]` / `variant.value = ("x",)`. It's now `variant.set("x", ...)` for
single and multi-valued variants.
* The `_original_value` prop is dropped, since it was unused.
* The wildcard `*` is no longer a possible variant value in any type of variant, since the *parser*
deals with it and creates a variant with no values.
The second change technically affects non-Windows, but the
behavior should be exactly the same:
* Packages no longer have access to `.msbuild` and `.nmake`
automatically; they now get them via a dependency on `msvc`.
* Update two CMake-based packages that call `make test` to
instead call `ctest` (`netcdf-cxx4` and `pegtl`).
CMake-based packages should do this because on Windows
`make test` will not generally work, but `ctest` does.
* Fix `openssl` "make test" on Windows (WRT prior point: not
a CMake-based package).
* genfit: depend on c compiler to fix installation issues
genfit does not specify `LANGUAGES` in their `project` declaration yet, so C is also required to pass the cmake stage.
* vbfnlo: Depend on C compiler to pass configure stage
* cppunit: Depend on C compiler to pass configure stage
* Make py-pyqt5 depend on C to fix build error
* bdsim: Depend on C to pass configure stage
This strong preference fixes a sporadic issue when
concretizing environments with `unify:when_possible`.
In the first round of concretization, it is almost
certain that glibc is installed, and that spec might
provide iconv.
In later rounds using that as a provider might be
preferred, as it leads to less nodes to be "built".
To avoid duplication by default, prefer libiconv
in a stronger way than default preferences.
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
Show progress meter for fetches when `stdout` is a `tty`.
* fetch_strategy.py: show progress
* "Fetched: x MB at y MB/s"
* add tests, show % if content-length
This PR fixes the issues with `%` and reused specs, due to https://github.com/spack/spack/issues/49847#issuecomment-2774640234
It does so by adding another layer of indirection, so that whenever a spec
`foo %bar` is encountered, the `%bar` part is encoded as an
`attr("build_requirement", ...)`.
Then:
1. If `foo` is a node to be built, then the build requirement implies a dependency
2. Otherwise it implies looking e.g. reused specs metadata, and ensure it matches
---------
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
When the solver produces specs that do not satisfy the input
constraints, dump both input and output specs as json in an temporary
dir and ask the user to upload these files in a bug report.
Fetching generated tarballs from github.com sometimes takes pauses for
more than 10 seconds, when the server is slow to put together the next
bits of the tarball. Default to 30s to avoid that issue.
Currently we inject runtimes when a package has a direct build dep on a
compiler, but what matters is whether the package depends on a language.
That way we can avoid recursion of injecting runtimes to runtimes
without a rule in the solver: runtimes don't depend on languages, they
just have a build dep on the same compiler.
* Clearly split old and new hip settings requirements
* Fix style
* TO REVERT: Trigger CI
* Apply generic rocm handling to every project
* TO REVERT: Trigger CI
* Revert "TO REVERT: Trigger CI"
This reverts commit dcedb2ead5.
* Revert "TO REVERT: Trigger CI"
This reverts commit 02f76a8ca6.
* Update RADIUSS packages with latest release and sync with RSC implementation
* Update CARE package
* make default logic for hip support more robust
* TO REVERT: Trigger CI
* Fix style
* Fix style (bis)
* Shorten message
* GPU_TARGET is only necessary under certain project specific conditions, it should not be necessary in general
* Update logic to find amdclang++
* Fix syntax
* Let's postpone update of hip handling in camp
* Revert "TO REVERT: Trigger CI"
This reverts commit 620fbc1b01.
* Remove unecessary logic from CARE
* Update CARE: add 0.15.1
In this way, to run them, we just need to run:
spack unit-test lib/spack/spack/test/concretization
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
- allow conduit=ofi-slingshot11 to work with regular OpenMPI and MPICH when
they are built with ^libfabric fabrics=cxi.
- add missing libfabric dependency for conduit=ofi-slingshot11. Embedded GASNet
build uses PATH to detect libfabric installation.
This explicitly specifies the correct library for zlib to CMake:
CMake's find zlib looks for zlib before zdll. On Windows, zlib is the
static lib, and zdll the import library. LibPNG only links to shared
zlib, but was getting zlib from CMake on Windows, which was resulting
in a linker failure.
* TestSuite: add type hints
* spack test run: add a --timeout argument
* pipelines: allow 2 minutes to run tests
* Fix docstrings, increase maximum pipelines time for tests to 5 mins.
* Use SIGTERM first, SIGKILL shortly after
* Add unit-tests for "start_build_process"
---------
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
* pressio: add packages for pressio, pressio-ops, and pressio-log
* pressio: use symlinks for pressio-ops/log; specify compatible versions
* pressio: refactor supported versions, update pressio-ops to use main branch
* pressio: update package after renaming repository to pressio-rom
* pressio: remove unneeded if statement
---------
Co-authored-by: Caleb Schilly <cwschilly@gmail.com>
Multiple build systems have been part of Spack for a long
time now, and they are rarely the cause of a missing attribute.
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
Similar to the range-or-specific-version ambiguity of `@1.2` in the past,
which was solved with `@1.2` vs `@=1.2` we still have the ambiguity of
`name=a,b,c` in multi-valued variants. Do they mean "at least a,b,c" or
"exactly a,b,c"?
This issue comes up in for example `gcc languages=c,cxx`; there's no
way to exclude `fortran`.
The ambiguity is resolved with syntax `:=` to distinguish concrete from
abstract.
The following strings parse as **concrete** variants:
* `name:=a,b,c` => values exactly {a, b, c}
* `name:=a` => values exactly {a}
* `+name` => values exactly {True}
* `~name` => values exactly {False}
The following strings parse as **abstract** variants:
* `name=a,b,c` values at least {a, b, c}
* `name=*` special case for testing existence of a variant; values are at
least the empty set {}
As a reminder
* `satisfies(lhs, rhs)` means `concretizations(lhs)` ⊆ `concretizations(rhs)`
* `intersects(lhs, rhs)` means `concretizations(lhs)` ∩ `concretizations(rhs)` ≠ ∅
where `concretizations(...)` is the set of sets of variant values in this case.
The satisfies semantics are:
* rhs abstract: rhs values is a subset of lhs values (whether lhs is abstract or concrete)
* lhs concrete, rhs concrete: set equality
* lhs abstract, rhs concrete: false
and intersects should mean
* lhs and rhs abstract: true (the union is a valid concretization under both)
* lhs or rhs abstract: true iff the abstract variant's values are a subset of the concrete one
* lhs concrete, rhs concrete: set equality
Concrete specs with single-valued variants are printed `+foo`, `~foo` and `foo=bar`;
only multi-valued variants are printed with `foo:=bar,baz` to reduce the visual noise.
neoverse_v1 matches the name of the stack and more accurately captures
the requirement for these jobs. The relevant runners in GitLab already
bear both tags, so this shouldn't affect how jobs get assigned to runners.
* kokkos: add version 4.6.00
* kokkos-kernels: add version 4.6.00
* kokkos-nvcc-wrapper: add version 4.6.00 and update url to match kokkos releases
* kokkos: add zen4 support
Return a single scope from environment.env_config_scope
Return a single scope from environment_path_scope
---------
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
* e4s oneapi: upgrade to latest compilers oneapi@2025.1
* update specs and package preferences
* enable some more dav packages
* enable additional specs
* e4s oneapi: packages: elfutils does not have bzip2 variant
* e4s oneapi: packages: elfutils does not have xz variant
* e4s oneapi: comment out heffte+sycl
* comment out e4s oneapi failures
* comment out more failures
* comment out failing spec
* Revert "paraview: add patch for Intel Classic compilers (#49116)"
This reverts commit 7a95e2beb5.
We'll mark Intel Classic compilers as conflicting with ParaView
versions 5.13.0-5.13.2 instead since 5.13.3 is available and can be
built with with those compilers.
* Add conflict for Intel Class compilers and ParaView 5.13.0-5.13.2.
* paraview: add new v5.13.3 release
This commit reorders ASP setup, so that rules from
possible compilers are collected first.
This allows us to know the dependencies that may be
injected before counting the possible dependencies,
so we can account for them too.
Proceeding this way makes it easier to inject
complex runtimes, like hip.
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
Deal with the "issue" that passing a str instance does not cause a
type check failure, because str is a subset of Sequence[str] and
Iterable[str]. Instead fix it by special casing the str instance.
* fix: move depends_on(c,cxx,fortran) with other dependencies, after variants
* treewide style: move depends_on(c,cxx,fortran) with other dependencies, after variants
* treewide style: move depends_on(c,cxx,fortran) with other dependencies, after variant
---------
Co-authored-by: Alec Scott <hi@alecbcs.com>
CMake 4.0.0 breaks compatibility with CMake projects
requiring a CMake < 3.5. However, many projects that
specify a minimum requirement for versions older
than 3.5 are actually compatible with newer CMake
and do not use CMake 3.4 or older features. This
allows those projects to use a newer CMake
Co-authored-by: John W. Parent <45471568+johnwparent@users.noreply.github.com>
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
The requirements being removed are redundant, or
even outdated (%cray-prgenv-* is not a compiler in v0.23).
When compilers turned into nodes, these constraints,
with the "one_of" policy, started being unsat under
certain conditions e.g. we can't compile anymore
with GCC and depend on LLVM as a library.
Remove the requirements to make the recipe solvable
again.
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
* update packages to work with python 3.12+
* partd updates
* py-nc-time-axis updates for 3.12
* Add new py-cftime as required for py-nc-time-axis
* fix dropped python 3.9
* switch from when blocks to flat
* remove redundant requires
* protect version range for python@:3.11
* add new c-blosc to support newly added python 3.12 py-blosc version
* add scikit-build 0.18.1 for python 3.12 required for this set of commits
* add complete optional variant for py-partd to match pyproject.toml. Deprecate super old versions
* only set system blosc for the required case
* style
* Remove incorrect python bound
* improve python version reqs and move to more canonical depends_on
* move to depends from req
* add new python range limit, update comment
* remove @coreyjadams as maintainer as per their request https://github.com/spack/spack/pull/48830#issuecomment-2705062587
* Fix python bounds
Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>
---------
Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>
* Check for LSF, FLux, and Slurm when determing MPI exec
* Make scheduler/MPI exec helper functions methods of CachedCMakeBuilder
* Remove axom workaround for running mpi on machines with flux
* Clearly split old and new hip settings requirements
* Apply generic rocm handling to every project
* make default logic for hip support more robust
* GPU_TARGET is only necessary under certain project specific conditions, it should not be necessary in general
* Update logic to find amdclang++
fixes#49717
If no compiler is listed in the 'packages' section of
the configuration, Spack will currently try to:
1. Look for a legacy compilers.yaml to convert
2. Look for compilers in PATH
in that order. If an entry in compilers.yaml is
corrupted, that should not result in an obscure
error.
Instead, it should just be skipped.
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
This module references `spack.error.Something` in the same file, which happens to
work but is incorrect. Use `spack.error` to prevent that in the future.
Adds Equinox, a JAX library. I've added the latest version 0.11.2, and also 0.11.0
which is compatible with older JAX versions.
I've built both versions and loading an example from their page seems to work OK.
* Add py-wadler-lindig
* Add py-equinox
I noticed that `abseil-cpp` was showing in `spack find` with "no compiler", and the only
difference between it and other nodes was that it *only* depends on `cxx` -- others
depend on `c` as well.
It turns out that the `select()` method on `EdgeMap` only takes `Sequence[str]` and doesn't
check whether they're actually just one `str`. So asking for, e.g., `cxx` is like asking for
`c` or `x` or `x`, as the `str` is treated like a sequence. This causes Spack to miss `cxx`
and `fortran` language virtuals in `DeprecatedCompilerSpec`.
Signed-off-by: Todd Gamblin <tgamblin@llnl.gov>
Currently, externals show up in `spack find` and `spack spec` install status as a green
`[e]`, which is hard to distinguish from the green [+] used for installed packages.
- [x] Make externals magenta instead, so they stand out.
Signed-off-by: Todd Gamblin <tgamblin@llnl.gov>
Concretization setup was checking whether any input spec has a dependency
that's *not* in the set of possible dependencies for all roots in the solve.
There are two reasons to check this:
1. The user could be asking for a dependency that none of the roots has, or
2. The user could be asking for a dependency that doesn't exist.
For abstract roots, (2) implies (1), and the check makes sense. For concrete
roots, we don't care, because the spec has already been built. If a `package.py`
no longer depends on something it did before, it doesn't matter -- it's already
built. If the dependency no longer exists, we also do not care -- we already
built it and there's an installation for it somewhere.
When you concretize an environment with a lockfile, *many* of the input specs
are concrete, and we don't need to build them. If a package changes its
dependencies, or if a `package.py` is removed for a concrete input spec, that
shouldn't cause an already-built environment to fail concretization.
A user reported that this was happening with an error like:
```console
spack concretize
==> Error: Package chapel does not depend on py-protobuf@5.28.2/a4rf4glr2tntfwsz6myzwmlk5iu25t74
```
Or, with traceback:
```console
File "/apps/other/spack-devel/lib/spack/spack/solver/asp.py", line 3014, in setup
raise spack.spec.InvalidDependencyError(spec.name, missing_deps)
spack.spec.InvalidDependencyError: Package chapel does not depend on py-protobuf@5.28.2/a4rf4glr2tntfwsz6myzwmlk5iu25t74
```
Fix this by skipping the check for concrete input specs. We already ignore conflicts,
etc. for concrete/external specs, and we do not need metadata in the solve for
concrete dependencies b/c they're imposed by hash constraints.
- [x] Ignore the package existence check for concrete input specs.
Signed-off-by: Todd Gamblin <tgamblin@llnl.gov>
* Skip packages removed for automatic checksum verification
* Unify finding modified or added packages with spack.repo logic
* Remove unused imports
* Fix unit-tests using shared modified function
* Update last remaining unit test to new format
* glab: add v1.54.0 and v1.55.0
* glab: uniform go deps
Co-authored-by: Alec Scott <hi@alecbcs.com>
---------
Co-authored-by: Alec Scott <hi@alecbcs.com>
* py-jaxlib: add spack-built ROCm support
* fix style
* py-jaxlib 0.4.38 rocm support
* py-jaxlib 0.4.38 rocm support
* add comgr dependency
* changes for ROCm external and enable till 0.4.38
* enable version of py-jax
* add jax+rocm to ci
* add conflict for cuda and remove py-jaxlib from aarch64 pipeline
* Update var/spack/repos/builtin/packages/py-jaxlib/package.py
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
* add conflict for aarch64
---------
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
## Summary
Compilers stop being a *node attribute*, and become a *build-only* dependency.
Packages may declare a dependency on the `c`, `cxx`, or `fortran` languages, which
are now treated as virtuals, and compilers would be *providers* for one or more of
those languages. Compilers can also inject runtime dependency, on the node being
compiled. An example graph for something as simple as `zlib-ng` is the following:
<p align="center">
<img src="https://github.com/user-attachments/assets/ee6471cb-09fd-4127-9f16-b9fe6d1338ac" alt="zlib-ng DAG" width="80%" height="auto">
</p>
Here `gcc` is used for both the `c`, and `cxx` languages. Edges are annotated with
the virtuals they satisfy (`c`, `cxx`, `libc`). `gcc` injects `gcc-runtime` on the nodes
being compiled. `glibc` is also injected for packages that require `c`. The
`compiler-wrapper` is explicitly represented as a node in the DAG, and is included in
the hash.
This change in the model has implications on the semantics of the `%` sigil, as
discussed in #44379, and requires a version bump for our `Specfile`, `Database`,
and `Lockfile` formats.
## Breaking changes
Breaking changes below may impact users of this branch.
### 1. Custom, non-numeric version of compilers are not supported
Currently, users can assign to compilers any custom version they want, and Spack
will try to recover the "real version" whenever the custom version fails some operation.
To deduce the "real version" Spack must run the compiler, which can add needless
overhead to common operations.
Since any information that a version like `gcc@foo` might give to the user, can also
be suffixed while retaining the correct numeric version, e.g. `gcc@10.5.0-foo`, Spack
will **not try** anymore to deduce real versions for compilers.
Said otherwise, users should have no expectation that `gcc@foo` behaves as
`gcc@X.Y.Z` internally.
### 2. The `%` sigil in the spec syntax means "direct build dependency"
The `%` sigil in the spec syntax means *"direct build dependency"*, and is not a node
attribute anymore. This means that:
```python
node.satisfies("%gcc")
```
is true only if `gcc` is a direct build dependency of the node. *Nodes without a compiler
dependency are allowed.*
### `parent["child"]`, and `node in spec`, will now only inspect the link/run sub-DAG
and direct build dependencies
The subscript notation for `Spec`:
```python
parent["child"]
```
will look for a `child` node only in the link/run transitive graph of `parent`, and in its
direct build dependencies. This means that to reach a transitive build dependency,
we must first pass through the node it is associated with.
Assuming `parent` does not depend on `cmake`, but depends on a `CMakePackage`,
e.g. `hdf5`, then we have the following situation:
```python
# This one raises an Exception, since "parent" does not depend on cmake
parent["cmake"]
# This one is ok
cmake = parent["hdf5"]["cmake"]
```
### 3. Externals differing by just the compiler attribute
Externals are nodes where dependencies are trimmed, and that _is not planned to
change_ in this branch. Currently, on `develop` it is ok to write:
```yaml
packages:
hdf5:
externals:
- spec: hdf5@1.12 %gcc
prefix: /prefix/gcc
- spec: hdf5@1.12 %clang
prefix: /prefix/clang
```
and Spack will account for the compiler node attribute when computing the optimal
spec. In this branch, using externals with a compiler specified is allowed only if any
compiler in the dag matches the constraints specified on the external. _The external
will be still represented as a single node without dependencies_.
### 4. Spec matrices enforcing a compiler
Currently we can have matrices of the form:
```yaml
matrix:
- [x, y, z]
- [%gcc, %clang]
```
to get the cross-product of specs and compilers. We can disregard the nature of the
packages in the first row, since the compiler is a node attribute required on each node.
In this branch, instead, we require a spec to depend on `c`, `cxx`, or `fortran` for the
`%` to have any meaning. If any of the specs in the first row doesn't depend on these
languages, there will be a concretization error.
## Deprecations
* The entire `compilers` section in the configuration (i.e., `compilers.yaml`) has been
deprecated, and current entries will be removed in v1.2.0. For the time being, if Spack
finds any `compilers` configuration, it will try to convert it automatically to a set of
external packages.
* The `packages:compiler` soft-preference has been deprecated. It will be removed
in v1.1.0.
## Other notable changes
* The tokens `{compiler}`, `{compiler.version}`, and `{compiler.name}` in `Spec.format`
expand to `"none"` if a Spec does not depend on C, C++, or Fortran.
* The default install tree layout is now
`"{architecture.platform}-{architecture.target}/{name}-{version}-{hash}"`
## Known limitations
The major known limitations of this branch that we intend to fix before v1.0 is that compilers
cannot be bootstrapped directly.
In this branch we can build a new compiler using an existing external compiler, for instance:
```
$ spack install gcc@14 %gcc@10.5.0
```
where `gcc@10.5.0` is external, and `gcc@14` is to be built.
What we can't do at the moment is use a yet to be built compiler, and expect it will be
bootstrapped, e.g. :
```
spack install hdf5 %gcc@14
```
We plan to tackle this issue in a following PR.
---------
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
Signed-off-by: Todd Gamblin <tgamblin@llnl.gov>
Signed-off-by: Harmen Stoppels <me@harmenstoppels.nl>
Co-authored-by: Harmen Stoppels <me@harmenstoppels.nl>
Co-authored-by: Todd Gamblin <tgamblin@llnl.gov>
The `umea.se` mirror seems to have gone down (or at least is forbidden for now).
Revert the checksum changes in #47825; points at the official GNOME mirror
instead of the prior two places we were getting `gdk-pixbuf`.
Signed-off-by: Todd Gamblin <tgamblin@llnl.gov>
Since we moved from creating clingo symbols directly to constructing a pure string
representation of the program, we don't need to make `AspFunctions` into symbols before
turning them into strings. We can just write strings like clingo would.
This cuts about 25% off the setup time by avoiding an unnecessary round trip.
- [x] create strings directly from `AspFunctions`
- [x] remove unused `symbol()` method on `AspFunction`
- [x] setup no longer tries to call `symbol()`
Signed-off-by: Todd Gamblin <tgamblin@llnl.gov>
Signed-off-by: Greg Becker <becker33@llnl.gov>
---------
Signed-off-by: Todd Gamblin <tgamblin@llnl.gov>
Co-authored-by: Greg Becker <becker33@llnl.gov>
"""Return the root spec used to bootstrap black"""
return_root_spec("py-black@:24.1.0")
return_root_spec("py-black@:25.1.0")
defflake8_root_spec()->str:
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.