Compare commits

...

1072 Commits

Author SHA1 Message Date
Harmen Stoppels
ef544a3b6d Add a more detailed HTTPError (#39187) 2023-08-05 11:16:51 +02:00
Adam J. Stewart
4eed832653 py-pyqt6: add new package (#32696) 2023-08-04 18:49:54 -05:00
Wouter Deconinck
5996aaa4e3 acts: new versions 23.[3-5].0, 24.0.0, 25.0.[0-1], 26.0.0, 27.[0-1].0, 28.0.0 (#37055)
* acts: new version 23.[3-5].0, 24.0.0
- https://github.com/acts-project/acts/compare/v23.2.1...v23.3.0
- https://github.com/acts-project/acts/compare/v23.3.0...v23.4.0
- https://github.com/acts-project/acts/compare/v23.4.0...v23.5.0
- https://github.com/acts-project/acts/compare/v23.5.0...v24.0.0
* acts: update dependencies
* acts: new versions 25.0.0, 25.0.1, 26.0.0, 27.0.0
* [@spackbot] updating style on behalf of wdconinc
* acts: rm duplicate edm4hep variant definition
* acts: depends_on podio 0.6: open ended range
* acts: new version 27.1.0
* acts: depends_on mlpack when +mlpack
* acts: new version 28.0.0
* actsvg: new version 0.4.35
* acts: depends_on actsvg@0.4.35: when @28:

---------

Co-authored-by: wdconinc <wdconinc@users.noreply.github.com>
2023-08-04 16:47:15 -07:00
Brian Van Essen
4957607005 FIX libfabric module file (#39271)
* Add support to export the LD_LIBRARY_PATH for the libfabric package
and subsequent module files.

Fix the AWS OFI RCCL package so that it prepends the enviornment
variables.

* Fixed comment
2023-08-04 15:04:54 -07:00
Matt Drozt
78bca131fb [py-smartredis] New Package (#39098)
* Create a spack package for smartredis python client

* make py-SR deps versions match docs

* tie SR v0.4.0 to redis-plus-plus v1.3.5

* looser extension lib deps for concretization

* Apply suggestions from code review

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Address reviewer feedback

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-08-04 09:44:23 -05:00
Brian Van Essen
045c5cea53 Replace code that captures a recipes generator statement in the cached (#39192)
cmake build.
2023-08-04 05:38:12 -07:00
Alex Richert
ea256145d9 Add MET, METplus packages (#39238)
* Add metplus package
* Add met package
* add metplus develop version
* copyright year var/spack/repos/builtin/packages/met/package.py
* copyright year var/spack/repos/builtin/packages/metplus/package.py

---------

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-08-04 06:53:44 -04:00
Davide
0b2098850c julia: add v1.9.2 (#39269) 2023-08-04 10:53:59 +02:00
pabloaledo
d2df0a29ce salmon: update version (#39202)
* salmon: update version

---------

Signed-off-by: Pablo <pablo.aledo@seqera.io>
2023-08-03 17:57:17 -07:00
Vicente Bolea
92e9daec9b adios2: add 2.9.1 release (#39257) 2023-08-03 17:28:55 -04:00
Erik Schnetter
d65437114a openssl: Update to 3.1.2, 3.0.10, 1.1.1v (#39216) 2023-08-03 23:22:35 +02:00
Tamara Dahlgren
9a6e98e729 Revert checksum verification CI test (#39259) 2023-08-03 23:21:39 +02:00
Satish Balay
6515c16432 sowing: add version 1.1.26-p8 (#39258)
* sowing: add version 1.1.26-p8
* add in maintainer
2023-08-03 16:34:19 -04:00
Vanessasaurus
2826ab36f0 Automated deployment to update package flux-core 2023-08-03 (#39237)
Co-authored-by: github-actions <github-actions@users.noreply.github.com>
2023-08-03 11:07:41 -07:00
Mark W. Krentel
c035512930 hpcviewer: add version 2023.07 (#39236)
Add version 2023.07, adjust the line for deprecated (anything using
java 8 is now deprecated).
2023-08-03 10:52:58 -07:00
Stephen Sachs
cfadba47d3 patchelf@0.18.0 breaks intel compiler libraries (#39253) 2023-08-03 13:33:48 -04:00
Matthieu Dorier
95391dfe94 kafka: new versions (#39249)
* kafka: version 2.13-3.5.0
* kafka: version 2.13-3.5.1 and 2.13-3.4.1
2023-08-03 10:14:48 -07:00
Matthieu Dorier
382ba99631 librdkafka: version 2.2.0 (#39250) 2023-08-03 10:05:35 -07:00
Alec Scott
f8e25c79bf Add checksum CI test and verify with new versions for glab and gh (#39181) 2023-08-03 09:53:05 -07:00
Matthew Thompson
93b54b79d3 gftl-shared: new version 1.6.1 (#39217)
This PR adds gFTL-shared v1.6.1
2023-08-03 11:32:17 -04:00
Matthew Thompson
ff30efcebc mapl: add package (#39227)
* mapl: add package
* Fix style
2023-08-03 09:40:34 -04:00
Seth R. Johnson
54514682d4 py-sphinx-rtd-theme: avoid concretizing 0.5 with Sphinx 7.0 (#39212)
* py-sphinx-rtd-theme: avoid concretizing 0.5 with Sphinx 7.0

* Update var/spack/repos/builtin/packages/py-sphinx-rtd-theme/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-08-03 09:31:05 -04:00
Auriane R
92a75717f0 Add pika 0.17.0 (#39221) 2023-08-03 09:26:55 -04:00
Matthew Thompson
b9be8e883e pfunit: add versions 4.7.1, 4.7.2, 4.7.3 (#39218)
This adds the latest versions of pFUnit
2023-08-03 09:26:33 -04:00
Seth R. Johnson
da838a7d10 vecgeom: new version 1.2.5 (#39211)
* vecgeom: new version 1.2.5
* Mark previous versions as deprecated
* [@spackbot] updating style on behalf of sethrj
* vecgeom: fix 1.2.4 checksum for change to git describe
2023-08-03 08:59:41 -04:00
pabloaledo
85e5fb9ab7 ucsc-bedgraphtobigwig: add package (#39208)
Signed-off-by: Pablo <pablo.aledo@seqera.io>
2023-08-03 14:16:30 +02:00
Adam J. Stewart
c0c300d773 R: fix build on macOS arm64 (#39228) 2023-08-03 14:15:06 +02:00
Harmen Stoppels
6e933ac7df repo cache: use -inf default instead of 0 (#39214)
FastPackageChecker.modified_since should use a default number < 0

When the repo cache does not exist, Spack uses mtime 0. This causes the repo
cache not to be generated when the repo has mtime 0.

Some popular package managers such as spack use 0 mtime normalization for
reproducible tarballs. So when installing spack with spack from a buildcache, the
repo cache doesn't generate

Also add some typehints
2023-08-03 14:13:13 +02:00
pabloaledo
be679759be ucsc-bedclip: add package (#39209)
Signed-off-by: Pablo <pablo.aledo@seqera.io>
2023-08-03 14:04:37 +02:00
Adam J. Stewart
eace479b1e py-kornia: add v0.7.0 (#39233) 2023-08-03 13:59:31 +02:00
Harmen Stoppels
2069a42ba3 Buildcache commands cleanup, again... (#39203)
* Inform mypy that tty.die is noreturn

* avoid temporary allocation in env

* update spack buildcache save-specfile

* fix spack buildcache check/download/get-buildcache-name

- ensure that required args and mutually exclusive ones are marked as
  such in argparse for better error messages
- deprecate --spec-file everywhere
- use disambiguate for better error messages
2023-08-03 10:44:02 +02:00
George Young
41d2161b5b nextdenovo: new package @2.5.2 (and py-paralleltask) (#39139)
* py-paralleltask: new package @0.2.2

* adding hidden dependency

* nextdenovo: new package @2.5.2

* style

* Update var/spack/repos/builtin/packages/py-paralleltask/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-08-02 19:11:18 -04:00
mschouler
ba936574fc py-melissa-core: add new versions and py-iterative-stats dependency (#38654)
* py-melissa-core: add new versions and py-iterative-stats dependency

* Enhance dependency specification

* Fix dependency specification

* Fix comment alignment

* Improve dependency specification style

* Enhance dependencies

* Fix mpi4py, py-cloudpickle and py-python-hostlist dependencies

* Update var/spack/repos/builtin/packages/py-melissa-core/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-melissa-core/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-melissa-core/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Set develop version as preferred

* Update var/spack/repos/builtin/packages/py-melissa-core/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-08-02 17:46:50 -05:00
Stephen Hudson
c0d0603baa py-libEnsemble: add v0.10.2 (#39074)
* libEnsemble: add v0.10.2

* Make setuptools build only dep

* Update var/spack/repos/builtin/packages/py-libensemble/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-08-02 14:59:52 -05:00
Adam J. Stewart
edbf12cfa8 Add qmake virtual provider (#38848) 2023-08-02 13:50:37 -05:00
snehring
11b3dac705 openmolcas: adding version 23.06 (#39195) 2023-08-02 11:05:42 -07:00
pabloaledo
a7a5a994dc bioconductor-dupradar, bioconductor-rsubread: add packages (#39206)
* bioconductor-dupradar, bioconductor-rsubread: add packages
* [@spackbot] updating style on behalf of pabloaledo
2023-08-02 10:22:27 -07:00
pabloaledo
8a9a24ce1e tximeta: add package (#39207)
* tximeta: add package
  Signed-off-by: Pablo <pablo.aledo@seqera.io>
* [@spackbot] updating style on behalf of pabloaledo

---------

Signed-off-by: Pablo <pablo.aledo@seqera.io>
2023-08-02 10:16:21 -07:00
Harmen Stoppels
f54974d66e patchelf: 0.18 (#39215) 2023-08-02 09:54:31 -07:00
kwryankrattiger
0b4631a774 CI: Refactor ci reproducer (#37088)
* CI: Refactor ci reproducer

* Autostart container
* Reproducer paths match CI paths
* Generate start scripts for docker and reproducer

* CI: Add interactive and gpg options to reproduce-build

* Interactive will determine if the docker container persists
  after running reproduction.
* GPG path/url allow downloading GPG keys needed for binary
  cache download validation. This is important for running
  reproducer for protected CI jobs.

* Add exit_on_failure option to CI scripts

* CI: Add runtime option for reproducer
2023-08-02 09:51:12 -07:00
Harmen Stoppels
e7fa6d99bf version: move to module, avoid circular imports (#39077) 2023-08-02 17:47:08 +02:00
Harmen Stoppels
03c0d74139 buildcache extractall: extract directly into spec.prefix (#37441)
- Run `mkdirp` on `spec.prefix`
- Extract directly into `spec.prefix`
  1. No need for `$store/tmp.xxx` where we extract the tarball directly, pray that it has one subdir `<name>-<version>-<hash>`, and then `rm -rf` the package prefix followed by `mv`.
  2. No need to clean up this temp dir in `spack clean`.
  3. Instead figure out package directory prefix from the tarball contents, and strip the tarinfo entries accordingly (kinda like tar --strip-components but more strict)
- Set package dir permissions
- Don't error during error handling when files cannot removed
- No need to "enrich" spec.json with this tarball-toplevel-path

After this PR, we can in fact tarball packages relative to `/` instead of `spec.prefix/..`, which makes it possible to use Spack tarballs as container layers, where relocation is impossible, and rootfs tarballs are expected.
2023-08-02 17:06:13 +02:00
Wouter Deconinck
a14f4b5a02 feat: move -N/--namespace(s) to common args, allow in buildcache list (#36719)
`spack buildcache list` did not have a way to display the namespace of
packages in the buildcache. This PR adds that functionality.

For consistency's sake, it moves the `-N/--namespace` arg definition to
the `common/arguments.py` and modifies `find`, `solve`, `spec` to use
the common definition.

Previously, `find` was using `--namespace` (singular) to control whether
to display the namespace (it doesn't restrict the search to that
namespace). The other commands were using `--namespaces` (plural). For
backwards compatibility and for consistency with `--deps`, `--tags`,
etc, the plural `--namespaces` was chosen. The argument parser ensures
that `find --namespace` will continue to behave as before.

Co-authored-by: Harmen Stoppels <me@harmenstoppels.nl>
2023-08-02 11:16:14 +00:00
Alec Scott
3be565f49e rust: disable build from downloading a version of LLVM from Rust CI (#39146) 2023-08-02 12:35:52 +02:00
Adam J. Stewart
df2938dfcf Python: fix library/header error msg format (#39171) 2023-08-02 12:14:30 +02:00
Martin Aumüller
5d8482598b dcmtk: new version and pic configuration (#39161)
* dcmtk: checksum 3.6.7

compiles on macos

* dcmtk: support pic configuration

* [@spackbot] updating style on behalf of aumuell

* dcmtk: use define_from_variant for shorter code

* dcmtk: refine conflict

it appears that dcmtk < 3.6.7 only fails on macos/aarch64:
/Library/Developer/CommandLineTools/usr/lib/clang/14.0.3/include/xmmintrin.h:14:2:
  error: "This header is only meant to be used on x86 and x64 architecture"

---------

Co-authored-by: aumuell <aumuell@users.noreply.github.com>
2023-08-01 21:21:47 -07:00
Manuela Kuhn
f079e7fc34 py-gevent: add 23.7.0 and py-greenlet: add 3.0.0a1 (#39164)
* py-gevent: add 23.7.0 and py-greenlet: add 3.0.0a1

* Update var/spack/repos/builtin/packages/py-gevent/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Remove version 1.3.a2

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-08-01 18:21:40 -05:00
sid
3369acc050 py-openai, py-pandas-stubs (#38912)
* simple build of py-openai

* added variants to py-openai

* py-pandas-stubs is a dependency for py-openai

* fixed format and flake8 errors for py-openai

* black format error for py-pandas-stubs

* [@spackbot] updating style on behalf of sidpbury

* made style and format changes to py-openai

* made style and format changes to py-pandas-stubs

* py-types-pytz is a dependency for py-openai

* [@spackbot] updating style on behalf of sidpbury

* updated py-openpyxl for ver 3.0.7 and 3.1.2

* Update var/spack/repos/builtin/packages/py-pandas-stubs/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* ajs requested changes for py-openai

* updated py-openpyxl for supported python

* [@spackbot] updating style on behalf of sidpbury

* updated py-openpyxl

* removed requirement.txt dependencies in  py-openpyxl

* removed python depends on from openpyxl

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-08-01 17:35:41 -04:00
mschouler
26f4fc0f34 Add two latest versions (#39182)
Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
2023-08-01 15:35:55 -05:00
Weiqun Zhang
8c0551c1c0 amrex: add 23.08 (#39190) 2023-08-01 12:15:46 -07:00
Dax Lynch
59866cdb11 Mongodb: Add new package (#39085)
* Added the package

* added dependency

* Update package.py

* Update package.py

Added xz as a dependency
2023-08-01 10:25:16 -07:00
Chris White
8d2a32f66d remove CMAKE_GENERATOR from the host-config because it cannot be overwritten on the command line (#39044) 2023-08-01 08:57:56 -07:00
vucoda
b28ae67369 Fix source bootstrapping for Debian and derivatives (#39107)
* Fix Python package.py for Debian and derivatives to find the system Python library location

When bootstrapping from source, find_library() does not contain any paths that work for Debian and derivatives.  fixes #36666

* Update to pass styling

* Update to styling

* Update python package.py with fake config value for LIBPL

* Update python package.py libpl config_vars entry to follow double quote standard

* styling update
2023-08-01 03:42:46 -04:00
Satish Balay
b8590fbd05 petsc, py-petsc4py: add v3.19.4 (#39169) 2023-07-31 20:57:18 -05:00
Martin Aumüller
9343b9524f qt-base: add conflict for 6.5+ with GCC < 9 (#39158) 2023-07-31 18:36:16 -04:00
Adam J. Stewart
bb0cec1530 py-numpy: add v1.25.2 (#39172) 2023-07-31 16:58:07 -05:00
Alec Scott
d4f41b51f4 Add spack checksum --verify, fix --add (#38458)
* Add rewrite of spack checksum to include --verify and better add versions to package.py files
* Fix formatting and remove unused import
* Update checksum unit-tests to correctly test multiple versions and add to package
* Remove references to latest in stage.py
* Update bash-completion scripts to fix unit tests failures
* Fix docs generation
* Remove unused url_dict argument from methods
* Reduce chance of redundant remote_versions work
* Add print() before tty.die() to increase error readablity
* Update version regular expression to allow for multi-line versions
* Add a few unit tests to improve test coverage
* Update command completion
* Add type hints to added functions and fix a few py-lint suggestions
* Add @no_type_check to prevent mypy from failing on pkg.versions
* Add type hints to format.py and fix unit test
* Black format lib/spack/spack/package_base.py
* Attempt ignoring type errors
* Add optional dict type hint and declare versions in PackageBase
* Refactor util/format.py to allow for url_dict as an optional parameter
* Directly reference PackageBase class instead of using TypeVar
* Fix comment typo

---------

Co-authored-by: Tamara Dahlgren <dahlgren1@llnl.gov>
2023-07-31 21:49:43 +00:00
eugeneswalker
347acf3cc6 update py-cupy to enable ROCm builds and add variant to control optional dependencies (#38919)
* py-cupy updates: add +rocm and +all

* rocm deps are link only

* set parallelism for both +rocm and +cuda

* add missing deps; remove unnecessary deps; uncomment maintainers; get hipcc properly
2023-07-31 16:23:19 -05:00
Manuela Kuhn
65224ad6bc py-terminado: add 0.17.1 (#39165)
* py-terminado: add 0.17.1

* Fix style

* Update var/spack/repos/builtin/packages/py-terminado/package.py

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>

---------

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-07-31 14:22:00 -07:00
Andrey Perestoronin
784d56ce05 added new packages (#39166) 2023-07-31 15:38:33 -04:00
Martin Aumüller
b30523fdd8 libtiff: 4.5.1 (#39159) 2023-07-31 14:15:20 -05:00
Martin Aumüller
b46e098696 libgeotiff: new versions (#39160) 2023-07-31 14:14:44 -05:00
Manuela Kuhn
20a7622602 py-rdflib: add 6.3.2 (#39065)
* py-rdflib: add 6.3.2

* Update var/spack/repos/builtin/packages/py-rdflib/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Remove python dependency

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-31 13:50:00 -05:00
mschouler
d25f1059dd py-python-hostlist: package addition (#39035)
* Add recipe for py-hostlist

* Fix style

* Fix style

* Add homepage, fix version url and remove unnecessary dependency

* Fix version and remove url

* Rename package and fix git link

---------

Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
2023-07-31 12:39:56 -05:00
Adam J. Stewart
9394fa403e Remove Xcode mock-up (#39020)
* Remove Xcode mock-up

* Remove unused imports
2023-07-31 10:24:04 -07:00
Alec Scott
679c6a606d fzf: add v0.42.0 (#39150) 2023-07-31 09:55:48 -07:00
Adam J. Stewart
27f378601e py-lightning: add v2.0.6 (#39152) 2023-07-31 09:54:35 -05:00
Adam J. Stewart
832ddbdf6d py-sphinx: add v7.1 (#39151) 2023-07-31 09:54:10 -05:00
Martin Aumüller
0286455e1d libjpeg-turbo: checksum 2.1.5.1 & 3.0.0 (#39157) 2023-07-31 07:48:48 -07:00
Adam J. Stewart
4baf489460 py-lightly: add v1.4.14 (#39153) 2023-07-30 19:07:54 -07:00
Christopher Christofi
56c7921430 py-chex: add 0.1.5 (#39102) 2023-07-30 16:30:36 -05:00
Manuela Kuhn
c2288af55c py-csvkit: add 1.1.1 (#39124) 2023-07-30 16:28:33 -05:00
George Young
39cd2f3754 sourmash: new package @4.8.2 (#38571)
* sourmash: new package @4.8.2

* sourmash: new package @4.8.2

* py-bitarray: add 2.7.6, 2.7.4

* Update var/spack/repos/builtin/packages/py-bitstring/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update setuptools dependency

* Adding missing deps

* Update var/spack/repos/builtin/packages/sourmash/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Correcting maturin dep

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/sourmash/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/sourmash/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/sourmash/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Adding dependency types

* Add `@0.14.17` as the last pre-`@1:` release

* Switch to use `python_platlib`

* Update package.py

* Update var/spack/repos/builtin/packages/py-screed/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-30 16:13:25 -05:00
Adam J. Stewart
a941ab4acb PyPy: add new package (#38999)
* PyPy: add new package

* Typo fix

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>

---------

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-07-30 15:54:45 -05:00
Jordan Galby
048cc711d6 py-pytest-html: Add version 3.2.0 (#38989)
* py-pytest-html: add 3.2.0

* py-pytest-html: Add py-py version requirement

See https://github.com/pytest-dev/pytest-html/blob/v3.2.0/setup.py#L16

* py-pytest-html: Add dependencies from setup.py and pyproject.toml

* py-pytest-html: Add git url

* py-pytest-html: Add conflict with py-pytest@7.2: pending py-pytest-html@4
2023-07-30 15:01:00 -05:00
Tamara Dahlgren
63a5cf78ac Bugfix/ltrace: Add missing elf dependency (#39143) 2023-07-29 23:02:00 -07:00
Filippo Spiga
bef03b9588 Adding NVIDIA HPC SDK 23.7 (#39127) 2023-07-28 18:48:06 -04:00
dslarm
2859f0a7e1 HACCKernels git repository has changed URL. Updating. (#39129) 2023-07-28 16:33:52 -04:00
afzpatel
c1b084d754 Adding optional hip test (#34907)
* Adding optional hip test
* Modifications to run every samples test
* Skipping test directories without a Makefile
* fix styling and cleaning code
* fix styling and changed method of itterating through sample folders
* changed to new syntax for standalone tests
* Updates for changes in syntax
2023-07-28 10:10:29 -07:00
Julien Bigot
a8301709a8 libffi: add -Wno-error=implicit-function-declaration for clang >= 16 (#38356) 2023-07-28 10:18:12 -04:00
Fabien Bruneval
ad0b70a64a MOLGW package: fix dependence to threaded MKL (#39028)
* molgw package.py

* molgw package.py almost ready

* bug fix in molgw package.py

* MOLGW v3.2

* black pass

* duplicated line eliminated

* remove FIXME in the header

* add me as a maintainer

* fix previous commit

* sort the imports in the order spack wants

* chop the too-long lines

* many fixes

- variants before dependences
- eliminate useless build and install stages
- no openmp with intel-mkl was broken

* after blackization

* cleaning

* Update var/spack/repos/builtin/packages/molgw/package.py

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>

* Update var/spack/repos/builtin/packages/molgw/package.py

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>

* Update var/spack/repos/builtin/packages/molgw/package.py

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>

* Update var/spack/repos/builtin/packages/molgw/package.py

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>

* Update var/spack/repos/builtin/packages/molgw/package.py

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>

* use threaded mkl when openmp is triggered

---------

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-07-28 08:30:27 -04:00
Matthias Wolf
b5444e4304 py-distributed: add missing tblib dependency. (#39123)
I noticed this as we run a `pip check` on all modules we generate. This
dependeny seems to have been around for a long time:

https://github.com/dask/distributed/blob/2020.12.0/requirements.txt#L8
https://github.com/dask/distributed/blob/2023.4.1/pyproject.toml#L39

While it does not seem essential, it would be nice to have consistent
installations by including the missing dependency.
2023-07-28 05:42:35 -04:00
Michael Kuhn
e1d5d34b56 gcc: add 13.2.0 (#39119) 2023-07-28 10:36:07 +02:00
Brian Van Essen
e5b4607548 Added support for building with Caliper (#39116) 2023-07-27 13:59:11 -07:00
Brian Van Essen
ecdd8e035c Added the import of the regex package (#39117) 2023-07-27 13:53:40 -07:00
snehring
9d9e4a52f5 tecio: adding new package tecio (#39099) 2023-07-27 12:26:25 -07:00
Aiden Grossman
9e0629213c lm-sensors: respect compiler choice (#38890)
Currently lm-sensors defaults to the compiler specified in the Makefile
(gcc) rather than the one specified in the spec. This patch appends the
CC flag to the make invocation with the spec compiler to fix this
behavior.
2023-07-27 19:58:21 +02:00
Matthieu Dorier
51fa4e5fc4 mochi-margo: added version 0.14.1 (#39110) 2023-07-27 10:17:08 -07:00
Sreenivasa Murthy Kolam
8908b7584e Updates to rocm recipes for rocm-5.5.0 and rocm-5.5.1 releases (#37910)
* initial commit for rocm-5.5.0 release
* fix the hipsparse  build error for 5.5.0
* fix build error for amrex .add hiprand as a dependency
* modify the patch for rocprofiler-dev
* add hiprand for +rocm build
* initial commit for rocm-5.5.1 release
* bump up the version for rocm-5.5.1 release.
* bump up the version for rocmlir.miopen to use this backend only till 5.5
* add new recipe py-barectf and add it as dependency for rocprofiler-dev
* revert the changes for rocprofiler-dev for 5.5.0/1 for now as it depends
  on hsa-amdaqlprofile.so which is a closed source and no spack recipe is
  available for now.
* add rocm-core as dependency for rocm packages from 5.5.0 onwards
* avoid download of the gtest for building unit tests
2023-07-27 09:42:17 -07:00
Aiden Grossman
936c6045fc ROCm packages: remove build type variants (#39089)
After #36679, the default build type is Release, so there is no need to
explicitly set the build type as a custom variant.
2023-07-27 08:08:59 +02:00
David Boehme
ca2e9cf090 Caliper: Add variorum variant (#39104) 2023-07-26 19:22:36 -04:00
Gerhard Theurich
288b3c3ec2 esmf: add v8.5.0 (#39100) 2023-07-26 16:08:03 -07:00
David Boehme
31bb259a12 Add Caliper v2.10.0 (#39103) 2023-07-26 16:05:08 -07:00
Konstantinos Parasyris
a74dd96773 Adds AMS package.py (#39083)
Co-authored-by: koparasy <parasyris1@llnl.com>
Co-authored-by: Loic Pottier <pottier1@llnl.gov>, Tom Stitt <stitt4@llnl.gov>
2023-07-26 15:59:38 -07:00
Matthieu Dorier
9594fb47e1 mruby: added mruby package (#39093)
* mruby: added mruby package
* mruby: replaced / with os.path.join
* mruby: improving style
* mruby: improving style again
2023-07-26 10:06:16 -07:00
Matt Drozt
62cfe1ab47 Create a package for the redis ai module (#39096) 2023-07-26 12:58:25 -04:00
Rob Falgout
8c417b3ccc Update package.py for new hypre release 2.29.0 (#38537) 2023-07-26 11:57:30 -05:00
Gurkirat Singh
52c0127fc7 Implement odgi package (#39078)
* feature (packages): implement `odgi` package
  This commit re-implements odgi package (superseded by #38741)
* fix (packages): remove redundant `requires()` from odgi package
  This commit removes redundant use of `requires()` for gcc version in the `odgi` package
2023-07-26 09:38:41 -07:00
Scott Wittenburg
2c74b433aa ci: Make signing requirement explicit (#38995)
Instead of inferring whether to sign binaries, make it explicit,
and fail rebuild jobs early if signing is required but cannot be
accomplished.
2023-07-26 09:16:15 -06:00
Aiden Grossman
8bdfaf4ae5 libelf: fix build with clang16+ (#38915)
libelf fails to build with clang16+ due to Wimplicit-int and
Wimplicit-function-declarations becoming errors by default. This breaks
the configuration stage, so no build takes place. This patch fixes this
by passing -Wno-error=implicit-int and
-Wno-error=implicit-function-declarations as cflags.
2023-07-26 16:46:37 +02:00
Aiden Grossman
eb19f59fb1 llvm: remove build type comment (#39087)
The message is now outdated after
https://github.com/spack/spack/pull/36679 which could lead to some
confusion.
2023-07-26 16:39:10 +02:00
Aiden Grossman
856834537a gcoff: fix build with clang 16+ (#38914)
gcoff uses the register keyword in a couple different places which
causes errors when building with c++17, which is the default in clang
16. This patch adds the -Wno-register flag to ignore these errors when
when building with clang 16.
2023-07-26 16:34:07 +02:00
Aiden Grossman
fba019f0be unzip: fix build with clang16+ (#38899)
Clang 16's change to erroring out by default on implicit function
declarations and implicit integers causes the build script for unzip to
break. Since this project hasn't had a release since 2010, we need to
patch it downstream/pass additional flags to get the build to succeed.
2023-07-26 16:33:48 +02:00
Aiden Grossman
cc0ac7093b hdf: fix build with clang16+ (#38888)
With the release of clang 16, clang now treats implicit function
declarations and implicit integers as errors rather than warnings,
causing the build to fail. This patch adds flags to prevent build
failures.
2023-07-26 16:29:37 +02:00
Mikael Simberg
711d67090a Add newer versions of mimalloc (#39091) 2023-07-26 13:42:24 +02:00
Ken Raffenetti
5ce667de6a mpich: add 4.1.2 release (#39084) 2023-07-26 00:02:55 -04:00
Michael Kuhn
a77e6ea639 pmix: add 4.2.4 and disable munge explicitly (#39018) 2023-07-25 11:00:35 -07:00
fpruvost
3a661803ce Update pastix v6.3.0 (#39076) 2023-07-25 09:23:44 -07:00
Alex Richert
c6ed2227f2 Add w3emc 2.10.0 and update variants, run env logic (#39075) 2023-07-25 09:22:03 -07:00
Bruno Turcksin
bd9f8ba094 Kokkos: add release 4.1.0 (#38641)
* Add Kokkos 4.1.0 release

* Add -fp-model=precise flag when using SYCL

* Fix sycl flag

Co-authored-by: Robert Cohn <rscohn2@gmail.com>

---------

Co-authored-by: Robert Cohn <rscohn2@gmail.com>
Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-07-24 17:02:56 -07:00
Satish Balay
c7b849bdee xsdk: remove version 0.6.0, also remove corresponding xsdk-examples@0.2.0 (#39000) 2023-07-24 16:24:56 -07:00
Sergey Kosukhin
3f4012cf44 netcdf-fortran: add version 4.6.1 and fix the checks (#39043)
* netcdf-fortran: add version 4.6.1
* netcdf-fortran: fix the 'check' method
2023-07-24 15:54:18 -07:00
Alec Scott
e3b2e5b2cd bfs: add new package (#39057)
* bfs: add new package
* Remove redundant set to PREFIX during build
2023-07-24 15:50:27 -07:00
Matthieu Dorier
b2ed10dd83 quickjs: make Makefile use correct compiler (#39060)
* quickjs: make Makefile use correct compiler
* added lto variant and better handling of compilers
* quickjs: correct style
* quickjs: correct style for flake8
2023-07-24 15:45:21 -07:00
ajpowelsnl
1c3dc0bd5f openmpi: add openshmem variant (#39067) 2023-07-24 15:38:38 -07:00
Briffou
f28a2ccee2 mgis: add new variant for static libraries (#38917)
Co-authored-by: Thomas Briffard <thomas.briffard@michelin.com>
2023-07-24 15:34:31 -07:00
Scott Wittenburg
12d86ffb6a ci: fix stack mirror urls (#38882) 2023-07-24 20:20:08 +00:00
eugeneswalker
fde1954c13 mvapich2@2.3.7-1: add torque patch (#39027) 2023-07-24 12:56:32 -07:00
Jonathon Anderson
3ad65bbfc1 Always set workflow:rules in spack ci pipelines (#38921) 2023-07-24 14:31:39 -05:00
Chris White
f017f586df add conflict for +parmetis when ~mpi (#39050) 2023-07-24 10:54:18 -07:00
Ashwin Kumar Karnad
399271832b Fix typo: binary_caches.rst (#39064) 2023-07-24 15:09:34 +02:00
Harmen Stoppels
4bcceddba9 Don't add .spack/binary_distribution twice to the tarball when re-distributing (#39042)
Previously, spack would list the ./spack/binary_distribution file twice when pushing
a package that was installed from a binary tarball itself.
2023-07-24 14:39:37 +02:00
Harmen Stoppels
0fff219aa4 Fix broken sanitize_file_path (#38926)
The sanitization function is completely bogus as it tries to replace /
on unix after ... splitting on it. The way it's implemented is very
questionable: the input is a file name, not a path. It doesn't make
sense to interpret the input as a path and then make the components
valid -- you'll interpret / in a filename as a dir separator.

It also fails to deal with path components that contain just unsupported
characters (resulting in empty component).

The correct way to deal with this is to have a function that takes a
potential file name and replaces unsupported characters.

I'm not going to fix the other issues on Windows, such as reserved file
names, but left a note, and hope that @johnwparent can fix that
separately.

(Obviously we wouldn't have this problem at all if we just fixed the
filename in a safe way instead of trying to derive something from
the url; we could use the content digest when available for example)
2023-07-24 12:30:47 +02:00
Mosè Giordano
ac3c0a4347 mvapich2: Add patch to avoid segmentation fault in MPIR_Attr_delete_list (#39058) 2023-07-22 21:44:15 -07:00
Adam Fidel
cc2fa9895e mtn: add mtn package (#39053) 2023-07-22 17:45:54 -07:00
Michael Kuhn
fb83c7112e Fix pkgconfig dependencies (#39059)
pkg-config and pkgconf are providers.
2023-07-22 17:20:30 -07:00
Christopher Christofi
c811b71336 py-jaxlib: add conflict for missing cuda cuda_arch value (#39054)
* py-jaxlib: add conflict for missing cuda cuda_arch specification

* Update var/spack/repos/builtin/packages/py-jaxlib/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* py-jaxlib: conflict missing cuda_arch value when with cuda

* Update var/spack/repos/builtin/packages/py-jaxlib/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-22 12:27:49 -04:00
eugeneswalker
366c798b87 e4s oneapi ci: build with latest 2023.2 based image (#39048) 2023-07-22 09:22:02 -07:00
百地 希留耶
90ac0ef66e Implement fish completion (#29549)
* commands: provide more information to Command

* fish: Add script to generate fish completion

* fish: auto prepend `spack` command to avoid duplication

* fish: impove completion generation code readability

* commands: replace match-case with if-else

* fish: fix optspec variable name prefix

* fish: fix return value in get_optspecs

* fish: fix return value in get_optspecs

* format: split long line and trim trailing space

* bugfix: replace f-string with interpolation

* fish: compete more specs and some fixes

* fish: complete hash spec starts with /

* fish: improve compatibility

* style: trim trailing whitespace

* commands: add fish to update args and update tests

* commands: add fish completion file

* style: merge imports

* fish: source completion in setup-env

* fish: caret only completes dependencies

* fish: make sure we always get same order of output

* fish: spack activate
only show installed packages that have extensions

* fish: update completion file

* fish: make dict keys sorted

* Blacken code

* Fix bad merge

* Undo style changes to setup-env.fish

* Fix unit tests

* Style fix

* Compatible with fish_indent

* Use list for stability of order

* Sort one more place

* Sort more things

* Sorting unneeded

* Unsort

* Print difference

* Style fix

* Help messages need quotes

* Arguments to -a must be quoted

* Update types

* Update types

* Update types

* Add type hints

* Change order of positionals

* Always expand help

* Remove shared base class

* Fix type hints

* Remove platform-specific choices

* First line of help only

* Remove unused maps

* Remove suppress

* Remove debugging comments

* Better quoting

* Fish completions have no double dash

* Remove test for deleted class

* Fix grammar in header file

* Use single quotes in most places

* Better support for remainder nargs

* No magic strings

* * and + can also complete multiple

* lower case, no period

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-22 08:55:12 -05:00
Mark Olesen
66e85ae39a openfoam: add versions 2306, 2212_230612 (patch), 2212 (#38694)
* openfoam: add versions 2306, 2212_230612 (patch), 2212

* Fix syntax error

---------

Co-authored-by: Mark Olesen <Mark.Olesen@esi-group.com>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-22 02:52:55 -04:00
Manuela Kuhn
54fdae4a79 py-sqlalchemy: add 2.0.19 (#38951)
* py-sqlalchemy: add 2.0.19

* [@spackbot] updating style on behalf of manuelakuhn

* Add py-cython and py-greenlet and fix dependency type

* Fix typo
2023-07-21 23:41:00 -05:00
Zach Jibben
b215bb41dd Update Truchas (#39026) 2023-07-21 16:07:32 -07:00
Elliott Slaughter
b85803ae6c legion: Update Python dependencies. Fix variant requirements. Remove TLS. (#39003)
* legion: Missing Python dependency. Fix variant dependencies. Remove TLS.

* Update Python version bound and add NumPy dependency.

* Update requires syntax.
2023-07-21 13:59:04 -07:00
Matthieu Dorier
c5c75e8921 quickjs: add quickjs package (#39041)
* added quickjs package

* edited style of quickjs package
2023-07-21 12:50:10 -07:00
Manuela Kuhn
9c5ae722b2 py-isort: add 5.12.0 and fix build of 5.10.1 (#39033) 2023-07-21 14:06:40 -05:00
Martin Aumüller
132bb59be8 qt-*: update for 6.5.2 (#39038) 2023-07-21 10:38:11 -04:00
Massimiliano Culpo
c0b42151c3 Remove spack.repo.IndexError (#39029)
This exception is never used and
overrides a built-in.
2023-07-21 15:33:30 +02:00
Mosè Giordano
c1be7f2354 julia: Update hashes of github-generated patch files (#39034) 2023-07-21 15:32:36 +02:00
eugeneswalker
4edeabb2a2 e4s ci: add cray-sles ministack (#38744)
* e4s ci: add cray-sles ministack

* fix typo: variables, not env
2023-07-21 05:57:27 -07:00
Ashwin Kumar Karnad
405f563909 binary_caches.rst: fix typo (#39030) 2023-07-21 10:39:53 +02:00
Adam J. Stewart
089d775cf2 py-mpi4py: does not yet support cython 3 (#38996) 2023-07-20 19:13:16 -04:00
Martin Aumüller
6610b8bc27 proj: fix build of v7 with GCC 13 & add 9.2.1 (#39004)
* proj: fix building with GCC 13

apply upstream patch from 7.2 branch

* proj: checksum 9.2.1

* proj: fix sha256 of patch

thank you, @adamjstewart
2023-07-20 17:44:13 -04:00
mschouler
d3c4b74095 Add recipe for py-plotext (#39023)
Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
2023-07-20 16:43:38 -05:00
Samuel K. Gutiérrez
26a74bb3bc Add Quo-Vadis package. (#38998)
Signed-off-by: Samuel K. Gutierrez <samuel@lanl.gov>
2023-07-20 12:07:36 -07:00
Sergey Kosukhin
d2566e3d62 nag: update the versioning scheme (#35457)
* nag: append build number to the version
* nag: add version 7.1.7125
* nag: deprecate unavailable versions
2023-07-20 12:03:26 -07:00
willdunklin
3fbe5dd312 sensei: add version 4.1.0 (#38959) 2023-07-20 13:48:27 -05:00
Manuela Kuhn
d1ea315e57 serf: add 1.3.10 (#38847) 2023-07-20 11:37:41 -07:00
Tom Scogland
0bef599c21 update luajit and fix link on neovim to allow luajit to work on linux aarch64 (#38865) 2023-07-20 11:36:12 -07:00
Dmitriy
d1d2d76183 Add boost variant to henson and require it for aarch64 (#38916) 2023-07-20 11:29:18 -07:00
Rocco Meli
294d81e99e Update GNINA and libmolgrid (#38978)
* pin protobuf
* explicitly select python interpreter
* remove python pin
2023-07-20 11:14:06 -07:00
Martin Aumüller
22d2ef3d5a botan: checksum 3.1.0 and 3.1.1 (#39006) 2023-07-20 11:01:58 -07:00
Hariharan Devarajan
e087f3bf93 release gotcha 1.0.4 (#39007) 2023-07-20 10:59:52 -07:00
Martin Aumüller
ebdaa766ae tinygltf: new versions and add release branch (#39012)
* tinygltf: new versions and release branch
   for each minor release available, the newest patch release has been added

---------

Co-authored-by: aumuell <aumuell@users.noreply.github.com>
2023-07-20 10:56:14 -07:00
Martin Aumüller
a87ee7f427 qt: make partially buildable on macos (#38990)
- drop use_xcode = True, as this would lead to an attempt install Xcode (#34064)
- don't automatically build Qt Location with +opengl, as this is
  still broken

This built sucessfully with qt@5.15.10+opengl+dbus+phonon on ventura/arm without
Xcode installed (only command line tools) - I did not check with Xcode installed.
2023-07-20 11:53:38 -05:00
Adam J. Stewart
4f0020c794 py-lightly: add v1.4.13 (#39019) 2023-07-20 09:50:24 -07:00
Jen Herting
b23c6f2851 [py-wasabi] added version 1.1.2 (#38268)
* [py-wasabi] added version 1.1.2

* [py-wasabi] flake8

* [py-wasabi]

- added dependency on py-colorama
- updated homepage

* [py-wasabi] removed python check for py-colorama

* [@spackbot] updating style on behalf of qwertos

---------

Co-authored-by: qwertos <qwertos@users.noreply.github.com>
2023-07-20 11:14:58 -05:00
Manuela Kuhn
81f9910c26 py-stack-data: add 0.6.2 (#38952) 2023-07-20 11:03:56 -05:00
Jen Herting
b40e3898b4 [py-omegaconf] added version 2.2.2 (#38980) 2023-07-20 10:54:30 -05:00
Massimiliano Culpo
50b90e430d spack.util.lock: add type-hints, remove **kwargs in method signatures (#39011) 2023-07-20 09:41:23 +02:00
Massimiliano Culpo
3a565c66e9 Respect custom user store when bootstrapping (#39001)
The user store is lazily evaluated. The change
in #38975 made it such that the first evaluation
was happening in the middle of swapping to user
configuration.

Ensure we construct the user store before that.
2023-07-19 19:53:33 -04:00
Joe Schoonover
01167a1471 Add new feq-parse version (#38991)
* Add new feq-parse version
* Swap 2.0.0 for 2.0.1 - resolves feq-parse build failure
2023-07-19 19:33:05 -04:00
Alberto Sartori
3caa0093f8 justbuild: add v1.1.4 (#38985) 2023-07-19 13:27:54 -07:00
Xavier Delaruelle
d9fbdfbee9 modules: use curly braces to enclose value in Tcl modulefile (#38375)
Use curly braces instead of quotes to enclose value or text in Tcl
modulefile. Within curly braces Tcl special characters like [, ] or $
are treated verbatim whereas they are evaluated within quotes.

Curly braces is Tcl recommended way to enclose verbatim content [1].

Note: if curly braces charaters are used within content, they must be
balanced. This point has been checked against current repository and no
unbalanced curly braces has been spotted.

Fixes #24243

[1] https://wiki.tcl-lang.org/page/Tcl+Minimal+Escaping+Style
2023-07-19 17:57:37 +02:00
Jen Herting
ae08b25dac [py-openapi-schema-pydantic] New package (#38973) 2023-07-19 15:26:55 +02:00
Jen Herting
9ccb018b23 [py-langsmith] New package (#38971) 2023-07-19 15:21:57 +02:00
Harmen Stoppels
185bccb70f Fetch & patch: actually acquire stage lock, and many more issues (#38903)
* Fetching patches wouldn't result in acquiring a stage lock during install
* The installer would acquire a stage lock *after* fetching instead of
   before, leading to races
* The name of the stage for patches was random, so on build failure
   (where stage dirs are not removed), these directories would continue
   to exist after a second successful install.
* There was this redundant "composite fetch" object -- there's already
   a composite stage. Remove this.
* For some reason we do *double* shasum validation of patches, before
   and after compression -- that's just too much? I removed it.
2023-07-19 15:06:56 +02:00
Jen Herting
8c8186c757 [py-uc-micro-py] New package (#38967) 2023-07-19 14:19:45 +02:00
Jen Herting
8a76430039 [py-pydub] new package (#38966) 2023-07-19 14:07:31 +02:00
Jen Herting
33939656e2 [py-hatch-requirements-txt] new package (#38965) 2023-07-19 14:03:21 +02:00
Jen Herting
950b5579fb [py-ffmpy] New package (#38964) 2023-07-19 14:00:31 +02:00
Jen Herting
d996b4d240 [py-colorama] added version 0.4.6 (#38737)
* [py-colorama] added version 0.4.6

* [py-colorama] limited py-setuptools dependency
2023-07-19 13:51:25 +02:00
Harmen Stoppels
886946395d drop redundant rpaths post install (#38976)
Spack heuristically adds `<install prefix>/lib` and `<install prefix>/lib64` as rpath entries, as it doesn't know what the install dir is going to be ahead of the build. This PR cleans up non-existing, absolute paths[^1], which

1. avoids redundant stat calls at runtime
2. drops redundant rpaths in `patchelf`, making it relocatable -- you don't need patchelf recursively then.

[^1]: It also removes relative paths not starting with `$` (so, `$ORIGIN/../lib` is retained -- we _could_ interpolate `$ORIGIN`, but that's hard to get right when symlinks have to be taken into account). Relative paths _are_ supported in glibc, but are relative to _the current working directory_, which is madness, and it would be better to drop those paths.
2023-07-19 09:48:31 +00:00
Adam J. Stewart
57b69c9703 py-cython: add v3.0.0 (#38961) 2023-07-19 11:24:35 +02:00
Massimiliano Culpo
f34c93c5f8 llnl.util.lock: add type-hints (#38977)
Also uppercase global variables in the module
2023-07-19 11:23:08 +02:00
Massimiliano Culpo
a7f2abf924 Remove LazyReference from code (#38944)
A LazyReference object is a reference to an attribute of a 
lazily evaluated singleton. Its only purpose is to let developers
use shorter names to refer to such attribute.

This class does more harm than good, as it obfuscates the fact
that we are using the attribute of a global object. Also, it can easily
go out of sync with the singleton it refers to if, for instance, the
singleton is updated but the references are not.

This commit removes the LazyReference class entirely, and access
the attributes explicitly passing through the global value to which
they are attached.
2023-07-19 11:08:51 +02:00
Aiden Grossman
a99eaa9541 magma: add package name to conflict messages (#38984)
Without the package name being present in the conflict messages, it is
significantly more difficult to debug concretization failures in
environments that contain many packages.
2023-07-19 03:47:26 -04:00
downloadico
76b6436ade petsc: add version 3.19.3 (#38974) 2023-07-19 08:32:58 +02:00
Emil Briggs
0facda31eb rmgdft: add v5.3.1, v5.4.0 and cuda variant (#37813)
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-07-19 08:30:37 +02:00
Aiden Grossman
032fd38af0 mesa-glu: Patch register long to long (#38833)
mesa-glu still has a couple instances of the register keyword which
causes build failures with clang on my platform. This patch removes the
register keyword which doesn't have any impact on correctness.
2023-07-19 08:29:24 +02:00
Aiden Grossman
b04b3aed9e gperf: patch usage of register keyword (#38893)
gperf still uses the register keyword in one place which makes
compilation fail with c++17. This patch adds in a patch file to remove
the usage of the reigster keyword so that it compiles properly.
2023-07-19 08:28:57 +02:00
Aiden Grossman
90b2e402f5 elfutils: remove conflicts with clang after version 0.186 (#38945)
In late 2021 elfutils was patched to make it build with clang, and these
patches ended up in version 0.186. This commit updates the conflicts to
specify this so elfutils can be built with clang.
2023-07-19 08:28:13 +02:00
Carlos Bederián
1f17f44def amdfftw: turn conflicts into conditional variants (#38221) 2023-07-19 08:23:40 +02:00
Sebastian Grimberg
cf87d9f199 palace: fix bugs introduced in #38910 (#38983) 2023-07-19 07:21:06 +02:00
Rocco Meli
d7a1a61702 Improve RDKit package (#36566) 2023-07-18 20:57:55 -04:00
markus-ferrell
416edfa229 Windows testing: enable tests for installer components (#36970)
These tests now work without any changes to core. Furthermore, it is
surprising that they had to be disabled (at least, as long as the
installer.py tests are run on Windows: these tests are more-basic
and their functionality would have been exercised automatically).
2023-07-18 16:19:14 -07:00
Sebastian Grimberg
9beb02ea83 palace: add v0.11.2 (#38910) 2023-07-18 22:29:35 +00:00
Manuela Kuhn
ce4162e28b py-poetry-core: add 1.6.1 and fix url (#38452)
* py-poetry-core: add 1.6.1 and fix url

* Update var/spack/repos/builtin/packages/py-poetry-core/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Re-add python upper bound for older versions

* Update var/spack/repos/builtin/packages/py-poetry-core/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-18 18:10:14 -04:00
Massimiliano Culpo
14f3297cca Ensure the bootstrap store has a padding length of zero (#38975)
Without this PR, padded length was propagating from user configuration to
bootstrap configuration, and was causing the issue reported in #38963
2023-07-18 23:49:22 +02:00
markus-ferrell
f24f98a1e2 Windows testing: enable bootstrap test (#36972) 2023-07-18 14:42:26 -07:00
Julien Loiseau
64361e1fc7 FleCSPH: update package (#37888)
Co-authored-by: Richard Berger <richard.berger@outlook.com>
2023-07-18 23:06:36 +02:00
Aiden Grossman
9a05dce3bf fftw: fix build with clang15+ (#38889)
In Clang 15, -Wint-conversion became an error instead of a warning,
breaking the fftw build for clang versions > 15. This patch fixes fftw
builds with clang 15+ by passing -Wno-error=int-conversion as a cflag.
2023-07-18 23:02:51 +02:00
markus-ferrell
ffc283ab8b test_clear_failures_success: run on Windows too (#36792) 2023-07-18 22:42:57 +02:00
Harmen Stoppels
3fef586cfb binary cache docs: remove redundant flag and comment (#38960) 2023-07-18 22:38:04 +02:00
eugeneswalker
515b53ac50 e4s cray: expand spec list (#38947)
* e4s cray: expand spec list

* unzip: require %gcc

* remove datatrasnferkit
2023-07-18 20:04:26 +00:00
markus-ferrell
b710778bda Windows testing: enable architecture test (#36973)
Works out of the box: remove skip.
2023-07-18 12:33:52 -07:00
markus-ferrell
a965fe9354 Windows testing: enable "spack clean" tests (#36840)
They work out out of the box on windows. Simply removing skips.
2023-07-18 12:25:32 -07:00
fpruvost
e47a2a7a65 chameleon: update to version 1.2.0 (#38936) 2023-07-18 12:57:42 -04:00
Harmen Stoppels
5b23c5dcc0 buildcache push: make --allow-root the default and deprecate the option (#38878)
Without --allow-root spack cannot push binaries that contain paths in
binaries. This flag is almost always needed, so there is no point of
requiring users to spell it out. 

Even without --allow-root, rpaths would still have to be patched, so the 
flag is not there to guarantee binaries are not modified on install.

This commit makes --allow-root the default, and drops the code 
required for it. It also deprecates `spack buildcache preview`, since 
the command made sense only with --allow-root.

As a side effect, Spack no longer depends on binutils for relocation
2023-07-18 18:45:14 +02:00
Massimiliano Culpo
ad1fdcdf48 Pin Spack dev dependencies on RtD (#38950) 2023-07-18 18:37:04 +02:00
Massimiliano Culpo
82aa27f5a5 Fix default construction of locks (#38953)
This fixes a typo introduced in a refactor
2023-07-18 14:36:41 +02:00
Taillefumier Mathieu
909f185f02 Update dbcsr and cp2k to latest version (#38939)
Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>
2023-07-18 11:48:42 +02:00
Xavier Delaruelle
8c7adbf8f3 modules: add support for conflict in lua modulefile (#36701)
Add support for conflict directives in Lua modulefile like done for Tcl
modulefile.

Note that conflicts are correctly honored on Lmod and Environment
Modules <4.2 only if mutually expressed on both modulefiles that
conflict with each other.

Migrate conflict code from Tcl-specific classes to the common part. Add
tests for Lmod and split the conflict test case in two.

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-07-18 10:24:46 +02:00
Peter Scheibel
10165397da "spack develop": always pull full history for git repos (#38343) 2023-07-18 09:53:33 +02:00
Houjun Tang
af60b802f7 Update package.py (#38946) 2023-07-18 03:17:48 -04:00
Rocco Meli
4e8f91a0c7 wannier90 github (#38927) 2023-07-17 23:52:38 -07:00
Michael Kuhn
7b87f0a569 meson: add 1.2.0, 1.1.1 and 1.0.2 (#38935) 2023-07-17 23:50:39 -07:00
Andrey Perestoronin
377fecd86f added new packages (#38941) 2023-07-18 00:47:46 -04:00
David Huber
2c7df5ce35 Update gsi-ncdiag/1.1.1 sha256 (#38943) 2023-07-18 00:12:43 -04:00
Manuela Kuhn
3bcd1a6c0e py-soupsieve: add 2.4.1 (#38929) 2023-07-17 17:48:27 -05:00
Manuela Kuhn
a468ca402e py-setuptools: add 68.0.0 (#38930)
* py-setuptools: add 68.0.0

* [@spackbot] updating style on behalf of manuelakuhn
2023-07-17 17:47:08 -05:00
Manuela Kuhn
ecb9d35cd4 py-setuptools-rust: add 1.6.0 (#38932) 2023-07-17 17:46:03 -05:00
Manuela Kuhn
d7b2f9d756 py-sphinxcontrib-applehelp: add 1.0.4 (#38933) 2023-07-17 17:44:32 -05:00
Manuela Kuhn
8c303cd29a py-sphinxcontrib-htmlhelp: add 2.0.1 (#38934) 2023-07-17 17:43:37 -05:00
Dan Lipsa
4831d45852 Decompression: fix naming issues (#37749)
* When using system tools to unpack a .gz file, the input file needs a
  different name than the output file. Normally, we generate this new
  name by stripping off the .gz extension off of the file name.
  This was not sufficient if the file name did not have an extension,
  so we temporarily rename the file in that case.
* When using system tar utility to untar on Windows, we were (erroneously)
  skipping the actual untar step if the filename was lacking a .tar
  extension
* For foo.txz, we were not changing the extension of the decompressed file
  (i.e. we would decompress foo.txz to foo.txz). This did not cause any
  problems, but is confusing, so has been updated such that the output
  filename reflects its decompressed state (i.e. foo.tar).
* Added test for strip_compression_extension
* Update test_native_unpacking to test each archive type with and without
  an extension as part of the file name (i.e. we test "foo.tar.gz", but
  also make sure we decompress properly if it is named "foo").
2023-07-17 14:33:18 -07:00
Harmen Stoppels
f05837a480 Fix wrong StageComposite keep override (#38938)
`Stage(keep=True)` was ignored when put in a composite that doesn't
override the value.
2023-07-17 23:20:24 +02:00
Manuela Kuhn
1fa60a6c70 py-pyside: fix build with python3.8 (#38886)
* py-pyside: fix build for version 1.2.2

* Remove check for python version

* Fix style

* Remove unnecessary patch

* Update var/spack/repos/builtin/packages/py-pyside/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-pyside/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Remove py-markupsafe conflict

* Update var/spack/repos/builtin/packages/py-pyside/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-pyside/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Move python check removal below suprocess patch

* Remove preference of 1.2.2

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-17 15:54:59 -05:00
snehring
1730bcaa31 soapdenovo2: strip optimization flags from injected flags (#38846)
* soapdenovo2: strip optimization flags from injected flags
* soapdenovo2: add maintainer
* soapdenovo2: only append on cflags
* soapdenovo2: clean up some wording and implementation
2023-07-17 13:33:37 -07:00
Alberto Sartori
e6235a8ff9 justbuild: add v1.1.3 (#38925) 2023-07-17 13:23:14 -07:00
Manuela Kuhn
884b4952af Fix python import tests (#38928)
Running `spack test run <python package>` resulted in the error
```
'str' object is not callable
```
because the python executable was not set correctly.
2023-07-17 13:19:47 -07:00
Seth R. Johnson
cc73789744 vecgeom: new version 1.2.4 (#38940) 2023-07-17 12:00:57 -07:00
Ashwin Kumar Karnad
c9b7eb3647 libxc: add kxc and lxc variants (#38937)
* libxc: add kxc and lxc variants
* libxc: add kxc and lxc variants for @5:0:
* Apply suggestion from @tldahlgren

---------

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-07-17 13:53:29 -04:00
Harmen Stoppels
1100cdf5a0 Enable http/2 support by default in curl (#38750) 2023-07-17 09:21:51 -07:00
Manuela Kuhn
6ac93e1095 librsvg: add 2.56.2 and rust upper version limit for 2.51 (#38766)
* librsvg: add rust upper version limit

* librsvg: Add 2.56.2
2023-07-17 09:14:05 -07:00
Martin Aumüller
193e6e7678 qt-base: fix build on macos, when +network (#38519)
* qt-base: always link to GSS framework on macOS

On macos, the code in src/network/kernel/qauthenticator.cpp
unconditionally includes the header from the GSS framework, so we should
link against it.

This applies two patches from the dev branch. They are to be cherry-picked
into the 6.5 (probably released with 6.5.2) and 6.6 branches, but they
apply against 6.3.2 as well.

* qt-base: disable libproxy on macOS

src/network/CMakeLists.txt disables it on MACOS anyway. And as it is not
found without pkg-config, building with +network would break because of
the feature being explicitly enabled.

* qt-base: don't depend on pkgconfig on macOS

On macOS, usage of pkg-config is disabled by unsetting
PKG_CONFIG_EXECUTABLE, unless the feature pkg-config is requested explicitly.

* qt-base: don't depend on at-spi2-core on macOS

Does not build on macOS and seems to be targeted at linux. Qt6 on
homebrew does not depend on it, either.

* qt-base: fix long lines

* qt-base: restrict use of pkgconfig to linux

yes, probably not needed on windows, either

Co-authored-by: Alec Scott <alec@bcs.sh>

* qt-base: disable libproxy on Windows as well

according to src/network/CMakeLists.txt it's only used on Unix

* qt-base: improvements based on reviewer suggestions

---------

Co-authored-by: Alec Scott <alec@bcs.sh>
2023-07-17 08:53:47 -07:00
Elliott Slaughter
dc216adde2 legion: Add 23.06.0, variants for UCX, max nodes, update CUDA version. (#38759)
* legion: Add 23.06.0, variants for UCX, max nodes, update CUDA version.

* legion: Make newer CUDA versions dependent on newer Legion.

* legion: Update CUDA arch list so that we can stop tracking manually.
2023-07-17 08:51:45 -07:00
Maxence Thévenet
bf43471a7c HiPACE++ 23.07 (#38862)
* Update package and fix compilation issues
* fix order
2023-07-17 08:23:27 -07:00
Daniele Cesarini
469f06a8f2 Added py-eprosima-fastdds package (#38877)
* Added py-eprosima-fastdds package

* Fixed python extension and dependency version

* Added build type for swig

* Added minimum cmake support

* Added py-test dependency

* Added suggestion on python extension

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Added suggestion on build type for cmake

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-17 11:12:29 -04:00
Massimiliano Culpo
53ae969aa0 Lock, database and store don't need global configuration on construction (#33495)
Lock objects can now be instantiated independently,
without being tied to the global configuration. The
same is true for database and store objects.

The database __init__ method has been simplified to
take a single lock configuration object. Some common
lock configurations (e.g. NO_LOCK or NO_TIMEOUT) have
been named and are provided as globals.

The use_store context manager keeps the configuration
consistent by pushing and popping an internal scope.
It can also be tuned by passing extra data to set up
e.g. upstreams or anything else that might be related
to the store.
2023-07-17 16:51:04 +02:00
Adam J. Stewart
2b5a7bb4d7 Update new PythonPackage template to prefer --config-settings (#38918) 2023-07-17 08:03:05 -05:00
Aiden Grossman
e91db77930 root: Add package name to all conflict messages (#38920)
Not having the package name in the conflict messages can make debugging
conflicts exceedingly hard when trying to concretize an environment with
a sufficient number of packages. This patch adds the package name to all
of the conflict messages so that it is easy to tell just from the
message which package is causing conflicts.
2023-07-17 07:10:36 -05:00
Peter Scheibel
31431f967a Environment/depfile: fix bug with Git hash versions (attempt #2) (#37560)
Co-authored-by: Harmen Stoppels <me@harmenstoppels.nl>
2023-07-17 11:17:32 +00:00
Massimiliano Culpo
63b88c4b75 Minimal cleanup of a few tests in test/packaging.py (#38880)
* Minimal cleanup of a few tests in packaging.py

* Use f-strings
2023-07-17 10:36:29 +02:00
Manuela Kuhn
5e7f989019 py-jinja2: add conflict for py-markupsafe@2.0.2 (#38913)
* py-jinja2: add conflict for py-markupsafe@2.0.2

* Update var/spack/repos/builtin/packages/py-jinja2/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-15 18:05:15 -05:00
Manuela Kuhn
319ef0f459 py-shiboken: fix build by restricting dependencies (#38900)
* py-shiboken: fix build by restricting dependencies

* Update var/spack/repos/builtin/packages/py-shiboken/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Remove conflict

* Remove py-markupsafe conflict

* Update var/spack/repos/builtin/packages/py-shiboken/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-15 18:57:35 -04:00
Manuela Kuhn
a9d5f24791 py-furo: add new package (#38904) 2023-07-15 17:16:34 -05:00
Manuela Kuhn
74d5da43a8 py-sphinx-rtd-theme: add 1.2.2 and py-sphinxcontrib-jquery: add 4.1 (#38896) 2023-07-15 16:25:58 -05:00
Elliott Slaughter
829b4fe8fe py-cupy: Add 11.3.0, 11.4.0, 11.5.0, 11.6.0, 12.0.0, 12.1.0 (#38911)
* py-cupy: Add 11.3.0, 11.4.0, 11.5.0, 11.6.0, 12.0.0, 12.1.0.

* Clean up version bounds.
2023-07-14 21:12:31 -07:00
Jonas Thies
5672c64356 add a phist patch to avoid trying to compile SSE code if that is not … (#38806)
* add a phist patch to avoid trying to compile SSE code if that is not available.

* phist: make the avoid-sse patch more robust because compiler on ARM system still tried to compile SSE code
2023-07-14 21:10:57 -07:00
Richard Berger
1f58ac5ed3 spiner: update dependencies (#37367)
* spiner: update dependencies
* spiner: add v1.6.1 and updated dependency
2023-07-14 20:07:17 -04:00
Massimiliano Culpo
206a0a1658 legion package: use conditional variants for gasnet (#38902) 2023-07-14 14:44:15 -07:00
Michael Kuhn
b72d0e850d lmdb: add 0.9.31 (#38892) 2023-07-14 11:04:16 -07:00
Thomas Madlener
29835ac343 podio: add 0.16.6 tag and mark older releases as deprecated (#38891)
* podio: Add latest tag
* podio: Deprecate older versions
2023-07-14 11:03:08 -07:00
G-Ragghianti
e276131b2a new release and bug fix on check() (#38901) 2023-07-14 10:57:11 -07:00
Adam J. Stewart
c5f9ae864a GDAL: add v3.7.1 (#38884) 2023-07-14 13:23:01 -04:00
Harmen Stoppels
ac5976d17d Remove unused context manager (#38897) 2023-07-14 18:41:30 +02:00
Vicente Bolea
de719e9a4b adios2: add catalyst variant (#38852) 2023-07-14 08:51:28 -07:00
Harmen Stoppels
f30ede1ab8 ci: remove aws-ahug (#38777) 2023-07-14 10:49:57 -05:00
dependabot[bot]
9e0f1f8998 build(deps): bump actions/setup-python from 4.6.1 to 4.7.0 (#38887)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 4.6.1 to 4.7.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](bd6b4b6205...61a6322f88)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-14 15:48:29 +00:00
Manuela Kuhn
ee335c0d53 py-protobuf: add 4.23.3 (#38614)
* py-protobuf: add 4.23.3

* protobuf: add 3.23.3

* py-protobuf: disable cpp variant for @4.22:
2023-07-14 10:38:23 -05:00
Manuela Kuhn
0c986da030 py-simplejson: add 3.19.1 (#38898) 2023-07-14 10:34:33 -05:00
Adam J. Stewart
0d5d9524f2 py-lightly: add v1.4.12 (#38883) 2023-07-14 10:49:18 -04:00
Taillefumier Mathieu
c94137f6ea Use sirius namespacing for cmake (#38707)
* Use sirius namespacing for cmake

* Formating

* Fix lapack variables
2023-07-14 10:43:49 -04:00
Wouter Deconinck
9259a6aae4 xrootd: new versions 5.6.0, 5.6.1 (#38844) 2023-07-14 08:50:52 -05:00
Rocco Meli
244dfb3a35 Fix issue on cray with super call (#38895) 2023-07-14 10:00:02 +00:00
Harmen Stoppels
e16397b5d8 disable superlu test (#38894) 2023-07-14 10:53:16 +02:00
Tamara Dahlgren
2e9e7ce7c4 Bugfix/spack spec: read and use the environment concretizer:unification option (#38248)
* Bugfix: spack.yaml concretizer:unify needs to be read and used
* Optional: add environment test to ensure configuration scheme is used
* Activate environment in unit tests
  A more proper solution would be to keep
  an environment instance configuration as
  an attribute, but that is a bigger refactor
* Delay evaluation of Environment.unify
* Slightly simplify unit tests

---------

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-07-13 23:43:20 +02:00
Adam J. Stewart
f802b64e7a Update TensorFlow ecosystem (#38747)
* Update TensorFlow ecosystem

* Re-add +cpp

* Do not use system protobuf

* Let bazel auto-detect macOS SDK version

* Unnecessary duplicated dep

* Remove unused import
2023-07-13 14:42:07 -05:00
Sergey Kosukhin
afe6f7ed79 eccodes: fix a few issues in the recipe (#38873)
* explicitly disable the Python 2 interface

* drop obsolete cmake argument HDF5_ROOT for newer versions

* set PYTHON_EXECUTABLE only when needed
2023-07-13 13:53:19 -04:00
Richard Berger
82d41a7be4 FleCSI updates (#38870)
* flecsi: update maintainers
* flecsi: allow newer HPX to be used
* flecsi: propagate ROCm variants when using legion
* flecsi: add v2.2.1
2023-07-13 10:19:11 -07:00
Mikael Simberg
412a09e78b Add keep_werror = "specific" to mpich (#38861) 2023-07-13 09:27:03 -07:00
Harmen Stoppels
fbc0956d19 ccache: 4.8.2 (#38874) 2023-07-13 09:14:06 -07:00
Harmen Stoppels
dcb4bc3c54 ca-certificates-mozilla: add 2023-05-30 (#38875) 2023-07-13 09:12:46 -07:00
Manuela Kuhn
1ac2f34333 foonathan-memory: add 0.7-3 (#38879) 2023-07-13 08:59:14 -07:00
Harmen Stoppels
033eb77aa9 spack buildcache push: improve argparse (#38876) 2023-07-13 16:01:09 +02:00
Harmen Stoppels
522d9e260b mirrors: distinguish between source/binary mirror; simplify schema (#34523)
Allow the following formats:

```yaml
mirrors:
  name: <url>
```

```yaml
mirrors:
  name:
    url: s3://xyz
    access_pair: [x, y]
```

```yaml
mirrors:
  name:
    fetch: http://xyz
    push:
      url: s3://xyz
      access_pair: [x, y]
```

And reserve two new properties to indicate the mirror type (e.g.
mirror.spack.io is a source mirror, not a binary cache)

```yaml
mirrors:
  spack-public:
    source: true
    binary: false
    url: https://mirror.spack.io
```
2023-07-13 11:29:17 +00:00
Massimiliano Culpo
3261889e3a spack audit: allow skipping version checks from package.py (#28372)
A few packages have version directives evaluated
within if statements, conditional on the value of
`platform.platform()`.

Sometimes there are no cases for e.g. platform=darwin and that
causes a lot of spurious failures with version existence
audits.

This PR allows expressing conditions to skip version
existence checks in audits and avoid these spurious reports.
2023-07-13 06:47:47 -04:00
Harmen Stoppels
161b30a32f Add type hints to spack.installer (#38872) 2023-07-13 10:41:19 +00:00
Adam J. Stewart
b67f1f395b Add missing space in error msg (#38863) 2023-07-13 10:24:02 +02:00
dependabot[bot]
33c2fd7228 build(deps): bump docker/setup-buildx-action from 2.9.0 to 2.9.1 (#38868)
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2.9.0 to 2.9.1.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](2a1a44ac4a...4c0219f9ac)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-13 10:23:22 +02:00
Manuela Kuhn
7d5007b5e4 Restrict py-pip version for packages using --install-option (#38837) 2023-07-13 10:00:40 +02:00
Adam J. Stewart
bb7f437bf5 Standardize subcommand help strings (#38804)
### Rationale

While working on #29549, I noticed a lot of inconsistencies in our argparse help messages. This is important for fish where these help messages end up as descriptions in the tab completion menu. See https://github.com/spack/spack/pull/29549#issuecomment-1627596477 for some examples of longer or more stylized help messages.

### Implementation

This PR makes the following changes:

- [x] help messages start with a lowercase letter.
- [x] Help messages do not end with a period
- [x] the first line of a help message is short and simple

    longer text is separated by an empty line
- [x] "help messages do not use triple quotes" 

    """(except docstrings)"""
- [x] Parentheses not needed for string concatenation inside function call
- [x] Remove "..." "..." string concatenation leftover from black reformatting
- [x] Remove Sphinx argument docs from help messages

The first 2 choices aren't very controversial, and are designed to match the syntax of the `--help` flag automatically added by argparse. The 3rd choice is more up for debate, and is designed to match our package/module docstrings. The 4th choice is designed to avoid excessive newline characters and indentation. We may actually want to go even further and disallow docstrings altogether.

### Alternatives

Choice 3 in particular has a lot of alternatives. My goal is solely to ensure that fish tab completion looks reasonable. Alternatives include:

1. Get rid of long help messages, only allow short simple messages
2. Move longer help messages to epilog
3. Separate by 2 newline characters instead of 1
4. Separate by period instead of newline. First sentence goes into tab completion description

The number of commands with long help text is actually rather small, and is mostly relegated to `spack ci` and `spack buildcache`. So 1 isn't actually as ridiculous as it sounds.

Let me know if there are any other standardizations or alternatives you would like to suggest.
2023-07-13 00:18:23 -07:00
Vicente Bolea
6312ae8464 vtk-m: modernize vtk-m recipe (#38726) 2023-07-13 08:21:38 +02:00
Harmen Stoppels
3828ae2a52 ci: populate caches in before script (#38762)
* ci: run spack list in power ci

Let's see if Spack itself is the bottleneck in CI...

* rebuild curl in CI

* more of the same please!

* drop the profiler

* undo rebuildme test in ci variant

* add comment for posterity

* enable profiling

* trigger CI

* See how it goes now that perf regressions are fixed on develop

* try shorter poll intervals

* Revert "try shorter poll intervals"

This reverts commit d60c34ad3eceead0c13a5277cf8e783fd42b7458.

* Remove spec.format call in Database._get_matching_spec_key

* once more in ci please

* undo irrelevant changes

* run spack list in before script

* test in ci

* -:

* Undo CI testing
2023-07-12 18:12:22 -05:00
dependabot[bot]
c2bdb4600a build(deps): bump docker/setup-buildx-action from 2.8.0 to 2.9.0 (#38783)
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2.8.0 to 2.9.0.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](16c0bc4a6e...2a1a44ac4a)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-12 17:18:05 -04:00
Jonathon Anderson
90208da8a5 containers: retain shallow git data (#37734) 2023-07-12 21:03:10 +00:00
Michael Fink
c8026c3c87 Add path to MPI executables to ^mpi dependents (#35758) 2023-07-12 13:58:43 -05:00
G-Ragghianti
f895f80bc2 Package papi: update for smoke tests (#38711)
* Adding papi smoke tests
* smoke tests
* update to new test framework
2023-07-12 11:38:57 -07:00
Stephan Grein
0ca11d7033 Fix fmt and spdlog versions for micromamba. (#38739)
The spdlog project precisely states/depends which fmt version should
be used for compatibility. Latest version 1.11.0 depends explictly on
fmt 9.1.0. Without fixed version micromamba build fails when using spack
install micromamba on e.g. Rockylinux 8.5.
2023-07-12 11:24:26 -07:00
Dax Lynch
4fa7dc03ae py-callmonitor: added new package (#38764)
* py-callmonitor: added new package

* depends_on numpy

* Update var/spack/repos/builtin/packages/py-callmonitor/package.py

Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>

---------

Co-authored-by: eugeneswalker <eugenesunsetwalker@gmail.com>
Co-authored-by: eugeneswalker <38933153+eugeneswalker@users.noreply.github.com>
Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>
2023-07-12 11:19:57 -07:00
Vicente Bolea
5ba99b8eb2 adios2: add aws variant (#38857) 2023-07-12 11:14:47 -07:00
Samuel Browne
78b24b45f6 Add gettext as a dependency of bison (#35979)
The 'bison' executable requires libtextstyle to run.  I think this was
usually satisfied because gettext is often installed with the OS, or
brought in accidentally via perl/m4.

Looks like the libtextstyle library dependency started in Bison 3.4
2023-07-12 14:01:12 -04:00
kjrstory
c2bafd7b7f openfoam-org: add precision option (#38746) 2023-07-12 14:49:45 +02:00
Andre Sailer
778cbb225c Static-analysis-suite: mark versions deprecate for this obsolete package (#38754) 2023-07-12 14:47:03 +02:00
Mikael Simberg
62f24f1b2a Patch broken CMake handling when no architectures are found in HIP package (#37022) 2023-07-12 14:39:41 +02:00
Vicente Bolea
37ef31dc22 vtk-m: correct cuda_arch variant behavior (#38697)
Co-authored-by: eugeneswalker <eugenesunsetwalker@gmail.com>
2023-07-12 14:34:50 +02:00
Mikael Simberg
7f2be62ff2 Add conflict for hpx on ARM (#38812)
HPX requires use of Boost.Context on ARM.
2023-07-12 13:38:57 +02:00
snehring
ca16066eef apptainer: add flag_handler to discard spack flags (#38843) 2023-07-12 13:31:47 +02:00
Vanessasaurus
6a762501f8 flux-sched: add v0.28.0 (#38860)
Co-authored-by: github-actions <github-actions@users.noreply.github.com>
2023-07-12 05:33:48 -04:00
Seth R. Johnson
29fa4bf64c hepmc3: add protobuf variant and update flags (#38841) 2023-07-12 11:21:49 +02:00
Adam J. Stewart
d2ed8c5226 py-torch: rename master to main (#38858) 2023-07-12 11:20:47 +02:00
Massimiliano Culpo
fb223f034b Fix build of CentOS stream docker image (#38824) 2023-07-12 10:55:43 +02:00
Daniele Cesarini
ca4c59cd77 REGALE: add new package (#38444)
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-07-12 10:21:36 +02:00
Richard Berger
dfcb3bca65 legion: add ofi-slingshot11 conduit (#38859) 2023-07-12 03:53:26 -04:00
Tamara Dahlgren
ce6b79cd96 cbflib: fix build with newer gfortran (#38632) 2023-07-12 09:15:26 +02:00
Rocco Meli
831bfb43f5 DLA-Future: ensure umpire~cuda~rocm when ~cuda~rocm (#38835)
Co-authored-by: Raffaele Solcà <rasolca@cscs.ch>
2023-07-12 09:11:07 +02:00
Wileam Y. Phan
60697b421e fpm: add versions up to 0.9.0 (#38856) 2023-07-12 09:09:36 +02:00
Michael Kuhn
d5d0b8821c installer: Improve status reporting (#37903)
Refactor `TermTitle` into `InstallStatus` and use it to show progress
information both in the terminal title as well as inline. This also
turns on the terminal title status by default.

The inline output will look like the following after this change:
```
==> Installing m4-1.4.19-w2fxrpuz64zdq63woprqfxxzc3tzu7p3 [4/4]
```
2023-07-12 08:54:45 +02:00
Samuel Browne
d3704130b6 trilinos: Add CMake minimum and 14.2.0 version (#38853)
* Update minimum CMake version for Trilinos
  Changed to 3.23 as of release 14.0.0.
* Add Trilinos 14.2.0
2023-07-12 01:04:07 -04:00
Seth R. Johnson
9ef138dad5 protobuf: use cxxstd from abseil-cpp to fix C++17 build (#38840) 2023-07-11 20:03:51 -04:00
Thomas Madlener
6b51bfb713 edm4hep: Add tag for version 0.10 and deprecate older versions (#38817)
* edm4hep: add latest tag
* edm4hep: Mark all older versions as deprecated
2023-07-11 16:00:06 -07:00
MatthewLieber
fb7cdb0408 Adding sha for the 7.2 release of OMB (#38842)
Co-authored-by: Matt Lieber <lieber.31@osu.edu>
2023-07-11 15:56:25 -07:00
Chris Green
1e1b086484 [procps] Improve gettext/libintl handling (#38646)
Fixes #38639.
2023-07-11 15:35:55 -07:00
Stephen Hudson
0d51faf6cb libEnsemble: add v0.10.1 (#38845) 2023-07-11 18:18:16 -04:00
Manuela Kuhn
ed247744e7 py-charm4py: add missing dependencies (#38830) 2023-07-11 14:49:49 -04:00
Christian Glusa
299066feb5 Py-PyNucleus: Update dependencies, enable parallel build (#38779) 2023-07-11 12:50:41 -04:00
Martin Aumüller
2e695fa03f ispc: on ARM, build with ARM targets enabled, and updates (#38080)
* llvm: fix build with libcxx=none

* ispc: checksum 1.20.0

* ispc: ensure that it does not crash immediately

this would happen if linked to the wrong libc++

* ispc: fix build on macos

find ncurses instead of curses and link against tinfo in order to avoid
unresolved references to _del_curterm, _set_curterm, _setupterm, and
_tigetnum

* ispc: enable arm targets, if building on arm

* ispc: remove double cmake argument

I forgot to remove the constant -DARM_ENABLED=FALSE when adding
-DARM_ENABLED with a value depending on target architecture

* ispc: fix linux build

since 1.20, linux build uses TBB as default tasking system and thus
needs to depend on it

* ispc: try to fix link error on linux

link against both curses (as before) and tinfo (added because of macos)

* ispc: update for recent llvm changes

libcxx=none instead of ~libcxx
2023-07-11 09:44:18 -07:00
Adam J. Stewart
5fc949f252 py-black: add v23.7.0 (#38834) 2023-07-11 09:50:19 -05:00
Adam J. Stewart
e6876f47e6 py-lightning: add v2.0.5 (#38828) 2023-07-11 09:49:50 -05:00
Rocco Meli
364884df97 fix tiled-mm (#38774) 2023-07-11 14:28:37 +02:00
Massimiliano Culpo
d0e39a9870 Add CHANGELOG entry for v0.20.1 (#38836) 2023-07-11 13:35:04 +02:00
Todd Gamblin
162d0926f9 mypy: add more ignored modules to pyproject.toml (#38769)
`mypy` will check *all* imported packages, even optional dependencies outside your
project, and this can cause issues if you are targeting python versions *older* than the
one you're running in. `mypy` will report issues in the latest versions of dependencies
as errors even if installing on some older python would have installed an older version
of the dependency.

We saw this problem before with `numpy` in #34732. We've started seeing it with IPython
in #38704. This fixes the issue by exempting `IPython` and a number of other imports of
Spack's from `mypy` checking.
2023-07-11 13:30:07 +02:00
Manuela Kuhn
f0ef0ceb34 py-gluoncv: switch to PyPI and add 0.10.5.post0 (#38814)
* py-gluoncv: switch to PyPI and add 0.10.5.post0

* Fix style

* Remove no-unicode-readme.patch
2023-07-10 21:19:15 -05:00
Adam J. Stewart
5ba40913af py-numpy: add v1.25.1 (#38799) 2023-07-10 21:18:39 -05:00
Jen Herting
7288f11cf9 [arrow] tuple has no method append (#38820) 2023-07-10 18:12:08 -07:00
Wouter Deconinck
d5b01e45ce mlpack: remove go variant from cmake_args (#38821) 2023-07-10 18:10:02 -07:00
Manuela Kuhn
8827f01865 py-minkowskiengine: add missing openblas dependency (#38742)
* py-minkowskiengine: add missing openblas dependency

* Add comment about blas
2023-07-10 17:21:16 -05:00
renjithravindrankannath
2163c3701c Setting library path as lib similar to other rocm packages. (#37568)
* Setting library path as lib similar to other rocm packages.
* Fix style check failure
* Restricting changes to 5.4.3 and above
* Including comgr change
2023-07-10 14:55:39 -07:00
afzpatel
db23fd055c new hip-examples package (#35891)
* initial commit for adding hip-examples package
* adding test to hip-examples
* fixed compile error on add4
* change standalone test to use new syntax
2023-07-10 13:05:46 -07:00
Sangu Mbekelu
73acf110ff py-sacrebleu (#37159)
* new mosesdecoder package

* "new py-sacrebleu package"

* Delete package.py

* [@spackbot] updating style on behalf of Sangu-Mbekelu

* Update package.py

updating package based on review

---------

Co-authored-by: Sangu Mbekelu <s.mbekelu9@gmail.com>
2023-07-10 12:16:42 -07:00
kjrstory
ff49969264 Package:Openfoam-org version url using function (#37587)
* Package:Openfoam-org version url using function
* Package:Openfoam-org small style fix
* openfoam-org: url_for_function
2023-07-10 11:19:29 -07:00
eugeneswalker
eb94d830e1 legion +rocm: set HIP_PATH to {hip.prefix}/hip (#38819) 2023-07-10 10:35:12 -07:00
Chris Green
8fdd8fcf63 Perl package: detect opcode support in externals (#38618)
Spack-installed Perl always has opcode support, but external Perl
installations might not. This commit adds a +opcode variant and
updates the external detection logic to check for opcode support.

The postgresql package is updated to require perl+opcode (in
combination with the above, this helps detect when an external
Perl instance is sufficient for a Spack build of postgreqsql, or
if Spack needs to build its own Perl).
2023-07-10 10:01:20 -07:00
Michael Kuhn
30b077e63c glib: add 2.76.4 (#38813) 2023-07-10 09:06:05 -07:00
Taillefumier Mathieu
64c6d63675 Update cp2k recipe to use cmake or the current build system (#35718)
* Update cp2k recipe to use cmake or the current build system

Offers the possibility to build cp2k with the new cmake build system. commands like this are now supported

spack install cp2k@master build_system=cmake +.....

the recipe supports the following optional functionalities

- superlu, cosma, sirius, spglib, metis, spglib, libxc, libint, cuda/rocm, mkl/openblas/sci (and others), mpi, openmp, dbcsr
- dbcsr is built separately using the currently available recipe.

Two PRs need to be merged to be fully functional (cosma update in spack + one PR in cp2k github).

* Fix indentation

* Fix indentation

* Update libvori

* More typos

* Simplify BLAS/LAPACK

* Simplify BLAS/LAPACK

* Add A100 gpu value

* Fix typo

* Add the enable_regtests option

if -DCP2K_ENABLE_REGTESTS=ON (+enable_regtests with spack) then the location of the binary executables will be in the cp2k root directory under exe/build-cmake-*. This option is needed to run the regtests afterwards.

* Minor update

* more fixes

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

* small changes

* Remove any reference to nvidia architecture in the rocm list

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>

* Update var/spack/repos/builtin/packages/cp2k/package.py

Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>

* Final reformating

* Update py-fypp

---------

Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>
Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>
2023-07-10 14:02:52 +02:00
Massimiliano Culpo
0ed6ff3823 Removing inactive maintainer (#38773) 2023-07-10 11:31:09 +02:00
Todd Gamblin
757f8ae59c find: add --hashes shortcut for piping to other commands (#38663)
People frequently ask us how to pipe `spack find` output to other commands, and we tell
them to do things like this:

```console
$ spack find --format "/{hash}" | spack uninstall -ay
```

Sometimes users don't know about hash references and come up with potentially ambiguous
formulations like this:

```console
spack find --format {name}@{version}%{compiler} | spack uninstall -ay
```

Since this is a common enough thing to want to do, and to make it more obvious how, this
PR adds a `-H` / `--hashes` as a shortcut, so you can now just do:

```console
spack find -H | spack uninstall -ay
```
2023-07-10 09:43:37 +02:00
Dax Lynch
27c62b981a Added package py-bitstruct (#38761)
* Added packages bitstruct, callmonitor, and PYnvtx

* Revert "Added packages bitstruct, callmonitor, and PYnvtx"

This reverts commit 76d25aa76b.

* py-bitstruct: This module is intended to have a similar interface as the python struct module, but working on bits instead of primitive data types (char, int, …)

* Update package.py

To pass the style prechecks

* PyNVTX: new package

* Delete package.py

Accidentally added this package.

* Update var/spack/repos/builtin/packages/py-bitstruct/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: eugeneswalker <38933153+eugeneswalker@users.noreply.github.com>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-09 20:19:07 -05:00
Manuela Kuhn
1ed934c710 py-triangle: restrict Python version (#38808) 2023-07-09 20:12:42 -04:00
Harmen Stoppels
eef14ddcad openssl: prefer 3.x (#36729)
* openssl: prefer 3.x

This PR is not intended to be merged immediately, but it would be good
to see what packages fail to build in CI so that we can get proper
version constraints on openssl (before all packages update and support
both openssl 1 and 3)

* Disable assembly for 3.x %oneapi

* cmake: depend on spack curl, to deal with curl - openssl compat

* also make zlib external

* remove overly strict & unsafe requirement on py-cryptographty patch version number

* update openssl compat bounds in py-cryptography

* smaller diff

* Make libssh2 an autotools/cmake package

* fix weird upperbound in libssh2 as there is not openssl v2

* libssh2: pc file lists plain -lssl -lcrypto w/o leading -L flag, confusing libgit2 parsing of pkg-config output

* Actually fix the issue in libssh2: its pc file looks broken
2023-07-09 17:48:00 -04:00
Jonathon Anderson
db879a5679 ci: Fix broken SPACK_CHECKOUT_VERSION (#38778) 2023-07-09 12:37:36 -07:00
Vanessasaurus
d0804c44f1 Automated deployment to update package flux-core 2023-07-08 (#38790)
Co-authored-by: github-actions <github-actions@users.noreply.github.com>
2023-07-09 12:12:55 -07:00
Harmen Stoppels
374fda1063 Don’t call spec.format in Database._get_matching_spec_key (#38792)
`"%s" % spec` formats the spec with deps included, which produces sometimes KBs
of data and is slow to run in pure Python. It can delay otherwise very short-lived
read/write locks on the database.

Discovered in #38762 where profile output showed about 2 seconds is spent in
`spec.format`, which is significant overhead when using multiprocessing to install
from binary cache in parallel (installation often takes <5s for small packages). With
this change, `spec.format` no longer shows up in profile output.

(This line hasn't changed since Spack v0.9 ;p)

* move format() call to custom NoSuchSpecError exception
* add a comment saying why, so we can eventually change `Spec.__str__`
2023-07-09 11:27:38 -04:00
Jonathon Anderson
3c14569b8e pkgconf: Update to new upstream URL (#38800)
See 437c2a3218
2023-07-09 16:12:47 +02:00
Michael Kuhn
841402c57a gcc: add 10.5.0 (#38784) 2023-07-09 12:13:04 +02:00
Wouter Deconinck
09e1258ed4 qt-* (Qt6 pkgs): new versions 6.5.0, 6.5.1 (#36705)
* qt-base: new version 6.5.0

* qt-declarative: new version 6.5.0

* qt-quick3d: new version 6.5.0

* qt-quicktimeline: new version 6.5.0

* qt-shadertools: new version 6.5.0

* qt-*: new version 6.5.1

* qt-base: new version 6.5.1
2023-07-08 15:36:27 -05:00
Dax Lynch
b2dcd9bd42 PyNVTX: added new package (#38763) 2023-07-07 20:02:21 -05:00
Manuela Kuhn
2dc76248d3 py-pyarrow: disable dataset variant by default (#38775)
* py-pyarrow: enable parquet variant by default

* Disable parquet variant by default

* Add conflict to enable parquet when dataset is active

* Disable dataset variant by default
2023-07-07 16:27:32 -05:00
Adam J. Stewart
bf6eb832ae py-matplotlib: add v3.7.2 (#38745)
* py-matplotlib: add v3.7.2

* Update dep versions
2023-07-07 14:43:41 -05:00
Chris Richardson
e8e6d69af5 New package: py-nanobind (#38327)
* initial commit of nanobind package

* style fixes

* Update package.py

Typo

* addressed PR comments

* add v1.4.0

* Update var/spack/repos/builtin/packages/py-nanobind/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Matthew Archer <ma595@cam.ac.uk>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-07 12:02:45 -04:00
Manuela Kuhn
050d8df5a5 py-astropy: fix import tests and restrict py-pip version (#38731)
* py-astropy: fix import tests and restrict py-pip version

* Fix --install-option name in comments

* Rename variant and fix variant dependencies

* Remove parquet variant from py-pyarrow
2023-07-07 10:19:02 -05:00
Massimiliano Culpo
6958b49c2f Remove "node_compiler" from the list of unknown atoms (#38753) 2023-07-07 13:19:53 +02:00
Harmen Stoppels
a1d33e97ec Fix multiple quadratic complexity issues in environments (#38771)
1. Fix O(n^2) iteration in `_get_overwrite_specs`
2. Early exit `get_by_hash` on full hash
3. Fix O(n^2) double lookup in `all_matching_specs` with hashes
4. Fix some legibility issues
2023-07-07 10:51:58 +00:00
Massimiliano Culpo
ca9b52bbc5 Prevent "spack external find" to error out on wrong permissions (#38755)
fixes #38733
2023-07-07 12:05:32 +02:00
Andrey Parfenov
ae00d7c358 add info about spack env from spack-configs for oneAPI build tools (#38751)
Signed-off-by: Andrey Parfenov <andrey.parfenov@intel.com>
2023-07-07 03:47:54 +00:00
Mickael PHILIT
1071c1d8e0 add cgns 4.4.0 (#38530) 2023-07-06 17:52:03 -07:00
Carlos Bederián
5f6c832020 freesurfer: add 7.4.1, 7.4.0, 7.3.2 (#38544) 2023-07-06 17:51:01 -07:00
Wouter Deconinck
9e4c4be3f5 mlpack: new package (#38277)
* mlpack: new package

mlpack is an intuitive, fast, and flexible header-only C++ machine learning library with bindings to other languages. It is meant to be a machine learning analog to LAPACK, and aims to implement a wide array of machine learning methods and functions as a "swiss army knife" for machine learning researchers.

* mlpack: upstream merged patch to allow python installation in spack
2023-07-06 13:42:56 -07:00
John W. Parent
6c325a2246 Curl Package: Fixup bugs preventing build on Win (#38757) 2023-07-06 14:59:42 -04:00
Ben Cowan
28b884ace5 Add new version 5.0.0 of PyAMG (#38674)
* Added v5.0.0 of PyAMG.  This required v7.1.0 of setuptools_scm due to a bug in 7.0.5.

* Added comment about version requirement.

* Loosened dependency based on build experiments.

* Updated tomli deps.

* Update var/spack/repos/builtin/packages/py-setuptools-scm/package.py

Dependence for 7.0 only.

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-pyamg/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Swapped lines.

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-06 13:54:29 -04:00
Harmen Stoppels
a13687f022 Disable fortran in openblas for darwin ci, fix variant default value (#38752) 2023-07-06 17:47:20 +02:00
Thomas Bouvier
bd81676e3c py-torch: fix build (#38730) 2023-07-06 09:35:11 -05:00
Adam J. Stewart
7eaa99eabc py-scikit-learn: add v1.3.0 (#38660) 2023-07-06 08:55:00 -05:00
kjrstory
5cb0b57b30 openfoam.org: add a maintainer(#37280) (#37697)
Co-authored-by: Dom Heinzeller <dom.heinzeller@icloud.com>
2023-07-06 13:44:24 +02:00
Jen Herting
c6867649b9 [py-blis] added versions 0.7.9 and 0.9.1 (#38269)
* [py-blis] added version 0.7.9

* [py-blis] added version 0.9.1

* [py-blis]

- removed type run for dependency py-cython
2023-07-06 05:09:11 -04:00
Jim Phillips
c129603192 namd: add maintainer (#38740) 2023-07-06 04:28:54 -04:00
Manuela Kuhn
4e456992e4 py-abipy: add 0.9.3 (#38716)
* py-abipy: add 0.9.3

* Remove py-cython dependency

* Remove dep version restrictions for new release
2023-07-06 04:23:55 -04:00
Jen Herting
10876736e0 [py-cymem] added version 2.0.7 (#38267)
* [py-cymem] added version 2.0.3

* [py-cymem] added restriction to py-wheel limitation
2023-07-06 04:13:44 -04:00
Thomas Bouvier
982cdd7988 py-dm-tree: add v0.1.8 (#38606)
* `py-dm-tree`: add v0.1.8

* Update dependencies

* Fix hash
2023-07-06 00:12:04 -05:00
Thomas Bouvier
095e48f399 py-horovod: update to v0.28.1 (#38732) 2023-07-05 23:56:47 -05:00
Manuela Kuhn
833db65fa3 py-pip: add 23.1.2 (#38608)
* py-pip: add 23.1.2

* Restrict py-pip version for py-protobuf

* Restrict py-pip version for straightforward packages

* Restrict py-pip version for nrm

* Fix --install-option name in comments

* Simplify py-pip restriction for py-scs

* nrm: fix wrong comment
2023-07-05 23:37:16 -04:00
Harmen Stoppels
06268f7b72 perl: add 5.38.0, 5.36.1; prefer all even minor versions over development versions (#38690)
* perl: add 5.38.0, 5.36.1; prefer all even minor versions over development versions

* fix libxcrypt build with new perl

* fix libxcrypt with a patch
2023-07-05 18:08:54 -04:00
Manuela Kuhn
f884e71a03 py-spglib: add 2.0.2 (#38715)
* py-spglib: add 2.0.2

* Update var/spack/repos/builtin/packages/py-spglib/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Remove py-setuptools as run dependency

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-07-05 15:24:31 -05:00
Wouter Deconinck
ea1439dfa1 acts: new variant cxxstd (#38682)
* acts: allow ^root cxxstd=20

* acts: new variant cxxstd, pass through to root

* acts: always args.append CMAKE_CXX_STANDARD from variant

* acts: remove unused import

* acts: fix self.define_from_variant
2023-07-05 12:56:06 -07:00
Adam J. Stewart
45838cee0b Drop Python 2 super syntax (#38718) 2023-07-05 09:04:29 -05:00
Adam J. Stewart
95847a0b37 Drop Python 2 object subclassing (#38720) 2023-07-05 14:37:44 +02:00
George Young
8861fe0294 salmon: patching to build with %gcc@13: (#38553)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-07-05 14:36:55 +02:00
Harmen Stoppels
12427c6974 plumed: deprecate non-buildable versions, patch Python makefile only when supported (#38713) 2023-07-05 05:48:13 -04:00
Taillefumier Mathieu
a412403d7b Update cosma and a few related recipes (#35615)
* Add maintainers 

* Updated cosma archive checksum and costa version

- updated cosma version (in the cosma build system)
- updated costa version
- use the default generic url for downloading packages
- do not build tiled-mm when the cpu only version is needed


Signed-off-by: Dr. Mathieu Taillefumier <mathieu.taillefumier@free.fr>
Co-authored-by: Rocco Meli <r.meli@bluemail.ch>
Co-authored-by: Harmen Stoppels <harmenstoppels@gmail.com>
2023-07-05 11:02:50 +02:00
Martin Diehl
6a258c148f damask: fix build of alpha release (#38457) 2023-07-05 10:59:05 +02:00
Tom Epperly
8b13440038 Add version 1.8.23 that fixes a compilation bug on clang-15. (#38541) 2023-07-05 10:56:18 +02:00
Tamara Dahlgren
632f840d8a tk: convert to new stand-alone test process (#38575) 2023-07-05 10:55:07 +02:00
Alex Richert
8372726a88 ip: add v4.1.0, and additional variants (#38526) 2023-07-05 10:45:38 +02:00
Tamara Dahlgren
5dc84b64e9 tests/qthreads: convert to new stand-alone test process (#38600) 2023-07-05 10:41:25 +02:00
Tamara Dahlgren
8d72b8dd63 tests/papyrus: convert to new stand-alone test process (#38627) 2023-07-05 10:34:15 +02:00
Jim Phillips
adde84e663 Build NAMD with Tcl by default (#38645)
NAMD users expect the Tcl scripting interface to be enabled as it is used in many examples and tutorials in addition to being required for features such as multi-copy algorithms.
2023-07-05 10:29:11 +02:00
Rémi Lacroix
f863066b7e git-annex: add latest version 10.20230408 (#38728) 2023-07-05 04:27:46 -04:00
Juan Miguel Carceller
082afe04b8 xrootd: add _STAT_VER patch (#38547)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-07-05 10:14:18 +02:00
Peter Scheibel
f365386447 Installations: don't set group permissions when they match what is desired (#38036)
* When installing a package Spack will attempt to set group permissions on
the install prefix even when the configuration does not specify a group.

Co-authored-by: David Gomez <dvdgomez@users.noreply.github.com>
2023-07-05 09:54:04 +02:00
Carlos Bederián
a90200528f hcoll: ucx version requirements (#38665) 2023-07-05 09:48:58 +02:00
Adam J. Stewart
1ce6feef94 py-pyqt4: stricter dependency versions (#38673) 2023-07-05 09:45:24 +02:00
Weiqun Zhang
84010108b1 amrex: add v23.07 (#38676) 2023-07-05 09:43:37 +02:00
Adam J. Stewart
24d2005920 py-lightly: add v1.4.11 (#38717) 2023-07-05 09:41:08 +02:00
Robert Cohn
fa73b14247 intel-oneapi-mkl: support for cray mpich (#38725) 2023-07-05 09:20:19 +02:00
Manuela Kuhn
a99b7886e9 py-pymatgen: add 2022.9.8 (#38714) 2023-07-05 00:12:18 -05:00
Adam J. Stewart
2978911520 spack commands: add type hints and docstrings (#38705) 2023-07-04 16:43:02 -04:00
Harmen Stoppels
d35149d174 remove another Python 3.7 requirement & preference, since it was deprecated (#38710) 2023-07-04 20:33:47 +02:00
Manuela Kuhn
a3d11a7973 py-requests: add 2.31.0 (#38563) 2023-07-04 10:33:06 -04:00
Max Zeyen
cb69dbd804 gpi-space: add new versions (#38709)
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-07-04 15:01:39 +02:00
Laura Bellentani
e6f50c5341 quantum-espresso: change in maintainers (#38688) 2023-07-04 14:06:21 +02:00
Chris White
32d0b5ca97 conduit: remove no longer needed blueos logic (#38698) 2023-07-04 07:52:59 -04:00
valmar
b537fad37a Added Python Prometheus client as dependency (#38700) 2023-07-04 07:12:47 -04:00
Thomas Bouvier
78e78eb1da nvtx: add new package (#38430)
Co-authored-by: thomas-bouvier <thomas-bouvier@users.noreply.github.com>
2023-07-04 07:07:41 -04:00
Stephen Sachs
8aeecafd1a wrf: add ARM compiler support (#38695) 2023-07-04 12:33:58 +02:00
Stephen Sachs
a0b2ca2dde Temporarily disable aws-pcluster pipelines (#38708) 2023-07-04 11:27:01 +02:00
Harmen Stoppels
08f23f4802 macos sip: apply on macos only, dont store LD_LIBRARY_PATH (#38687) 2023-07-04 10:54:13 +02:00
Adam J. Stewart
e9dc6dc96c Fix DYLD_* propagation to Python process from fish shell (#38615) 2023-07-04 10:48:56 +02:00
Adam J. Stewart
5588b93683 util-linux: add v2.39.1, fix macOS build (#38677) 2023-07-04 10:47:26 +02:00
George Young
70a38ea1c5 plink2: add new package @2.00a4.3 (#38469)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-07-04 04:09:45 -04:00
Adam J. Stewart
5bd7a0c563 spack make-installer: deterministic choice order (#38706) 2023-07-04 09:39:38 +02:00
Adam J. Stewart
33c5959e23 Remove from __future__ imports (#38703) 2023-07-04 08:30:29 +02:00
Manuela Kuhn
65288566e5 py-numpydoc: add 1.5.0 (#38701) 2023-07-03 22:13:54 -04:00
Manuela Kuhn
5e1c4693fd py-ruff: add 0.0.276 (#38702) 2023-07-03 21:59:14 -04:00
Aditya Bhamidipati
feb4681878 Add NCCL v2.18.3-1 release to recipe (#38647) 2023-07-03 16:26:07 -05:00
Thomas Bouvier
994b5ad49e ffmpeg: patch build failure (#38656)
* `ffmpeg`: patch build failure

* [@spackbot] updating style on behalf of thomas-bouvier

---------

Co-authored-by: thomas-bouvier <thomas-bouvier@users.noreply.github.com>
2023-07-03 11:12:26 -07:00
Harmen Stoppels
4654db54c7 hdf5-vol-log: depends on mpi (#38693)
From the configure.ac file:

> H5VL_log is built on top of MPI. Configure option --without-mpi or
> --with-mpi=no should not be used. Abort.

This currently fails to build in the oneAPI pipeline on `develop`
2023-07-03 20:08:40 +02:00
Adam J. Stewart
a6ebff3a2e py-pillow: add v10.0.0 (#38670) 2023-07-03 11:02:24 -07:00
Ashwin Kumar Karnad
6e8fb30b83 Add hash for octopusV13 (#38655) 2023-07-03 10:24:52 -07:00
Cyrus Harrison
465f83b484 add ascent 0.9.2 release (#38661) 2023-07-03 10:14:01 -07:00
Harmen Stoppels
ba7ae2c153 Drop requirement of python@3.7 since it's deprecated (#38692) 2023-07-03 16:15:32 +02:00
Jonathon Anderson
54adab7eac python: require xz libs=shared when +lzma (#38593) 2023-07-03 07:11:30 -05:00
Andrey Parfenov
30cb55e97c add support for oneapi compiler to wrf 4.4 (#38607)
Signed-off-by: Andrey Parfenov <andrey.parfenov@intel.com>
2023-07-03 07:34:06 -04:00
Harmen Stoppels
3594203f64 guile: fix %oneapi fast math madness (#38691) 2023-07-03 13:25:55 +02:00
Adam J. Stewart
f0add2428c dbus: AutotoolsPackage, optional documentation build (#38679)
Co-authored-by: Harmen Stoppels <me@harmenstoppels.nl>
2023-07-03 04:18:00 -04:00
Adam J. Stewart
af449b7943 qt-base: disable accessibility by default (#38680) 2023-07-03 09:45:22 +02:00
Adam J. Stewart
b6d591e39b bash: adam now uses fish (#38684) 2023-07-03 02:44:44 -05:00
Adam J. Stewart
3811dec18d Deprecate conda for Python 2 (#38681) 2023-07-03 09:44:20 +02:00
Adam J. Stewart
ae2efa1c27 xmlto: fix missing dependency on util-linux (#38678) 2023-07-03 09:43:18 +02:00
John Biddiscombe
acdcc8ed71 Add support to Paraview for TBB (#38582)
Co-authored-by: Jean Favre <jfavre@cscs.ch>
2023-07-03 09:33:56 +02:00
Jack Morrison
11bc27d984 Add libfabric 1.18.1 release (#38669) 2023-07-02 13:39:20 -07:00
Adam J. Stewart
4d5ff045e3 Deprecate Python 3.7 (#38619)
* Deprecated Python 3.7

* Add Python 3.7.17 because why not
2023-07-02 11:29:35 -05:00
Adam J. Stewart
63576275be SIPPackage: documentation fix (#38672) 2023-07-02 11:30:08 +02:00
Harmen Stoppels
cc74729115 Revert "openblas: do not build tests when installing (#38591)" (#38662)
This reverts commit 51c75c6da3.
2023-07-01 22:02:39 -04:00
dependabot[bot]
a864108bc1 build(deps): bump docker/setup-buildx-action from 2.7.0 to 2.8.0 (#38625)
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2.7.0 to 2.8.0.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](ecf95283f0...16c0bc4a6e)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-01 10:57:26 -07:00
Tamara Dahlgren
4aed051b73 openrasmol: convert to new stand-alone test process (#38630) 2023-07-01 10:55:20 -07:00
Jochen Klein
43996e84c3 icarus: add v11_0 and v12_0 (#38666) 2023-07-01 10:38:09 -07:00
Harmen Stoppels
14ebf1985e mercurial: add 6.x, fix python bounds (#38668)
* mercurial: add 6.x, fix python bounds

* remove python@2 versions, cause package audits is complaining
2023-07-01 12:49:49 +02:00
Robert Cohn
0c2b98ca70 [intel-oneapi-mkl] add openmpi support for +cluster (#38554) 2023-06-30 18:38:40 -04:00
Jonathon Anderson
43143b134a New package: pipx (#38658)
* py-userpath: new package

* pipx: new package

* Update var/spack/repos/builtin/packages/pipx/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* pipx: Remove incorrect dependency on py-platformdirs

* Update var/spack/repos/builtin/packages/pipx/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* py-userpath: Remove version requirements to match upstream

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-30 16:42:57 -05:00
Chris Green
45697582dc [py-onnx-runtime] Remove package superseded by py-onnxruntime (#37392) 2023-06-30 16:42:12 -05:00
David Boehme
9a214ffb75 Add Caliper variant in hypre package (#38651) 2023-06-30 15:46:18 -05:00
Tamara Dahlgren
4286c7398b tests/petsc: convert to new stand-alone test process (#38652) 2023-06-30 15:36:41 -05:00
Tamara Dahlgren
131acbdacc tests/slepc: convert to new stand-alone test process (#38653) 2023-06-30 15:34:42 -05:00
Adam J. Stewart
86d2399c76 Remove deprecated versions and packages (#37895)
This PR removes deprecated versions for all packages that I'm maintaining. In future Spack releases, I'm planning to do this on a much larger scale, but we can hold off until we have better reproducibility.

I'm hoping that this will improve the maintainability of these packages. If any other maintainers of these recipes would like to retain any of these deprecated versions, or add new versions, speak now or forever hold your peace 😄 

---------

Co-authored-by: adamjstewart <adamjstewart@users.noreply.github.com>
2023-06-30 12:29:45 -07:00
Adam J. Stewart
d89d6dab6d Python: add new versions (#38620) 2023-06-30 14:38:11 -04:00
Dan Lipsa
e6c94e9126 XZ package (Windows): install .dll files in bin (#35888)
Windows runtime library loading searches PATH, and therefore bin/ is
the appropriate place to put .dll files. Prior to this change, XZ was
installing both .dll and .lib files to the lib/ directory.
2023-06-30 10:10:18 -07:00
Scott Wittenburg
af5b93bb97 gitlab ci: reorganize when we check for specs on mirrors (#38626)
Move the logic checking which mirrors have the specs we need closer
to where that information is needed.  Also update the staging summary
to contain a brief description of why we scheduled or pruned each
job.  If a spec was found on any mirrors, regardless of whether
we scheduled a job for it, print those mirrors.
2023-06-30 10:18:16 -06:00
Tamara Dahlgren
dc25da1931 tests/pythons: convert to new stand-alone test process (#38340) 2023-06-30 05:52:42 -04:00
Chris White
067e40591a Py-shroud: add version 0.12.2 (#38643)
* add py-shroud version

* change version number based on advice of adamjstewart
2023-06-29 23:43:08 -04:00
mschouler
483688580e py-iterative-stats: Change maintainer, add new version (#38609)
* Change maintainer, add new version and deprecate old one

* Fix style issue

* Revert deprecation

---------

Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
2023-06-29 21:06:43 -05:00
Thomas Bouvier
7448acaf98 py-nvidia-dali: add v1.27.0 (#38605)
* `py-nvidia-dali`: add v1.27.0

* Style
2023-06-29 20:47:41 -05:00
Adam J. Stewart
dfe2d5dca2 py-scipy: add v1.11.1 (#38635) 2023-06-29 18:38:48 -04:00
kwryankrattiger
b980fcff64 CI: Disable building VisIt in CI (#38642)
VisIt requires a deprecated version of Python (3.7) due to a VTK 8
dependency. Spack CI does not support building deprecated versions.
2023-06-29 17:33:40 -05:00
Adam J. Stewart
b405559e7b py-pandas: add v2.0.3 (#38636) 2023-06-29 14:13:23 -04:00
Sébastien Valat
7c5e3ddac5 numaprof: New package (version : 1.1.4) (#35271)
* numaprof: New package (version : 1.1.4)
* numaprof: Improve the deps description by adding 'type'
* numaprof: Fix maintainer semantic
2023-06-29 09:19:39 -07:00
Annop Wongwathanarat
6ffc11c46d relion: use patch from github for relion 4.0 (#38432) 2023-06-29 05:14:37 -04:00
Adam J. Stewart
a45d129f86 py-rasterio: add v1.3.8 (#38621) 2023-06-28 22:48:44 -05:00
eugeneswalker
3ccc527d74 py-pykerberos: needs krb5 for build to determine link and cflags via krb5-config binary (#38623) 2023-06-28 18:23:50 -04:00
Seth R. Johnson
51c75c6da3 openblas: do not build tests when installing (#38591)
* openblas: do not build tests when installing
* Add note about building tests
2023-06-28 17:57:08 -04:00
eugeneswalker
c3f4822f92 pruners-ninja: patch in upstream fix for spack issue #32112 (#38613) 2023-06-28 15:02:52 -04:00
Robert Cohn
ccae0ad534 [intel-tbb] support for building 2020.3 with icx (for dyninst) (#38610) 2023-06-28 14:08:12 -04:00
eugeneswalker
95fffe16a8 e4s ci: add hdf5-vol-daos (#37887)
* e4s ci: add hdf5-vol-daos

* hdf5-vol-daos: comment with failure notes
2023-06-28 08:31:59 -07:00
Seth R. Johnson
640ccf2ef9 celeritas: add patch when using geant4@10 (#38592) 2023-06-28 14:07:30 +01:00
John W. Parent
78f33bc002 Windows: Add PowerShell env support (#37951)
PowerShell requires explicit shell and env support in Spack.
This is due to the distinct differences in shell interactions between
cmd and pwsh. Add a doskey in pwsh piping 'spack' commands to a
powershell script similar to the sh function 'spack'. Add
support for PowerShell-specific shell interactions from Spack
(set/unset shell variables).
2023-06-27 18:26:51 -07:00
Xavier Delaruelle
25cc734452 environment-modules: add version 5.3.1 (#38597) 2023-06-27 21:22:53 -04:00
Adam J. Stewart
71b17a6945 geos: add v3.12.0 (#38595) 2023-06-27 16:23:51 -07:00
snehring
9425df1259 mindthegap: adding new version 2.3.0 (#38596) 2023-06-27 16:22:24 -07:00
Robert Cohn
e81076edd0 intel-oneapi-mkl: handle external mkl with external mpi (#38263) 2023-06-27 17:38:09 -04:00
Manuela Kuhn
84043d97b7 py-ruamel-yaml: add 0.17.32 and py-ruamel-yaml-clib: add 0.2.7 (#38585)
* py-ruamel-yaml: add 0.17.32 and py-ruamel-yaml-clib: add 0.2.7

* Update var/spack/repos/builtin/packages/py-ruamel-yaml/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Fix style

* Fix python dependency

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-27 16:37:28 -05:00
Adam J. Stewart
f93b61338c py-lightly: add v1.4.10 (#38594) 2023-06-27 16:37:11 -05:00
Axel Huebl
526ae84137 HDF5: is_enabled helper (ON) (#35705)
* HDF5: is_enabled helper (ON)
  Slightly generalize the `is_enabled` helper in the HDF5 package.
  `ON` is the most typical CMake bool option passed, besides many
  other possible `true` values, and should be included as a possible
  check to the config.
* Simplify
---------

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-06-27 16:42:57 -04:00
Manuela Kuhn
d960d29485 py-reportlab: add 4.0.4 (#38561) 2023-06-27 15:40:03 -05:00
Manuela Kuhn
5388ab1ac1 py-setupmeta: add 3.4.0 (#38589) 2023-06-27 13:09:12 -05:00
Manuela Kuhn
9ce075ed3d py-rst2pdf: add 0.100 (#38581) 2023-06-27 13:04:41 -05:00
Manuela Kuhn
46419502cb py-rich: add 13.4.2, py-markdown-it-py: add 3.0.0, py-mdurl: new (#38573)
* py-rich: add 13.4.2, py-markdown-it-py: add 3.0.0, py-mdurl: add new package

* Fix style
2023-06-27 13:03:40 -05:00
Manuela Kuhn
50623f6bde py-rfc3986: add 2.0.0 (#38570) 2023-06-27 12:46:35 -05:00
brian-kelley
d8922233ce kokkos-kernels: require kokkos+cuda_lambda (#38568)
(when +cuda, and on version 4.0.00 and up)
2023-06-27 10:22:57 -07:00
Adam J. Stewart
26a98f4c14 py-lightning: add v2.0.4, drop +extra (#38531)
* py-lightning: add v2.0.4, drop +extra

* Update dependencies
2023-06-27 12:01:39 -05:00
Scott Wittenburg
b6b33cfe7a ci: remove compiler bootstrapping code (#38543) 2023-06-27 10:35:19 -05:00
Luc Berger
41582f76bd Kokkos Kernels: adding release 3.7.1 and 4.0.0 (#36655)
Co-authored-by: eugeneswalker <38933153+eugeneswalker@users.noreply.github.com>
2023-06-27 08:33:29 -07:00
Tamara Dahlgren
97972d300a superlu-dist: convert to new stand-alone test process (#38188) 2023-06-27 10:44:16 -04:00
wspear
7470d14b35 Update superlu home page (#38562) 2023-06-27 08:34:12 -04:00
Tamara Dahlgren
ac825bd9d4 tests/py-genshi: convert to new stand-alone test process (#38345)
* py-genshi: convert to new stand-alone test process

* py-genshi: add run as py-setuptools deptype; remove test_testsuite comment
2023-06-27 08:33:56 -04:00
Wileam Y. Phan
e24bf70af4 Adjust cc90 to require at least CUDA 12 (#38572) 2023-06-27 08:24:12 -04:00
Dennis Klein
dfbdcaf551 fairmq: add v1.7.0 (#38550) 2023-06-27 08:19:42 -04:00
Matthieu Dorier
cc5ea14a6e cargs: add new package (#38548) 2023-06-27 08:19:19 -04:00
George Young
efd2ed750d py-bx-python: add 0.9.0 (#38419)
* py-bx-python: add 0.9.0

* remove dependency

* Remove python upper bound

* Clarify dependency requirements

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-27 08:14:37 -04:00
Harmen Stoppels
ab10b645c6 Revert "Updates to symlinking for Windows (#34701)" (#38578)
This reverts commit 66f75407d1.
2023-06-27 09:46:08 +02:00
Brian Van Essen
e79f275bc9 CachedCMakePackage: set build type (#38502)
Fixed the cached CMake package so that the build_type field is saved
in the cached configuration file.
2023-06-26 18:25:46 -07:00
Adam J. Stewart
09b4ed6c80 py-numpy: add v1.24.4 (#38555) 2023-06-26 18:28:13 -04:00
David Alexander
66f75407d1 Updates to symlinking for Windows (#34701)
* Support hardlinks/junctions on Windows systems without developer
  mode enabled
  * Generally, use of llnl.util.symlink.symlink is preferred over
    os.symlink since it handles this automatically
* Generally an error is now reported if a user attempts to create a
  symlink to a file that does not exist (this was previously allowed
  on Linux/Mac).
  * One exception to this: when Spack installs files from the source
    into their final prefix, dangling symlinks are allowed (on
    Linux/Mac - Windows does not allow this in any circumstance).
    The intent behind this is to avoid generating failures for
    installations on Linux/Mac that were succeeding before.
* Because Windows is strict about forbidding dangling symlinks,
  `traverse_tree` has been updated to skip creating symlinks if they
  would point to a file that is ignored. This check is not
  transitive (i.e., a symlink to a symlink to an ignored file would
  not be caught appropriately)
* Relocate function: resolve_link_target_relative_to_the_link
  (this is not otherwise modified)

Co-authored-by: jamessmillie <smillie@txcorp.com>
2023-06-26 13:38:14 -07:00
Manuela Kuhn
5db241c755 krb5: add missing findutils dependency (#38440)
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-06-26 20:28:50 +02:00
Xavier Delaruelle
1dcc67535a modules: ignore more Modules variables in from_sourcing_file (#38455)
Update list of excluded variables in `from_sourcing_file` function to
cover all variables specific to Environment Modules or Lmod. Add
specifically variables relative to the definition of `module()`, `ml()`
and `_module_raw()` Bash functions.

Fixes #13504
2023-06-26 20:21:46 +02:00
Carson Woods
46fe1f48bc Adds new Qthreads package version (#38421)
* Add new versions of Qthreads
* Add version URLs explicitly as it has recently changed
* Use function to extrapolate version URL for older versions
* Fix url formatter
2023-06-26 09:48:47 -04:00
kjrstory
30201e3381 Openfoam: replace two boolean variants with multi-valued variant for precision option (#37736) 2023-06-26 15:43:27 +02:00
Martin Aumüller
501bb88de2 llvm: fix build against libstdc++ 13 (#38329)
llvm @13-15 is required for ispc, but fails to build with GCC 13.
14.0.6 and 15.0.7 built successfully with upstream patch, 13.0.1
still fails. Thus upstream patch is applied to 14 and 15 only.
2023-06-26 15:42:25 +02:00
Alex Richert
c5adb05433 ufs-utils: update urls, versions, and dependencies (#37255) 2023-06-26 15:41:38 +02:00
Tamara Dahlgren
8528106484 tests/heffte/tasmanian: convert to new stand-alone test process (#35750) 2023-06-26 15:10:55 +02:00
George Young
134dceb055 cromwell: add v85 (#38427)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-26 09:08:34 -04:00
Sergey Kosukhin
aa3744299b netcdf-c: apply patches (#38324)
* netcdf-c: fix building on macOS

* netcdf-c: add patch fixing multi-threaded HDF5 calls

* netcdf-c: update patch url
2023-06-26 15:04:12 +02:00
George Young
105ac0c377 mmseqs2: patching to support building with %gcc@13: (#38296)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-26 14:59:05 +02:00
Cameron Book
1949f67a71 scotch: add new variants + bison version min. (#37958) 2023-06-26 14:55:21 +02:00
Terry Cojean
0314071763 ginkgo: add version 1.6.0 (#38439) 2023-06-26 14:13:48 +02:00
Annop Wongwathanarat
6e13d7d917 acfl: remove version 23.04 (#38363) 2023-06-26 14:02:17 +02:00
Annop Wongwathanarat
2d4758bdd9 armpl-gcc: remove version 23.04 (#38362) 2023-06-26 14:01:43 +02:00
George Young
ff002316a8 py-python-lzo: add 1.15 (#38418)
* py-python-lzo: add 1.15

* Update package.py

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-26 07:42:39 -04:00
snehring
251282812b demuxlet: add new package (#38425) 2023-06-26 13:17:01 +02:00
SXS Bot
4ac43b5032 spectre: add v2023.06.19 (#38474)
Co-authored-by: sxs-bot <sxs-bot@users.noreply.github.com>
2023-06-26 13:07:39 +02:00
Tamara Dahlgren
05b6ac16bc tests/*mpi*: convert to new stand-alone test process (#35802) 2023-06-26 12:40:03 +02:00
Xavier Delaruelle
8164712264 Add raw attribute to env.set command (#38465)
Update `env.set` command and underlying `SetEnv` object to add the `raw`
boolean attribute. `raw` is optional and set to False by default. When
set to True, value format is skipped for object when generating
environment modifications.

With this change it is now possible to define environment variable
whose value contains variable reference syntax (like `{foo}` or `{}`)
that should be set as-is.

Fixes #29578
2023-06-26 11:55:57 +02:00
Wouter Deconinck
ce0b9ea8cf acts: ensure Python_EXECUTABLE uses ^python when +python (#38540)
By default, `find_package(Python)` searches from highest version to lowest version, identifying the highest version that satisfies the requirements. This means that `/usr/bin/python3.11` will be found before `$(spack location -i python)/bin/python3.10`, even when other packages have been built with the `python` in spack.

This ensures that the `python` dependency is explicitly the `python` version that is used.
2023-06-26 11:31:48 +02:00
Adam J. Stewart
c560053c39 py-scipy: add v1.11.0 (#38546)
Co-authored-by: adamjstewart <adamjstewart@users.noreply.github.com>
2023-06-26 11:30:06 +02:00
Fabien Bruneval
5b0ca6d287 MOLGW: add new package (#37878) 2023-06-26 11:12:03 +02:00
is-a-gamer
887d356e01 bzip2: add pkg-config file (#38355)
Co-authored-by: HongZhi He <a13041902330@outlook.com>
2023-06-26 05:02:23 -04:00
Tamara Dahlgren
95ca9dea89 libxml2: convert to new stand-alone test process (#37694) 2023-06-25 01:02:33 -04:00
Cyrus Harrison
cb23362b7f ascent: add optional occa dep (#38426)
Co-authored-by: cyrush <cyrush@users.noreply.github.com>
2023-06-24 23:32:34 -04:00
George Young
42c4a8b388 gmap-gsnap: updating to 2023-06-01 (#38428)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-24 16:46:37 +02:00
Thomas Madlener
cc1f403385 circe2: add new package (#38491) 2023-06-24 16:32:15 +02:00
snehring
b1d281f197 apptainer: add squashfuse dep (#38499) 2023-06-24 16:02:51 +02:00
Tamara Dahlgren
29a1c418b3 etsf-io: convert to new stand-alone test process (#35746) 2023-06-24 15:59:48 +02:00
Wouter Deconinck
36dd325187 gaudi: new versions 36.[11-14] (#38498) 2023-06-24 15:56:02 +02:00
Tamara Dahlgren
585e150816 hpctoolkit: convert to new stand-alone test process (#35752) 2023-06-24 15:44:14 +02:00
miheer vaidya
9a30ba1a4d clp and osi depend on pkgconfig (#31505)
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
Co-authored-by: Harmen Stoppels <harmenstoppels@gmail.com>
2023-06-24 15:34:56 +02:00
David Huber
d5bb152165 GSI-ncdiag: add v1.1.0 and v1.1.1. (#38196)
Co-authored-by: [David Huber] <[david.huber@noaa.gov]>
2023-06-24 15:29:01 +02:00
Stephen Sachs
0c6d0541f0 Fix syntax to set default target in aws-pcluster pipelines (#38048)
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-06-24 15:25:19 +02:00
Dennis Klein
7b977dc103 libzmq: Fix static assertion failure with gcc-13 (#38391) 2023-06-24 13:13:17 +02:00
Matthew Thompson
f98bfebce4 pfunit: fix the max_array_rank variant definition (#38528) 2023-06-24 11:01:21 +02:00
Kapil Arya
4907315079 DMTCP: add v3.0.0. (#38307) 2023-06-24 11:00:20 +02:00
Richard Berger
48168de1cc lammps: new verisons (#38532) 2023-06-24 10:49:18 +02:00
Gurkirat Singh
d99892e490 Fixes openmpi configure args for multinode execution on slurm (#38403)
Remove `--enable-mca-no-build=btl-uct` check for ucx spec
as it is already fixed in the openmpi open-mpi/ompi#6666
2023-06-24 10:40:43 +02:00
Chris Green
09d9b48957 range-v3: remove overbroad boost dependence (#38539)
Co-authored-by: greenc-FNAL <greenc-FNAL@users.noreply.github.com>
2023-06-24 10:25:39 +02:00
Stephen Hudson
62aa9d87ee libEnsemble: add v0.10.0 (#37954)
* libEnsemble: add v0.10.0

* Make new deps required

* Fixes to deps

* Update var/spack/repos/builtin/packages/py-libensemble/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Fix build, run

* Reorder required deps

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-23 15:16:53 -05:00
Manuela Kuhn
0470fe545f py-pytest: add 7.3.2 (#38522)
* py-pytest: add 7.3.2

* [@spackbot] updating style on behalf of manuelakuhn

* Swap py-importlib-metadata dependency order

* Restrict python version for older versions
2023-06-23 15:07:38 -05:00
mschouler
db8bf333d3 Add recipe for iterative-stats (#38039)
* Add recipe for iterative-stats

* Fix branch name and remove comment

* Add git link

* Add package maintainer

* Enforce multiple requested changes

* Update var/spack/repos/builtin/packages/py-iterative-stats/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update checksum

* Fix openturns dependency specification

* Add python variant spec to openturns

---------

Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-23 15:07:04 -05:00
julian-zeidler
f73c8f2255 Added version 0.33 (#38534) 2023-06-23 14:17:38 -04:00
G-Ragghianti
42ed4d81b7 fix version dependency logic (#38535) 2023-06-23 11:08:56 -07:00
Harmen Stoppels
e76b039997 zlib-ng: add latest, default to drop in replacement of zlib (#37370) 2023-06-23 14:02:38 -04:00
Gurkirat Singh
b49d098e3f Add numa variant in ucx package (#38423) 2023-06-23 07:08:09 -04:00
Harmen Stoppels
cd67b2a1a9 spack buildcache sync (--manifest-glob <glob> | <src> <dest>) are mutually exclusive (#38533) 2023-06-23 12:20:48 +02:00
Manuela Kuhn
a076548bd4 py-pytz: add 2023.3 (#38525) 2023-06-22 23:03:28 -04:00
Juan Miguel Carceller
3d342ac69a py-qmtest: add patch for the removed bdist_wininst class (#38253)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-06-22 22:48:24 -04:00
Manuela Kuhn
88fc8ae591 py-python-gitlab: add 3.15.0 (#38524) 2023-06-22 22:43:15 -04:00
Paul R. C. Kent
ff6ac42812 Add 1606 (#38511) 2023-06-22 16:14:25 -07:00
snehring
c96f93b2a3 Emblmygff3 (#38515)
* py-bcbio-gff: adding new version 0.7.0

* emblmygff3: adding new package

* emblmygff3: adding py-setuptools dep
2023-06-22 16:50:11 -05:00
Alec Scott
cbe4a48291 rust: Add v1.70.0 and simplify package bootstrap (#38311)
* Add rust v1.70.0 and simplify package logic by moving bootstrap to dedicated package

* Fix formatting of rust-bootstrap package file

* Re-enable Rust as extendable

* Add nightly version to rust and rust-bootstrap

* Manually inject openssl certs into environment

* Add master and beta versions to rust

* Add additional documentation for using rust development releases

* Remove @AndrewGaspar as maintainer
2023-06-22 14:03:52 -07:00
Manuela Kuhn
ebd41134fe py-packaging: add 23.1 (#38417) 2023-06-22 16:29:49 -04:00
AMD Toolchain Support
77817a0f05 VASP package: Zen4 Support (#36800)
* zen4 support for vasp
* encourage openmp support in fftw/blas when +openmp
* enable gamma and non-collinear builds
2023-06-22 16:08:21 -04:00
Michael Kuhn
590d3ba6cf freefem: add missing dependencies (#38290)
Also remove the custom `autoreconf` method as it does not seem to be
necessary and potentially hides useful output provided by the default.
2023-06-22 11:48:00 -07:00
Manuela Kuhn
1e8988f11d py-notebook: add 6.5.4 (#38415)
* py-notebook: add 6.5.4

* [@spackbot] updating style on behalf of manuelakuhn

* Update var/spack/repos/builtin/packages/py-notebook/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Fix version of py-nbclassic dependency

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-22 12:14:38 -04:00
Ondřej Čertík
a889669cbc Add LFortran (#30901)
It installs the LFortran runtime library and
LFortran can compile codes to binaries. The interactive mode does not
work yet with LLVM > 11, that has to be fixed upstream.

Co-authored-by: Wileam Y. Phan <50928756+wyphan@users.noreply.github.com>
2023-06-22 09:51:29 -06:00
Manuela Kuhn
fde33e66be py-numexpr: add 2.8.4 (#38416) 2023-06-22 07:53:43 -04:00
mschouler
6314ddacf2 open turns: Add libxml2 dependency and increase version to v1.20 (#38038)
* Add libxml2 dependency and increase version to v1.20

* Update var/spack/repos/builtin/packages/openturns/package.py

Co-authored-by: Alec Scott <alec@bcs.sh>

* Add v19

* Add libxml2 variant

* Fix variant specification

---------

Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
Co-authored-by: Alec Scott <alec@bcs.sh>
2023-06-22 06:27:59 -04:00
Manuela Kuhn
f935f36b21 py-platformdirs: add 3.5.3 (#38435)
* py-platformdirs: add 3.5.3

* py-typing-extensions: add 4.6.3
2023-06-22 05:54:17 -04:00
Manuela Kuhn
082934f73f py-prompt-toolkit: add 3.0.38 (#38472) 2023-06-22 04:04:23 -04:00
Manuela Kuhn
3e9e01e496 py-patsy: add 0.5.3 (#38433) 2023-06-22 04:04:00 -04:00
Wouter Deconinck
2abbfe719d qt: new version 5.15.10 (#38489)
No changes to the build system, no changes to `package.py` needed.

Changelog: https://github.com/qt/qtbase/compare/v5.15.9-lts-lgpl...v5.15.10-lts-lgpl

Main change taking up space:
- bundled 3rdparty/pcre2 updated from 10.39 to 10.40 (spack now includes 10.42, and we don't put specific version requirements in `package.py`)
2023-06-22 03:43:58 -04:00
Mikael Simberg
ace20c5d29 hpx: Add conflict with some GCC versions and +rocm due to valarray bug (#38297)
* hpx: Add conflict with some GCC versions and +rocm due to valarray bug

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103022

* remove conflict for %gcc@11.1.0 since there is none

---------

Co-authored-by: eugeneswalker <eugenesunsetwalker@gmail.com>
2023-06-22 03:38:45 -04:00
Adam J. Stewart
f35fcee6be py-pyproj: add v3.6.0 (#38399) 2023-06-22 03:14:08 -04:00
Manuela Kuhn
103370d84a py-networkx: add 3.1 (#38377)
* py-networkx: add 3.1

* Update var/spack/repos/builtin/packages/py-networkx/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Add default variant

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-22 03:09:13 -04:00
Wouter Deconinck
6e47f1645f opencascade: typo in True (#38487)
Not sure why flake8 didn't catch this as an undefined name, e.g. https://www.flake8rules.com/rules/F823.html.
2023-06-22 02:39:20 -04:00
Seth R. Johnson
53eb6c46db Add VecGeom 1.2.3 and mark old versions as deprecated (#38483)
Co-authored-by: Ben Morgan <drbenmorgan@users.noreply.github.com>
2023-06-22 02:38:59 -04:00
miheer vaidya
00d769d644 add new package: daemonize (#38477) 2023-06-22 02:28:52 -04:00
Rémi Lacroix
b6b34aa0fe IQ-TREE: Add version 2.2.2.7 (#38481) 2023-06-22 02:24:13 -04:00
Seth R. Johnson
83b9196e78 celeritas: new version 0.3.0 (#38438) 2023-06-22 02:23:50 -04:00
Wouter Deconinck
ed76eab694 geant4: new version 11.1.2 (#38475)
No changes required to the geant4 package.py file.

Changes: https://gitlab.cern.ch/geant4/geant4/-/compare/v11.1.1...v11.1.2

Release notes: https://geant4.web.cern.ch/download/release-notes/notes-v11.1.2.txt

Co-authored-by: Ben Morgan <drbenmorgan@users.noreply.github.com>
2023-06-22 02:18:50 -04:00
Tamara Dahlgren
930b843885 tests/py-chainer: convert to new stand-alone test process (#38365)
* tests/py-chainer: convert to new stand-alone test process
* py-chainer: add skip_modules entry for onnx_chainer
2023-06-22 01:51:42 -04:00
Manuela Kuhn
f53c68e005 py-pycairo: add 1.24.0 (#38503)
* py-pycairo: add 1.24.0

* Change python dependency to 3.8

* Remove upper bound for python dependency

* Update var/spack/repos/builtin/packages/py-pycairo/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-21 16:47:35 -04:00
George Young
12a22eebc7 tetranscripts: new package @2.2.3 (#38485)
* tetranscripts: new package @2.2.3

* tidying up

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-21 15:43:48 -04:00
Matthieu Dorier
69eb15936c [tclap] Adds new versions to tclap package (#38508) 2023-06-21 15:34:22 -04:00
shanedsnyder
c69dea5465 darshan-runtime,darshan-util,py-darshan: add 3.4.3 releases (#38359)
* add darshan 3.4.3 releases

* darshan-runtime 3.4.3
* darshan-util 3.4.3
* py-darshan 3.4.3.0
  - add py-humanize as new dependency

* py-darshan has strict darshan-util version reqs

darshan-util version required is based on the first 3 parts of
the py-darshan version string

* remove support for python3.6

* py-humanize dependency for 3.4.3+ versions

* only enforce scipy dependency for 3.4.0.1

* drop optional lxml dependency

* drop matplotlib pinning

* importlib-resources not a dep in python-3.7+

* drop unnecessary numpy pin

* add build dep for pytest-runner

* fix typo in pytest-runner package name

* pip setuptools to match pydarsan setup.py

* spack style fix
2023-06-21 14:31:17 -05:00
miheer vaidya
3bd8c4df28 neovim: add v0.9.(0|1) (#38463) 2023-06-21 15:07:37 -04:00
Manuela Kuhn
02dc697831 py-prometheus-client: add 0.17.0 (#38471) 2023-06-21 13:34:04 -04:00
Manuela Kuhn
87cb39b860 py-gsutil: add 5.24, fix and add dependencies (#38450)
* py-gsutil: add 5.24, fix and add dependencies

* Update var/spack/repos/builtin/packages/py-httplib2/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Add httplib2@0.20.4 and pin it in py-gsutil

* Add py-cryptography conflict

* Update var/spack/repos/builtin/packages/py-httplib2/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* py-pyopenssl: fix py-cryptography conflict

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-21 13:33:42 -04:00
Erik Heeren
468138bb4f mpich: undefined variable dso_suffix (#37373)
* mpich: undefined variable dso_suffix

* mpich: formatting

---------

Co-authored-by: Nichols A. Romero <naromero77@users.noreply.github.com>
2023-06-21 11:12:05 -05:00
Adam J. Stewart
a8534b7345 py-lightly: add v1.4.8 (#38397)
* py-lightly: add v1.4.8

* Fix typo

* Update deps as well

* typing-extensions dep needed earlier

Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>

* Runtime dep on setuptools removed in master

---------

Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>
2023-06-21 11:47:24 -04:00
Manuela Kuhn
8ba45b0b99 py-pygments: add 2.15.1 (#38505) 2023-06-21 10:33:03 -05:00
Manuela Kuhn
6ae358edd8 py-pydicom: add 2.4.1 (#38504) 2023-06-21 10:30:47 -05:00
Manuela Kuhn
5ce45e0cee py-psutil: add 5.9.5 (#38479)
* py-psutil: add 5.9.5

* Remove unneeded windows dependencies
2023-06-21 15:26:53 +00:00
George Young
b2901f1737 bulker: new package @0.7.3 (#38437)
* py-bulker: new package at 0.7.3

* bulker: renaming package

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-21 10:21:01 -05:00
Rocco Meli
6b552dedbc Add MDAnalysis and MDAnalysisTests to 2.5.0 (#37968)
* update mda and mdatests

* black

* Update var/spack/repos/builtin/packages/py-mdanalysis/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-mdanalysis/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* polish

* Update var/spack/repos/builtin/packages/py-mdanalysistests/package.py

* fixes

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-21 10:08:48 -05:00
Christian Mauch
6b3d2c535f py-tensorboard(-plugin-wit): remove unused patch files (#38360) 2023-06-21 10:08:12 -05:00
Adam J. Stewart
2727bd92d8 py-numpy: add v1.25.0 (#38461) 2023-06-21 10:03:50 -05:00
Martin Pokorny
ebbfc0363b kokkos-nvcc-wrapper: add new versions (#38446) 2023-06-20 21:38:30 -04:00
Tamara Dahlgren
1b6e1fc852 tests/superlu: convert to new stand-alone test process (#38404)
* superlu: convert to new stand-alone test process
* Bugfix/superlu: add BaseBuilder and move post-install work to it
2023-06-20 16:46:11 -07:00
Matthieu Dorier
1376ec4887 [mochi-margo] margo version 0.14.0 added (#38473) 2023-06-20 18:48:21 -04:00
Stephen Sachs
0eec7c5c53 [WRF] Always use compiler wrappers for FFLAGS/FCFLAGS (#38470)
`FFLAGS` and `FCFLAGS` are being ignored by WRF build system. Not only in version
`3.9.1.1`, but also `4.x`.

Also, I see no reason to explicitly add `-w` and `-O2` to compile lines when
using `gcc@10:`. Tested for version `3.9.1.1`, `4.2.2`, & `4.5.0`.

Tagging original authors of this part @MichaelLaufer and @giordano in case they
want to chime in.
2023-06-20 18:24:31 -04:00
Valentin Volkl
05dd240997 fastjet: add v3.4.1, update patch (#38467) 2023-06-20 18:16:37 -04:00
Erik Schnetter
fb16c81b6c mpiwrapper: New version 2.10.4 (#38448) 2023-06-20 18:16:15 -04:00
Erik Schnetter
7c3b33416f mpitrampoline: New version 5.3.1 (#38449) 2023-06-20 18:08:00 -04:00
snehring
6755b74d22 ncbi-rmblastn: switching urls from ftp to https (#38490) 2023-06-20 16:03:48 -04:00
George Young
d0e843ce03 ncbi-rmblastn: patching to support building with %gcc@13: (#38382)
* ncbi-rmblastn: patching to support building with %gcc@13:
* ncbi-rmblastn: patching to build with %gcc@13:

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-20 12:42:22 -07:00
George Young
37f6231f2a py-umi-tools: add 1.1.4, add py-pybktree dependency (#38394)
* py-umi-tools: add 1.1.4, add py-pybktree dependency

* remove python spec

* Remove `six` dependency

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-20 15:35:12 -04:00
snehring
d85f25a901 apptainer: adding version 1.1.9 (#38492) 2023-06-20 15:20:48 -04:00
Manuela Kuhn
2041b92d3a py-pybids: add 0.16.1 (#38480) 2023-06-20 11:22:24 -05:00
Valentin Volkl
f461069888 root: fix variant detection (#38436) 2023-06-20 08:47:49 -05:00
Manuela Kuhn
9eb3de85c5 py-pre-commit: add 3.3.3 (#38468)
* py-pre-commit: add 3.3.3

* Update var/spack/repos/builtin/packages/py-pre-commit/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-19 18:30:42 -04:00
Manuela Kuhn
92d970498a py-nodeenv: add 1.8.0 (#38383)
* py-nodeenv: add 1.8.0

* Remove python@3.7 restriction
2023-06-19 18:01:43 -04:00
Manuela Kuhn
bd5e99120d py-pkginfo: add 1.9.6 (#38434)
* py-pkginfo: add 1.9.6

* Remove py-setuptools as run dependency
2023-06-19 17:39:14 -04:00
Juan Miguel Carceller
a7e307bd81 gsl: set GSL_ROOT_DIR (#38464)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-06-19 16:37:37 -04:00
snehring
55152781cb repeatmasker: adding version 4.1.5 (#38445) 2023-06-19 11:13:27 -07:00
Manuela Kuhn
8ce0c7771c py-pooch: add 1.7.0 (#38466) 2023-06-19 12:43:19 -05:00
Wouter Deconinck
7e0dfa270f spdlog: patch for fmt::basic_runtime when ^fmt@10 (#38082) 2023-06-19 12:15:01 +02:00
Andrey Parfenov
7dc485d288 cc: Ensure that user-specified flags take precedence over others (#37376)
Spack flags supplied by users should supersede flags from package build systems and
other places in Spack.  However, Spack currently adds user-supplied flags to the 
beginning of the compile line, which means that in some cases build system flags will
supersede user-supplied ones.

The right place to add a flag to ensure it has highest precedence for the compiler really
depends on the type of flag.  For example, search paths like `-L` and `-I` are examined
in order, so adding them first is highest precedence.  Compilers take the *last* occurrence
of optimization flags like `-O2`, so those should be placed *after* other such flags.  Shim
libraries with `-l` should go *before* other libraries on the command line, so we want
user-supplied libs to go first, etc.

`lib/spack/env/cc` already knows how to split arguments into categories like `libs_list`,
`rpath_dirs_list`, etc., so we can leverage that functionality to merge user flags into
the arg list correctly.

The general rules for injected flags are:

1. All `-L`, `-I`, `-isystem`, `-l`, and `*-rpath` flags from `spack_flags_*` to appear
   before their regular counterparts.
2. All other flags ordered with the ones from flags after their regular counterparts,
   i.e. `other_flags` before `spack_flags_other_flags`

- [x] Generalize argument categorization into its own function in the `cc` shell script
- [x] Apply the same splitting logic to injected flags and flags from the original compile line.
- [x] Use the resulting flag lists to merge user- and build-system-supplied flags by category.
- [x] Add tests.

Signed-off-by: Andrey Parfenov <andrey.parfenov@intel.com>

Co-authored-by: iermolae <igor.ermolaev@intel.com>
2023-06-18 14:07:08 -07:00
simonleary-umass-edu
5c6c3b403b fix oneapi modules (#38400) 2023-06-18 07:17:19 -04:00
Morten Kristensen
242854f266 py-vermin: add latest version 1.5.2 (#38460)
* py-vermin: add latest version 1.5.2

* Removed obsolete dep and setuptools is only for build-time

- setuptools are not used as runtime
- py27 isn't strictly necessary
2023-06-18 03:52:58 -04:00
William Moses
e9406a7d9e Add latest enzyme release (#38442) 2023-06-17 03:12:14 -04:00
Greg Becker
0ac1c52d17 unparser: drop Python 2, fix testing bugs with newer Pythons (#38424)
The `unparser` that Spack uses for package hashing had several tweaks to ensure compatibility
with Python 2.7:
1. Currently, the unparser automatically moves `*` and `**` args to the end to preserve
   compatibility with `python@:3.4`
2. `print a, b, c` statements and single-tuple `print((a, b, c))` function calls were
   remapped to `print(a, b, c)` in the unparsed output for consistency across versions.

(1) is causing issues in our tests because a recent patch to the Python source code  
(https://github.com/python/cpython/pull/102953/files#diff-7972dffec6674d5f09410c71766ac6caacb95b9bccbf032061806ae304519c9bR813-R823) 
has a `**` arg before an named argument, and we round-trip the core python source code
as a test of our unparser.  This isn't actually a break with our consistent unpausing -- it's still
consistent, the python source just doesn't unparse to the same thing anymore. It does makes
it harder to test, so it's not worth maintaining the Python2-specific stuff anymore.

Since we only support `python@3.6:`, this PR removes (1) and (2) from the unparser, but keeps
one last tweak for unicode AST inconsistencies, as it's still needed for Python 3.5-3.7.

This fixes the CI error we've been seeing on `python@3.11.4` and `python@3.10.12`. Again, that
bug exists only in the test system and doesn't affect our canonical hashing of Python code.
2023-06-16 20:52:26 -04:00
Manuela Kuhn
a3c42715db py-aiohttp: add 3.8.4 (#38451) 2023-06-16 16:49:45 -04:00
Alec Scott
0f27188383 millepede: add v04-13-03 (#38141) 2023-06-16 11:12:01 -07:00
Greg Becker
99f3b9f064 show external status as [e] (#33792) 2023-06-16 18:22:28 +02:00
Axel Huebl
d1bc4c4ef1 WarpX 23.06 (#38303)
* WarpX 23.06

Update WarpX and related Python packages to the lastest releases.

WarpX 23.06 introduces multi-dimension support in a single package,
which will ease deployment in E4S et al. that can ship now a single,
full-feature module/package that is NOT incompatible with itself
anymore.

* e4s ci stacks: multiple specs for each dim variant no longer required

* [@spackbot] updating style on behalf of ax3l

* WarpX: Update CMake CLI and Test/Check

* Add Missing `build-directory`

* [@spackbot] updating style on behalf of ax3l

* Remove `build_directory` again

---------

Co-authored-by: eugeneswalker <eugenesunsetwalker@gmail.com>
Co-authored-by: ax3l <ax3l@users.noreply.github.com>
2023-06-16 06:47:59 -07:00
Gurkirat Singh
69a5c55702 docs: add quotes around some values in a YAML example (#38412) 2023-06-16 10:29:09 +02:00
Larry Knox
2972d5847c Remove experimental hdf5 versions 1.13.x and add hdf5 version 1.10.10. (#38013)
* Remove experimental hdf5 versions 1.13.x.
Upgrade to 1.14 or remove dependencies on hdf5 1.13.x.

* Revert change to netcdf-c/package.py.
2023-06-15 22:41:39 -05:00
George Young
1577eb9602 star: add 2.7.10 (#38197)
* star: add 2.7.10
* star: fix building for non-avx2 arch processors
* convert to MakefilePackage, second take at fixing for aarch64
* style

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-15 12:53:32 -07:00
George Young
2f97c6ead2 perl-gd: update to 2.77, update urls (#38413)
* perl-gd: update to 2.77, update urls

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-15 12:39:57 -07:00
markus-ferrell
1df4afb53f Enable build system guess tests on windows (#36971) 2023-06-15 11:40:09 -07:00
Adam J. Stewart
4991f0e484 MXNet: fix flag versions (#38402) 2023-06-15 11:34:21 -07:00
markus-ferrell
09fd7d68eb Windows testing: enable graph, mark, and info cmd tests (#36977) 2023-06-15 11:28:52 -07:00
Jacob King
2ace8a55c1 Create package.py file for NIMROD abstract accelerated infrastructure. (#38405)
Co-authored-by: jacobrking <jacobrking@users.noreply.github.com>
2023-06-15 11:24:55 -07:00
Manuela Kuhn
861acb9467 py-nibabel: add 5.1.0 (#38379) 2023-06-15 13:14:26 -05:00
Thomas Madlener
eea743de46 podio: Add py-tabulate as new run and test dependency (#38409) 2023-06-15 10:56:00 -07:00
George Young
e2b6e5a7ec py-numba: add 0.57.0, update dependency ranges (#38390)
* py-numba: add 0.57.0, update dependency ranges

* Update var/spack/repos/builtin/packages/py-numba/package.py

Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>

* Update var/spack/repos/builtin/packages/py-numba/package.py

Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>

* Update package.py

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>
2023-06-15 12:39:12 -05:00
Manuela Kuhn
2f2dc3695c py-datalad: add 0.18.4 (#37936) 2023-06-15 12:22:45 -05:00
Tamara Dahlgren
6eb5e57199 tests/py-horovod: convert to new stand-alone test process (#38366) 2023-06-15 12:17:09 -05:00
Tamara Dahlgren
9a047eb95f tests/py-libensemble: convert to new stand-alone test process (#38344) 2023-06-15 12:09:57 -05:00
Tamara Dahlgren
ef42fd7a2f tests/py-eccodes: convert to new stand-alone test process (#38346) 2023-06-15 11:58:00 -05:00
Manuela Kuhn
e642c2ea28 py-neurora: add 1.1.6.10 (#38378) 2023-06-15 11:14:28 -05:00
Massimiliano Culpo
f27d012e0c Add virtual information on DAG edges (#34821)
* DependencySpec: add virtuals attribute on edges

This works for both the new and the old concretizer. Also,
added type hints to involved functions.

* Improve virtual reconstruction from old format

* Reconstruct virtuals when reading from Cray manifest

* Reconstruct virtual information on test dependencies
2023-06-15 07:16:54 -07:00
Tamara Dahlgren
c638311796 test/dust: convert to new stand-alone test process (#38367) 2023-06-14 20:27:35 -07:00
Manuela Kuhn
2a02bea405 py-nbclient: add 0.8.0 (#38325) 2023-06-14 17:31:03 -05:00
Manuela Kuhn
219b42d991 py-nbconvert: add 7.4.0 (#38326)
* py-nbconvert: add 7.4.0

* Move historical dependencies after variant
2023-06-14 17:28:30 -05:00
Manuela Kuhn
c290ec1f62 py-docutils: re-add python@3.7 (#38336) 2023-06-14 17:19:27 -05:00
Satish Balay
e7ede86733 magma@master: add python dependency (#38341) 2023-06-14 17:15:40 -05:00
Thomas Madlener
e3e7609af4 edm4hep: Add version 0.9 (#38205) 2023-06-14 16:53:31 -04:00
Dennis Klein
49d7ebec36 fairmq: Add v1.6.0 (#38392) 2023-06-14 16:47:59 -04:00
Alec Scott
7c3d82d819 ltp: add v20230516 (#38138) 2023-06-14 16:27:27 -04:00
George Young
1c0fbec9ce subread: add 2.0.6, update download paths (#38200)
* subread: add 2.0.6, update download paths
* Update var/spack/repos/builtin/packages/subread/package.py

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-06-14 13:20:29 -07:00
kjrstory
ca4d60ae25 openradioss-starter,engine: new package (#38291)
* openradioss-starter,engine: new package
* openradioss-engine: change version name develop to main
* openradioss-starter: change version name develop to main
2023-06-14 13:04:03 -07:00
Alec Scott
dc571e20d6 freeipmi: add v1.6.9 (#38349) 2023-06-14 13:02:02 -07:00
Kim Liegeois
1485275d0c Add Binder spackage (#38371)
* Add Binder spackage
* Format binder recipe
* Format binder recipe
2023-06-14 12:41:35 -07:00
pabloaledo
1afbf72037 add bioconductor-ebseq (#38380)
* add buiconductor-ebseq
  Signed-off-by: Pablo <pablo.aledo@seqera.io>

---------

Signed-off-by: Pablo <pablo.aledo@seqera.io>
2023-06-14 12:40:57 -07:00
Rémi Lacroix
407fd80f95 ctffind: Add a patch to fix incorrect return types. (#38085)
Prevent the code from crashing (cf. https://grigoriefflab.umassmed.edu/comment/1696#comment-1696).
2023-06-14 12:29:41 -07:00
Tamara Dahlgren
62525d9076 dsqss: convert to new stand-alone test process (#38372) 2023-06-14 11:54:47 -07:00
Alec Scott
c2371263d1 lastz: add v1.04.22 (#38388)
* lastz: add v1.04.22

* Fix formatting of versions to include extra space
2023-06-14 10:05:45 -07:00
Alec Scott
5a870182ec ipopt: add v3.14.9 (#38387) 2023-06-14 10:04:54 -07:00
Alec Scott
e33ad83256 imath: add v3.1.9 (#38386) 2023-06-14 10:03:41 -07:00
Alec Scott
0352a1df5d imagemagick: add v7.1.1-11 (#38385) 2023-06-14 10:02:36 -07:00
Alec Scott
ade44bce62 cgal: add v5.5.2 (#38384) 2023-06-14 10:01:33 -07:00
Mark W. Krentel
ddb29ebc34 intel-xed: add version 2023.06.07 (#38373)
Add version 2023.06.07, update python to 3.7.
2023-06-14 09:46:53 -07:00
Mark W. Krentel
19a62630e5 hpcviewer: add version 2023.05 (#38374) 2023-06-14 09:45:21 -07:00
Alec Scott
5626802aa0 cloc: add v1.96.1 (#38348) 2023-06-14 12:28:08 -04:00
kwryankrattiger
f68063afbc DaV: Drop propagation of HDF5 to darshan (#38361)
Darshan Runtime does not properly link symols for HDF5 when using shared
libraries.
2023-06-14 11:02:18 -05:00
Alec Scott
8103d019d6 hbase: add v2.5.4 (#38353) 2023-06-14 11:47:53 -04:00
Alec Scott
ce89cdd9d7 fzf: add v0.41.1 (#38351) 2023-06-14 11:38:02 -04:00
Alec Scott
20d9b356f0 hashcat: add v6.2.6 (#38352) 2023-06-14 11:32:56 -04:00
Alec Scott
3401438a3a hyperfine: add v1.17.0 (#38354) 2023-06-14 11:23:20 -04:00
Alec Scott
dcf1999d22 ftxui: add v4.1.1 (#38350) 2023-06-14 11:16:13 -04:00
snehring
9e3c3ae298 Repeatmodeler 2.0.4 (#38337)
* perl-devel-size: adding new package
* repeatmodeler: adding new version 2.0.4
* perl-devel-size: adding proper description
2023-06-14 11:10:50 -04:00
Tamara Dahlgren
40d6b84b4d dssp: convert to new stand-alone test process (#38368) 2023-06-14 07:27:49 -07:00
Xavier Delaruelle
2db09f27af modules: use depends-on to autoload module with Lmod on Tcl (#38347)
Update Tcl modulefile template to use the `depends-on` command to
autoload modules if Lmod is the current module tool.

Autoloading modules with `module load` command in Tcl modulefile does
not work well for Lmod at some extend. An attempt to unload then load
designated module is performed each time such command is encountered. It
may lead to a load storm that may not end correctly with large number of
module dependencies.

`depends-on` command should be used for Lmod instead of `module load`,
as it checks if module is already loaded, and does not attempt to reload
this module.

Lua modulefile template already uses `depends_on` command to autoload
dependencies. Thus it is already considered that to use Lmod with Spack,
it must support `depends_on` command (version 7.6+).

Environment Modules copes well with `module load` command to autoload
dependencies (version 3.2+). `depends-on` command is supported starting
version 5.1 (as an alias of `prereq-all` command) which was relased last
year.

This change introduces a test to determine if current module tool that
evaluates modulefile is Lmod. If so, autoload dependencies are defined
with `depends-on` command. Otherwise `module load` command is used.

Test is based on `LMOD_VERSION_MAJOR` environment variable, which is set
by Lmod starting version 5.1.

Fixes #36764
2023-06-14 15:35:53 +02:00
dependabot[bot]
6979d6a96f build(deps): bump python-levenshtein in /lib/spack/docs (#38339)
Bumps [python-levenshtein](https://github.com/maxbachmann/python-Levenshtein) from 0.21.0 to 0.21.1.
- [Release notes](https://github.com/maxbachmann/python-Levenshtein/releases)
- [Changelog](https://github.com/maxbachmann/python-Levenshtein/blob/main/HISTORY.md)
- [Commits](https://github.com/maxbachmann/python-Levenshtein/compare/v0.21.0...v0.21.1)

---
updated-dependencies:
- dependency-name: python-levenshtein
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-14 13:03:15 +02:00
dependabot[bot]
deffd2acc9 build(deps): bump docker/build-push-action from 4.1.0 to 4.1.1 (#38369)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4.1.0 to 4.1.1.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](44ea916f6c...2eb1c1961a)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-14 09:48:57 +02:00
dependabot[bot]
988f71f434 build(deps): bump docker/setup-buildx-action from 2.6.0 to 2.7.0 (#38370)
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2.6.0 to 2.7.0.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](6a58db7e0d...ecf95283f0)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-14 09:36:41 +02:00
kjrstory
4fe76f973a SU2: add versions up to 7.5.1, update dependencies (#37767)
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-06-13 18:33:10 -04:00
Raffaele Solcà
8e4e6ad529 add DLA-Future package (#38224) 2023-06-13 18:03:13 -04:00
Edoardo Aprà
3586a2dbe3 NWChem: fix fftw3 variant + patch (#38250) 2023-06-13 22:43:39 +02:00
Dan Lipsa
4648939043 Windows bugfix: path-to-URL conversion (#37827)
When interpreting local paths as relative URL endpoints, they were
formatted as Windows paths on Windows (i.e. with '\'). URLs should
always be POSIX-style.
2023-06-13 10:08:09 -07:00
Xavier Delaruelle
746eaaf01a modules: append trailing delimiter to MANPATH when set (#36678)
Update modulefile templates to append a trailing delimiter to MANPATH
environment variable, if the modulefile sets it.

With a trailing delimiter at ends of MANPATH's value, man will search
the system man pages after searching the specific paths set.

Using append-path/append_path to add this element, the module tool
ensures it is appended only once. When modulefile is unloaded, the
number of append attempt is decreased, thus the trailing delimiter is
removed only if this number equals 0.

Disclaimer: no path element should be appended to MANPATH by generated
modulefiles. It should always be prepended to ensure this variable's
value ends with the trailing delimiter.

Fixes #11355.
2023-06-13 10:29:11 +02:00
Alberto Sartori
bd2f78ae9a justbuild: bump version 1.1.2 (#38320) 2023-06-12 21:34:38 -04:00
Alec Scott
a4ebe01dec curl: add v8.1.2 (#38332) 2023-06-12 19:34:24 -04:00
Alex Richert
94e9e18558 Update sp package (#38208) 2023-06-12 17:51:57 -04:00
Alec Scott
d2e0ac4d1f cpp-httplib: add v0.12.5 (#38331) 2023-06-12 14:51:11 -07:00
Alec Scott
36321fef1c direnv: add v2.32.3 (#38333) 2023-06-12 14:48:06 -07:00
Alec Scott
e879877878 etcd: add v3.5.9 (#38334) 2023-06-12 14:46:43 -07:00
Alec Scott
f0bce3eb25 fastp: add v0.23.4 (#38335) 2023-06-12 14:45:45 -07:00
Wouter Deconinck
316bfd8b7d opencascade: new variants (#35345)
* opencascade: new variants

OpenCascade has several major modules and not every
application needs all of them. This adds variants for
the various modules.

It also uodatws the 3rdparty dependency treatment.

* [@spackbot] updating style on behalf of wdconinc

* Update var/spack/repos/builtin/packages/opencascade/package.py

* opencascade: remove variant foundation_classes (always true)

* [@spackbot] updating style on behalf of wdconinc

* Update var/spack/repos/builtin/packages/opencascade/package.py

---------

Co-authored-by: wdconinc <wdconinc@users.noreply.github.com>
2023-06-12 11:56:55 -05:00
Jerome Soumagne
92593fecd5 mercury: add v2.3.0 (#38279)
* fix Boost dependency

* fix testing and move psm2/sockets as unsupported

* fix style to separate maintainers/tags/version
2023-06-12 08:51:22 -07:00
MatthewLieber
8db5fecdf5 mvapich2: add hwloc_graphics variant (#38028)
Co-authored-by: Matthew Lieber <lieber.31@osu.edu>
2023-06-12 17:25:10 +02:00
Niclas Jansson
eee696f320 neko: add v0.6.0 and fixed rocm package recipe (#38024) 2023-06-12 17:17:12 +02:00
willdunklin
8689cf392f mochi-margo: correct patch versions (#38087) 2023-06-12 17:13:52 +02:00
Bruno Turcksin
15d4cce2eb Add new Kokkos release (#38049) 2023-06-12 17:08:51 +02:00
Peter Scheibel
45fbb82d1a pip is a pythonextension not a pythonpackage, and it turns out we werent doing our external surgery on things that inherited pythonextension (#38186) 2023-06-12 17:07:28 +02:00
Adam J. Stewart
2861c89b89 Deprecate R packages for spatial analysis (#38158)
* Deprecate R packages for spatial analysis

* [@spackbot] updating style on behalf of adamjstewart

---------

Co-authored-by: adamjstewart <adamjstewart@users.noreply.github.com>
2023-06-12 15:55:40 +02:00
Alec Scott
135bfeeb27 libtlx: add v0.6.1 (#38134) 2023-06-12 15:54:50 +02:00
Alec Scott
8fa9c66a7d ccache: add v4.8.1 (#38114) 2023-06-12 15:54:27 +02:00
snehring
5e6174cbe2 cdhit: add missing perl dep, patch shebangs (#38179) 2023-06-12 15:51:59 +02:00
MichaelLaufer
b4ad883b0d wrf: add v4.5.0 (#37618) 2023-06-12 15:48:54 +02:00
Juan Miguel Carceller
a681111a23 whizard: add tirpc/lib to the link flags (#38050)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-06-12 15:24:27 +02:00
Manuela Kuhn
d2436afb66 gdb: fix debuginfod for version 10 (#38058) 2023-06-12 15:20:45 +02:00
Martin Pokorny
e43444cbb6 kokkos: fix c++20 constraint (#37555) 2023-06-12 15:07:03 +02:00
nkgh77
8c0d947114 FrontISTR: relax the requirement on Trillinos (#38321) 2023-06-12 15:02:21 +02:00
Thomas Madlener
5ba4a2b83a podio: bump minimal version of catch2 (#38255) 2023-06-12 08:47:48 -04:00
Harmen Stoppels
da45073ef9 buildcache: remove deprecated api (#37246)
The API was deprecated in v0.20 and is slated for removal in v0.21
2023-06-12 14:33:26 +02:00
kwryankrattiger
61e17fb36d DaV: Use VTKm for all build configurations of ParaView (#38184) 2023-06-12 14:25:50 +02:00
Wouter Deconinck
9f13a90dd2 superlu: new version 6.0.0 (#38262)
No changes to build system required. Changelog: https://github.com/xiaoyeli/superlu/compare/v5.3.0...v6.0.0

Since this new version adds "64-bit indexing support", and since at least one dependent package (`armadillo`) requires "32-bit integers" (faa6cbf895), the previous version remains preferred.

* [@spackbot] updating style on behalf of wdconinc

---------

Co-authored-by: wdconinc <wdconinc@users.noreply.github.com>
2023-06-12 14:23:42 +02:00
Juan Miguel Carceller
ef4b35ea63 gaudi: remove the py-qmtest dependency (#38274)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-06-12 14:22:21 +02:00
George Young
66187c8a6e orthofinder: add 2.5.5, add variants (#38298)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-12 14:13:15 +02:00
Massimiliano Culpo
c8d95512fc bootstrap: add minimum versions required for flake8 and pytest (#38322) 2023-06-12 12:29:35 +02:00
George Young
c74fa648b9 fastq-screen: add 0.15.3, add variants (#38288)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-12 10:37:51 +02:00
snehring
4cc5e9cac6 ltr-retriever 2.9.4 (#38300) 2023-06-12 10:05:44 +02:00
snehring
41345d18f9 perl-libwww-perl: adding perl-clone dependency (#38301) 2023-06-12 10:04:29 +02:00
Alec Scott
0dd1316b68 alglib: add v4.00.0 (#38313) 2023-06-12 09:46:24 +02:00
Alec Scott
d8cc185e22 bismark: add v0.24.1 (#38315) 2023-06-12 09:45:53 +02:00
Alec Scott
061051270c blogbench: add v1.2 (#38316) 2023-06-12 09:45:42 +02:00
Alec Scott
61445159db consul: add v1.15.3 (#38317) 2023-06-12 09:45:30 +02:00
Christopher Christofi
7fa3c7f0fa Fix typo in example code block (#38318) 2023-06-11 22:12:36 -04:00
Manuela Kuhn
9c0fe30f42 py-mypy: add 1.3.0 (#38286)
* py-mypy: add 1.3.0

* Remove redundant py-typed-ast dependency

* Read python@3.7 dep
2023-06-11 15:22:55 -04:00
George Young
d00010819f py-deeptools: add 3.5.2, update dependency versions (#38287)
* py-deeptools: add 3.5.2, update dependency versions

* Update var/spack/repos/builtin/packages/py-deeptools/package.py

Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>

* Update var/spack/repos/builtin/packages/py-deeptools/package.py

Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>

* Rearranging dependencies to match setup.py

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Manuela Kuhn <36827019+manuelakuhn@users.noreply.github.com>
2023-06-11 15:17:52 -04:00
Manuela Kuhn
248b05b32a py-jedi: add 0.18.2 (#38177)
* py-jedi: add 0.18.2

* Add setuptools as run dependency
2023-06-11 15:12:56 -04:00
dependabot[bot]
8232e934e9 build(deps): bump docker/login-action from 2.1.0 to 2.2.0 (#38241)
Bumps [docker/login-action](https://github.com/docker/login-action) from 2.1.0 to 2.2.0.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](f4ef78c080...465a07811f)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-11 13:36:31 -05:00
dependabot[bot]
9d005839af build(deps): bump docker/setup-buildx-action from 2.5.0 to 2.6.0 (#38242)
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2.5.0 to 2.6.0.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](4b4e9c3e2d...6a58db7e0d)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-11 13:36:02 -05:00
dependabot[bot]
a7e5c73608 build(deps): bump docker/setup-qemu-action from 2.1.0 to 2.2.0 (#38243)
Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 2.1.0 to 2.2.0.
- [Release notes](https://github.com/docker/setup-qemu-action/releases)
- [Commits](e81a89b173...2b82ce82d5)

---
updated-dependencies:
- dependency-name: docker/setup-qemu-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-11 13:35:42 -05:00
dependabot[bot]
7896625919 build(deps): bump urllib3 from 2.0.2 to 2.0.3 in /lib/spack/docs (#38244)
Bumps [urllib3](https://github.com/urllib3/urllib3) from 2.0.2 to 2.0.3.
- [Release notes](https://github.com/urllib3/urllib3/releases)
- [Changelog](https://github.com/urllib3/urllib3/blob/main/CHANGES.rst)
- [Commits](https://github.com/urllib3/urllib3/compare/2.0.2...2.0.3)

---
updated-dependencies:
- dependency-name: urllib3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-11 13:35:22 -05:00
dependabot[bot]
fb43cb8166 build(deps): bump sphinx-rtd-theme in /lib/spack/docs (#38245)
Bumps [sphinx-rtd-theme](https://github.com/readthedocs/sphinx_rtd_theme) from 1.2.1 to 1.2.2.
- [Changelog](https://github.com/readthedocs/sphinx_rtd_theme/blob/master/docs/changelog.rst)
- [Commits](https://github.com/readthedocs/sphinx_rtd_theme/compare/1.2.1...1.2.2)

---
updated-dependencies:
- dependency-name: sphinx-rtd-theme
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-11 13:35:03 -05:00
dependabot[bot]
28f68e5d11 build(deps): bump docker/build-push-action from 4.0.0 to 4.1.0 (#38306)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](3b5e8027fc...44ea916f6c)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-11 13:34:44 -05:00
dependabot[bot]
1199eeed0b build(deps): bump docker/build-push-action from 4.0.0 to 4.1.0 (#38306)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](3b5e8027fc...44ea916f6c)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-11 13:34:33 -05:00
Manuela Kuhn
8ffeb4900b py-multidict: add 6.0.4 (#38284) 2023-06-11 12:03:21 -05:00
Manuela Kuhn
456550da3f py-mne: add 1.4.2 (#38228) 2023-06-11 11:52:01 -05:00
Olivier Cessenat
b2676fe2dd Gxsview new version 2023.05.29 (#38310)
* netpbm: new version 10.73.43

* gxsview: new version 2023.05.29
2023-06-11 09:48:04 -07:00
Jen Herting
8561ec6249 [py-spacy-legacy] New package (#38276) 2023-06-11 11:45:23 -05:00
Jen Herting
5b775d82ac [py-spacy-loggers] new package (#38275) 2023-06-11 11:44:19 -05:00
Jen Herting
b43088cc16 [py-langcodes] new package (#38273) 2023-06-11 11:43:16 -05:00
Manuela Kuhn
237eab136a py-nbclassic: add 1.0.0 and py-notebook-shim: add 0.2.3 (#38289) 2023-06-11 11:36:38 -05:00
Marie Houillon
ffffa2794b New version for openCARP packages, v13.0 (#37940)
* New version for openCARP packages

* Update carputils dependencies

* Update types of openCARP dependencies

* Add type "run" to setuptools dependency

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Add package py-common as carputils dependency

* Add setuptools dependency for py-common

* Remove spaces on blank line

* Restrict type of dependency setuptools to "build"

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: openCARP consortium <info@opencarp.org>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-11 11:25:41 -05:00
George Young
433b44403f py-pybktree: new package (#38209)
* py-pykbtree: new package

* py-pybktree: new package

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-11 11:16:33 -05:00
Manuela Kuhn
fa2e1c0653 py-pandas: exchange import_modules with skip_modules (#38227) 2023-06-11 11:14:56 -05:00
Manuela Kuhn
00257f6824 py-more-itertools: add 9.1.0 (#38229) 2023-06-11 11:14:43 -05:00
kjrstory
3b8366f3d3 slurm: add new version(23.02.2, 22.05.9) (#38285) 2023-06-10 18:48:48 -07:00
dependabot[bot]
a73f511404 build(deps): bump actions/checkout from 3.5.2 to 3.5.3 (#38305)
Bumps [actions/checkout](https://github.com/actions/checkout) from 3.5.2 to 3.5.3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](8e5e7e5ab8...c85c95e3d7)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-10 18:45:37 -07:00
Vanessasaurus
c823e01baf Automated deployment to update package flux-core 2023-06-10 (#38308)
Co-authored-by: github-actions <github-actions@users.noreply.github.com>
2023-06-10 18:30:10 -07:00
Carson Woods
4188080899 Add new Podman package versions and fix patch (#38234)
* Add new podman versions and correct the versions which patch is applied to
* Replace the existing maintainer with alecbcs at maintainers request
2023-06-10 20:40:58 +02:00
Fabien Bruneval
ef6ea2c93f correct SHA for ABINIT 9.8.3 and add ABINIT 9.8.4 (#38283) 2023-06-09 12:24:28 -07:00
Greg Becker
3c672905d0 install status arg: update to default true and add inverse (#38252)
* install status arg: update to default true and add inverse

* update bash completion

* fix tests broken by output change
2023-06-09 10:38:05 -07:00
Jen Herting
ee106c747f [py-typer] new package (#38270)
* [py-typer] new package

* [py-typer] added version 0.7.0
2023-06-09 12:10:09 -05:00
Jen Herting
295726e6b8 [py-catalogue] added version 2.0.8 (#38266) 2023-06-09 12:01:04 -05:00
afzpatel
2654d64a3c comgr: enable testing (#35605) 2023-06-09 18:04:19 +02:00
Stephen Sachs
d91ec8500f [gromacs] Fix intel (classic) libstdc++ path (#37822)
* [gromacs] Fix intel (classic) libstdc++ path

Gromacs's `cmake` run will look for `--gcc-toolchain` (e.g. LLVM, icpx) or
`--gcc-name` (e.g. icpc) in `CMAKE_CXX_FLAGS`. Only if it does not find a good
g++ candidate there it will look for `GMX_GPLUSPLUS_PATH`:
cb6b311c39/cmake/FindLibStdCpp.cmake (L97)

Spack installed intel compilers already define a g++ for std libs. But in
`icp{c,x}.cfg` instead of the compile line. If we use the pre-defined g++ we not
only have less chance of mixing g++ versions, but also don't need to explicitly
add `gcc` as dependency to `gromacs`.

* Fix format

* Use a variant

As there is no way to check if a file exists at depends_on stage

* Fix format

* New name and fail if variant is used with other compiler

* Line too long.
2023-06-09 09:17:49 -04:00
Jonathon Anderson
c354cc51d0 containerize: use an ENTRYPOINT script (#37769) 2023-06-09 09:25:13 +02:00
Massimiliano Culpo
d5747a61e7 Hotfix to avoid building compilers from sources in pcluster pipelines (#38256)
The pcluster image has am internal buildcache without an index.

Also, we need to force reuse to avoid rebuilding GCC, since the default is 
to only reuse dependencies - and that is subject to changes in the GCC 
recipe.
2023-06-09 07:56:28 +02:00
Chris White
e88c747abc BLT package: add version 0.5.3 (#38247) 2023-06-09 00:36:00 -04:00
Martin Pokorny
cfe9e5bca4 glab: add new versions (#38236)
* glab: add new versions

* Update var/spack/repos/builtin/packages/glab/package.py

Co-authored-by: Alec Scott <alec@bcs.sh>

---------

Co-authored-by: Alec Scott <alec@bcs.sh>
2023-06-08 20:36:16 -07:00
Manuela Kuhn
48f7655a62 py-mako: add 1.2.4 (#38194) 2023-06-08 19:10:02 -04:00
Manuela Kuhn
a1111a9858 py-lxml: add 4.9.2 (#38191) 2023-06-08 19:09:41 -04:00
Manuela Kuhn
b8b9a798bf py-looseversion: add 1.2.0 (#38190) 2023-06-08 19:03:05 -04:00
Manuela Kuhn
7a1e94c775 py-msgpack: add 1.0.5 (#38230) 2023-06-08 18:02:42 -04:00
Manuela Kuhn
8c4b2173d2 py-mistune: add 2.0.5 (#38214) 2023-06-08 17:43:51 -04:00
George Young
4c4cd7b3ea py-llvmlite: add 0.40.0, update llvm dependency information (#38171)
* py-llvmlite: add 0.40.0, update llvm dependency information

* Update var/spack/repos/builtin/packages/py-llvmlite/package.py

Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>

* Update var/spack/repos/builtin/packages/py-llvmlite/package.py

Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>

* Update var/spack/repos/builtin/packages/py-llvmlite/package.py

Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>

* Update var/spack/repos/builtin/packages/py-llvmlite/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-08 16:10:48 -05:00
George Young
e92554414b gatk: add 4.4, update to java@17 (#38211)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-08 16:01:56 -04:00
George Young
d165e2c94b bowtie2: add 2.5.1 (#38201)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-08 16:01:34 -04:00
George Young
a97bd31afe trimgalore: add 0.6.10, adding variants (#38206)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-08 15:55:03 -04:00
George Young
d7719b26f9 seqtk: add 1.4 (#38193)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-08 15:48:54 -04:00
Manuela Kuhn
855c0fd9e0 py-markupsafe: add 2.1.3 (#38198) 2023-06-08 15:37:26 -04:00
Daniele Cesarini
4156397027 New packages: eprosima-fastdds and dependencies (#38079) 2023-06-08 12:27:06 -07:00
Juan Miguel Carceller
b4bbe5e305 ocaml: don't use the spack compiler (#38251)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-06-08 12:17:29 -07:00
Adam J. Stewart
f5b595071e py-lightning: add v2.0.3 (#38260) 2023-06-08 15:14:28 -04:00
George Young
b6f2184cce bedtools2: patching to build with gcc@13 (#38254)
* bedtools2: patching to build with gcc@13

* bedtools2: patching to build with gcc@13

* Update var/spack/repos/builtin/packages/bedtools2/package.py

Yep, sure. Makes sense.

Co-authored-by: Alec Scott <alec@bcs.sh>

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Alec Scott <alec@bcs.sh>
2023-06-08 14:59:01 -04:00
Axel Huebl
9288067380 Mold: 1.11.0 (#38235)
* Mold: 1.11.0

Add the latest release of the `mold` linker.

* SHA for 1.7.1: zip to tar
2023-06-08 11:34:57 -07:00
Massimiliano Culpo
ddfc43be96 Forbid using env: as a top level environment attribute (#38199)
* Remove "env" from environment schema

* Remove spack.env.schema.keys

* Remove spack.environment.config_dict
2023-06-08 14:34:17 -04:00
Adam J. Stewart
63cad5d338 py-lightly: add v1.4.7 (#38259) 2023-06-08 14:04:16 -04:00
Ivan Maidanski
436ecdfb19 bdw-gc: add v8.2.4 (#37969)
* bdw-gc: add v8.2.4
* bdw-gc: Fix download URL for old package versions

---------

Co-authored-by: Tamara Dahlgren <dahlgren1@llnl.gov>
2023-06-08 14:03:57 -04:00
John W. Parent
06817600e4 CMake/Windows bugfix: Make CMAKE_INSTALL_PREFIX a posix path (#36842)
CMake gives off a warning when passed Windows style paths as
install prefixes as the resultant path often causes invalid
escape sequences.
2023-06-08 10:05:38 -07:00
Wouter Deconinck
4ae1a73d54 (r-rcpp)ensmallen: new package (#38249)
* ensmallen: new package
  ensmallen is a high-quality C++ library for non-linear numerical optimization.
* r-rcppensmallen: new package

---------

Co-authored-by: wdconinc <wdconinc@users.noreply.github.com>
2023-06-08 09:53:02 -07:00
Massimiliano Culpo
f29aab0d03 Fix compiler removal from command line (#38057)
* Improve lib/spack/spack/test/cmd/compiler.py

* Use "tmp_path" in the "mock_executable" fixture

* Return a pathlib.Path from mock_executable

* Fix mock_executable fixture on Windows

"mock_gcc" was very similar to mock_executable, so use the latter to reduce code duplication

* Remove wrong compiler cache, fix compiler removal

fixes #37996

_CACHE_CONFIG_FILES was both unneeded and wrong, if called
subsequently with different scopes.

Here we remove that cache, and we fix an issue with compiler
removal triggered by having the same compiler spec in multiple
scopes.
2023-06-08 09:38:20 -07:00
eugeneswalker
cea1b3123e e4s oneapi ci: use official intel oneapi-derived runner image (#38176)
* e4s oneapi ci: use official intel oneapi-derived runner image

* update oneapi image

* tau builds ok, but only with libdrm - comment out for now, follow up with pr later
2023-06-08 09:17:22 -07:00
Alec Scott
b22ccf279d junit4: add v4.13.2 (#38122) 2023-06-08 11:54:09 -04:00
Wouter Deconinck
81e15ce36e (r-rcpp)armadillo: new version 12.4.0 (#38246)
* armadillo: new version 12.4.0
   No build system changes necessary, https://gitlab.com/conradsnicta/armadillo-code/-/compare/12.2.x...12.4.x
* r-rcpparmadillo: new version 0.12.4.0.0
2023-06-08 11:49:17 -04:00
George Young
8907e52933 bismark: add 0.24.1, add HISAT2 dependency (#38210)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-06-08 11:49:00 -04:00
Carlos Bederián
80cefedac5 quantum-espresso: add 7.2 (#38223) 2023-06-08 11:23:54 -04:00
Seth R. Johnson
b85a66f77a trilinos: drop preferred version (#38086) 2023-06-08 11:18:44 -04:00
Alec Scott
a0ba3d890a cni-plugins: add v1.3.0 (#38064) 2023-06-08 10:27:20 +02:00
Manuela Kuhn
315873cbd3 py-keyring: add 23.13.1 (#38183)
* py-keyring: add 23.13.1

* [@spackbot] updating style on behalf of manuelakuhn
2023-06-07 23:00:05 -05:00
Thomas Bouvier
e05095af90 py-nvidia-dali: update versions up to v1.26.0 (#38022)
* `py-nvidia-dali`: update versions up to v1.26.0

* Add proper `cuda` dependency version
2023-06-07 22:52:52 -05:00
Thomas Bouvier
e0d6a73f96 py-horovod: add versions v0.27.0 and v0.28.0 (#38016)
* `py-horovod`: add versions v0.27.0 and v0.28.0

* fix: typo

* Add upper version bound for `py-pyarrow`
2023-06-07 22:51:19 -05:00
Manuela Kuhn
6ebfb41ad9 py-json5: add 0.9.14 (#38178) 2023-06-07 22:16:28 -05:00
Manuela Kuhn
d0aa01c807 py-jaraco-classes: add 3.2.3 (#38167) 2023-06-07 21:48:58 -05:00
Manuela Kuhn
1265c7df47 py-jupyter-client: add 8.2.0 (#38180) 2023-06-07 21:48:12 -05:00
Alec Scott
91e3f14959 hbase: add v2.5.3 (#38073) 2023-06-07 18:11:21 -07:00
Alec Scott
5f03eb650d chemfiles: add v0.10.4 (#38063) 2023-06-07 18:05:37 -07:00
Martin Pokorny
e0e6133444 casacore: add v3.5.0 (#37806) 2023-06-07 23:12:08 +02:00
Nate deVelder
ee68baf254 OpenFAST: add v3.3.0, v3.4.0 and v3.4.1 (#37407) 2023-06-07 23:10:39 +02:00
Christopher Kotfila
785c1a2070 Add documentation about package signing model (#30939)
Co-authored-by: Scott Wittenburg <scott.wittenburg@kitware.com>
Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
2023-06-07 23:05:44 +02:00
Dan Lipsa
79656655ba Guard for define in netcdf 4.9.0 and later. (#37853)
* Guard for define in netcdf 4.9.0 and later.

This code is already available in ParaView 5.11.0 so no patching
needed there.

* Add latest needed version (even if not in spack).

---------

Co-authored-by: Dan Lipsa <dan.lipsa@khq.kitware.com>
2023-06-07 14:20:27 -05:00
Sajid Ali
74921788a8 llvm: add new versions and set default for libomptarget according to os (#38092)
* llvm: add new versions and set default for libomptarget according to os

	modified:   var/spack/repos/builtin/packages/llvm/package.py

* Incorporate reviewer suggestions

Co-authored-by: Sergey Kosukhin <skosukhin@gmail.com>

---------

Co-authored-by: Sergey Kosukhin <skosukhin@gmail.com>
2023-06-07 10:55:46 -05:00
Carlos Bederián
b313b28e64 nwchem: remove -mtune=native flags (#37892)
Co-authored-by: Edoardo Aprà <edoardo.apra@gmail.com>
2023-06-07 09:02:35 +02:00
eugeneswalker
5f1bc15e80 E4S Cray CI Stack (#37837)
* e4s cray ci stack

* e4s ci: add cray

* add zen4 tag

* WIP: new defintions just for cray

* updates

* remove ci signing job overrride, not necessary

* echo $PATH and show modules loaded

* add mirror

* add external def for cray-libsci

* comment out quantum-espresso

* use /etc/protected-runner as key path

* cray ci stack: do not remove tags: [spack, public]

* make cray stack composable

* generate job should run on public tagged runner, override default config:install_tree:root

* CI: Use relative path in default script

* CI: Use relative includes paths for shell runners

* Use concrete_env_dir for relpath

* ml-darwin-aarch64-mps: jax has bazel codesign issue

---------

Co-authored-by: Scott Wittenburg <scott.wittenburg@kitware.com>
Co-authored-by: Ryan Krattiger <ryan.krattiger@kitware.com>
2023-06-06 18:41:32 -07:00
Mikael Simberg
fa9fb60df3 CachedCMakePackage: fix bug where CMAKE_CUDA_ARCHITECTURES=none is set (#38169)
#37592 updated cached cmake packages to set CMAKE_CUDA_ARCHITECTURES.
The condition `if archs != "none"` lead to `CMAKE_CUDA_ARCHITECTURES=none`
when cuda_arch=none (incorrect check on the value of a multi-valued
variant), i.e. CMAKE_CUDA_ARCHITECTURES is always set. This PR udpates
the condition to if archs[0] != "none" to ensure CMAKE_CUDA_ARCHITECTURES
is only set if cuda_arch is not none (which seems to be the pattern used
in other packages).

This does the same for HIP (although in general ROCmPackage disallows
amdgpu_target=none when +rocm).
2023-06-06 14:41:02 -07:00
Mosè Giordano
e759e6c410 julia: Update patch for llvm 14 without binary files (#37959) 2023-06-06 21:53:20 +02:00
Jonathon Anderson
f41446258a containers: don't install epel-release on Fedora (#37766) 2023-06-06 21:50:46 +02:00
Erik Schnetter
268649654d openssl: add versions 1.1.1u, 3.0.9, 3.1.1 (#38023) 2023-06-06 21:49:01 +02:00
Diego Alvarez S
12e249f64e Add nextflow 23.04.1 (#38166) 2023-06-06 12:12:50 -07:00
Tamara Dahlgren
c34cd76f2a perl: convert to new stand-alone test process (#37727) 2023-06-06 12:07:44 -07:00
Tamara Dahlgren
815b210fc8 tests/ginkgo: converted to new stand-alone test process (#35730)
* Ginkgo: converted to new stand-alone test process

* ginkgo: update string formatting, compiler setting
2023-06-06 11:58:53 -07:00
Tamara Dahlgren
e5d5efb4c1 tests/darshan-util: convert to new stand-alone test process (#37836) 2023-06-06 11:56:40 -07:00
Tamara Dahlgren
0aa4b4d990 tests/oommf: convert to new stand-alone test process (#38009)
* oommf: convert to new stand-alone test process

* oommf: Switch build-time tests to documented approach
2023-06-06 11:55:33 -07:00
Tamara Dahlgren
01c1d334ae tests/mfem: convert to new stand-alone test process (#38011)
* mfem: convert to new stand-alone test process
* Restore make target, use config_mk property
2023-06-06 11:42:51 -07:00
Massimiliano Culpo
717fc11a46 Don't build rocky:9 images for ppc64le (#38202)
See https://docs.rockylinux.org/release_notes/9_2/
2023-06-06 17:46:53 +02:00
eugeneswalker
d21c49e329 @develop+stokhos: do not set Stokhos_ENABLE_PCE_Scalar_Type=False (#38187) 2023-06-06 08:32:21 -07:00
Tamara Dahlgren
6937d9dddc eigenexa: convert to new stand-alone test process (#35745) 2023-06-06 15:08:51 +02:00
Thomas Bouvier
4c2531d5fb libraqm: add missing fribidi dependency (#36125)
* `libraqm`: add missing `fribidi` dependency
* `libraqm`: add `sheenbidi` variant
* [@spackbot] updating style on behalf of thomas-bouvier

---------

Co-authored-by: thomas-bouvier <thomas-bouvier@users.noreply.github.com>
2023-06-05 18:13:42 -04:00
Alex Richert
62fd890c52 Rename fpic variant to pic for fms (#38101) 2023-06-05 14:58:52 -07:00
Alex Richert
4772fd7723 Add MADIS package (#38097)
* Add MADIS package
* madis update
* [@spackbot] updating style on behalf of AlexanderRichert-NOAA
* allow arg mismatch for gcc@10: for madis
2023-06-05 14:31:51 -07:00
snehring
7c11faceb0 ninja-phylogeny: adding new package ninja-phylogeny (#38182) 2023-06-05 16:44:51 -04:00
Alec Scott
053550e28a asdcplib: add v2_10_38 (#37971) 2023-06-05 12:46:19 -07:00
Alec Scott
3ed7258447 fjcontrib: add v1.052 (#38116) 2023-06-05 14:25:30 -05:00
Manuela Kuhn
a5cf5baa9e py-jupyterlab: add 4.0.1 incl. new dependencies (#38102) 2023-06-05 13:54:20 -05:00
Alec Scott
ec8039cc74 seal: add v4.1.1 (#38155) 2023-06-05 11:46:40 -07:00
snehring
9bfa840c27 ncbi-rmblastn: adding new version 2.14.0 (#38173)
* ncbi-rmblastn: adding new version 2.14.0
* ncbi-rmblastn: add maintainer
2023-06-05 11:45:15 -07:00
Alec Scott
9865f42335 azcopy: add v10.19.0 (#38106) 2023-06-05 10:56:34 -07:00
Alec Scott
dba2829871 hssp: add v3.1.5 (#38107) 2023-06-05 10:51:30 -07:00
Alec Scott
8c0e1fbed9 diamond: add v2.1.7 (#38115) 2023-06-05 10:46:39 -07:00
Alec Scott
187488b75b optional-lite: add v3.5.0 (#38148) 2023-06-05 10:24:37 -07:00
Alec Scott
2aa35fef3e nccmp: add v1.9.1.0 (#38142) 2023-06-05 10:15:25 -07:00
Nathalie Furmento
d373fc36ae starpu: add release 1.3.11 (#38172) 2023-06-05 09:12:40 -07:00
Massimiliano Culpo
e483762015 Update RtD and Sphinx configuration (#38046) 2023-06-05 17:39:11 +02:00
Houjun Tang
5840a00000 Update package.py require HDF5 1.14+ (#38026) 2023-06-05 11:27:53 -04:00
George Young
110f836927 fastqc: add 0.12.1, update patch files (#37934)
* fastqc: add 0.12.1

* fastqc: add 0.12.1

* Update var/spack/repos/builtin/packages/fastqc/package.py

Yeah, had considered doing the same, I'd just opted to maintain the status quo. All good.

Co-authored-by: Alec Scott <alec@bcs.sh>

* Update package.py

Style fiddles to make the bot contented.

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Alec Scott <alec@bcs.sh>
2023-06-05 11:07:51 -04:00
Weiqun Zhang
d6765f66ae amrex: add version 23.06 (#38056) 2023-06-05 07:44:32 -07:00
Alec Scott
19dac780e8 iozone: add v3_506 (#38118) 2023-06-05 13:00:23 +02:00
Alec Scott
b82b549c59 iqtree2: add v2.2.2 (#38119) 2023-06-05 13:00:06 +02:00
Alec Scott
b376401ece jimtcl: add v0.82 (#38120) 2023-06-05 12:59:48 +02:00
Alec Scott
7d956dbe9e jline3: add v3.22.0 (#38121) 2023-06-05 12:59:32 +02:00
Alec Scott
6db1d84bb0 kubernetes: add v1.27.2 (#38123) 2023-06-05 12:58:47 +02:00
Alec Scott
2094fa3056 simde: add v0.7.6 (#38157) 2023-06-05 06:38:46 -04:00
Alec Scott
3d255bc213 leptonica: add v1.83.1 (#38125) 2023-06-05 12:36:16 +02:00
Alec Scott
5538dda722 libcint: add v5.3.0 (#38127) 2023-06-05 12:36:02 +02:00
Alec Scott
1c0d89bf25 libeatmydata: add v131 (#38128) 2023-06-05 12:35:46 +02:00
Alec Scott
4cc0199fbb libibumad: add v46.0 (#38130) 2023-06-05 12:35:33 +02:00
Alec Scott
edb8226fff librdkafka: add v2.1.1 (#38131) 2023-06-05 12:35:20 +02:00
Alec Scott
ef972cf642 libspiro: add v20221101 (#38132) 2023-06-05 12:35:03 +02:00
Alec Scott
50c13541e4 libgd: add v2.3.3 (#38129) 2023-06-05 06:29:32 -04:00
Alec Scott
fd5d7cea6e perl-math-bigint: add v1.999838 (#38150) 2023-06-05 06:29:15 -04:00
Alec Scott
526314b275 laszip: add v3.4.3 (#38124) 2023-06-05 06:29:00 -04:00
Alec Scott
7b37c30019 libthai: add v0.1.29 (#38133) 2023-06-05 11:28:44 +02:00
Alec Scott
dc03c3ad9e libvori: add v220621 (#38135) 2023-06-05 11:26:58 +02:00
Alec Scott
61b485f75d lsscsi: add v0.32 (#38136) 2023-06-05 11:26:42 +02:00
Alec Scott
e24151783f ltp: add v20230127 (#38137) 2023-06-05 11:25:55 +02:00
Alec Scott
ed9714e5ae mariadb-c-client: add v3.3.5 (#38140) 2023-06-05 11:25:22 +02:00
Alec Scott
ea620a083c nco: add v5.1.6 (#38143) 2023-06-05 11:24:54 +02:00
Alec Scott
504a8be666 nettle: add v3.9.1 (#38144) 2023-06-05 11:24:34 +02:00
Alec Scott
d460870c77 ngmlr: add v0.2.7 (#38145) 2023-06-05 11:24:19 +02:00
Alec Scott
f0f77251b3 nim: add v1.9.3 (#38146) 2023-06-05 11:24:00 +02:00
Alec Scott
bdd454b70b openexr: add v3.1.7 (#38147) 2023-06-05 11:23:26 +02:00
Alec Scott
aea6662774 pgdspider: add v2.1.1.5 (#38151) 2023-06-05 11:22:41 +02:00
Alec Scott
fe6bcb36c7 primer3: add v2.6.1 (#38152) 2023-06-05 11:22:22 +02:00
Alec Scott
2474a2efe1 sbt: add v1.8.3 (#38154) 2023-06-05 11:22:06 +02:00
Alec Scott
4cfd49019c signify: add v31 (#38156) 2023-06-05 11:20:04 +02:00
Alec Scott
7beae8af30 madx: add v5.09.00 (#38139) 2023-06-05 11:19:37 +02:00
Umashankar Sivakumar
22fc5d2039 papi: update git URL (#38042) 2023-06-05 11:13:17 +02:00
Alec Scott
b70fc461a4 at-spi2-core: add v2.48.3 (#38162) 2023-06-05 11:09:57 +02:00
Alec Scott
e756436d7c grep: add v3.11 (#38163) 2023-06-05 11:09:34 +02:00
Alec Scott
8dd87e2572 hugo: add v0.112.7 (#38164) 2023-06-05 11:09:12 +02:00
Manuela Kuhn
853bf95bd2 py-ipython: add 8.14.0 (#38113) 2023-06-04 22:18:00 -04:00
Manuela Kuhn
1c80d07fd2 py-iso8601: add 1.1.0 (#38110) 2023-06-04 22:07:43 -04:00
Manuela Kuhn
6fd8001604 py-ipykernel: add 6.23.1 (#38111) 2023-06-04 21:52:55 -04:00
Pariksheet Nanda
c08f9fd6fc py-jaxlib: patch bazel server cpu limit (#37548) (#38090) 2023-06-04 19:28:41 -04:00
Adam J. Stewart
c3fb998414 GMT: add new versions (#37921)
* GMT: add new versions

* [@spackbot] updating style on behalf of adamjstewart

---------

Co-authored-by: adamjstewart <adamjstewart@users.noreply.github.com>
2023-06-04 18:00:49 -05:00
George Young
3368a98210 py-htseq: add 2.0.3, switch to PyPI (#37935)
* py-htseq: add 0.12.3, switching over to new GitHub repo

* py-htseq: add 0.12.3, switching over to new GitHub repo

Style fixes

* py-htseq: add 2.0.3, switch to PyPI

* py-htseq: add 2.0.3, switch to PyPI

* Update package.py

* Update var/spack/repos/builtin/packages/py-htseq/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Removing SWIG

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-04 17:55:16 -05:00
Manuela Kuhn
606b7c7f16 py-hatch-fancy-pypi-readme: add 23.1.0 (#38075) 2023-06-04 17:30:33 -05:00
Manuela Kuhn
2f4e66be09 py-hatchling: add 1.17.0 (#38076) 2023-06-04 17:29:40 -05:00
Manuela Kuhn
9ce3e8707c py-humanize: add 4.6.0 (#38077) 2023-06-04 17:28:45 -05:00
Manuela Kuhn
d6a96745ee py-identify: add 2.5.24 (#38088) 2023-06-04 17:27:47 -05:00
Manuela Kuhn
a0fcdd092b py-imageio: add 2.30.0 (#38089) 2023-06-04 17:27:08 -05:00
Christoph Junghans
e17d09e607 votca: stable branch was removed (#38043) 2023-06-04 17:26:02 -05:00
Manuela Kuhn
847d67f223 py-gast: add 0.5.4 (#38054)
* py-gast: add 0.5.4

* py-pythran: add 0.12.2 and restict upper bound of py-gast
2023-06-04 17:25:35 -05:00
Alec Scott
7ae0e06a62 libbson: add v1.23.4 (#38126) 2023-06-04 16:33:51 -05:00
Alec Scott
d3df97df8b hyperfine: add v1.16.1 (#38108) 2023-06-04 12:45:51 +02:00
Sergey Kosukhin
7d5d075809 llvm: optionally build compiler-rt, libcxx and libunwind as runtimes (#32476)
* llvm: replace +omp_as_runtime with omp=runtime

* llvm: fetch 'libomp-libflags-as-list.patch' from upstream repo

* llvm: replace 'llvm14-hwloc-ompd.patch' with the official fix from upstream repo

* llvm: fix-up for the black reformatting

* llvm: fetch 'constexpr_longdouble.patch' from upstream repo

* llvm: optionally build libcxx as a runtime

* llvm: fetch 'llvm5-sanitizer-ustat.patch' from upstream repo

* llvm: update 'sanitizer-ipc_perm_mode.patch'

* llvm: refactor compiler conflicts when libcxx=project

* llvm: fetch 'llvm_python_path.patch' from upstream repo

* llvm: update comments and condition for 'xray_buffer_queue-cstddef.patch'

* llvm: optionally build compiler-rt as a runtime

* llvm: fetch 'lldb_external_ncurses-10.patch' from upstream repo

* llvm: fetch 'llvm_py37.patch' from upstream repo

* llvm: rename variant 'internal_unwind' to 'libunwind'

* llvm: optionally build libunwind as a runtime

* llvm: extend the list of maintainers

* llvm: allow for explicit '~clang~flang~libomptarget~lldb~omp_debug~z3'

* llvm: fetch 'llvm5-lld-ELF-Symbols.patch' from FreeBSD port repo

* llvm: fetch most of 'missing-includes.patch' from upstream repo and reuse 'llvm-gcc11.patch'

* llvm: regroup patches for missing include directives and drop compiler constraints for them

* llvm: fetch 'llvm-gcc11.patch' from upstream repo

* llvm: fetch 'no_cyclades.patch' from upstream repo

* llvm: update comments and condition for 'no_cyclades9.patch'

* llvm: rename variant 'omp' to 'openmp'

* llvm: constrain and rename variant 'omp_tsan' to 'libomp_tsan'

* llvm: rename variant 'omp_debug' to 'libomptarget_debug'

* llvm: do not apply same patch twice

* llvm: constrain and document the '*-thread.patch' patches

* llvm: document the '~lld+libomptarget' conflict

* llvm: update comments for the 'D133513.diff' patch
2023-06-03 23:08:10 -05:00
Peter Scheibel
237a0d8999 Add explicit CMake .libs implementation that returns an empty list; same for .headers (#35816) 2023-06-03 18:08:02 -07:00
Alec Scott
6952ed9950 c-blosc: add v1.21.4 (#37973) 2023-06-03 13:52:43 -04:00
Thomas Madlener
3e2d1bd413 lcio: Add latest version 2.20 (#38078) 2023-06-03 10:35:17 -07:00
Martin Aumüller
9dfba4659e botan: checksum new versions and enable external find (#38081)
* botan: checksum new versions, including new major

version 3 breaks API

* botan: support external find
2023-06-03 10:33:59 -07:00
Michael Kuhn
7fca252aa4 sqlite: add 3.42.0 (#38091) 2023-06-03 10:30:25 -07:00
Wouter Deconinck
fa23a0228f py-hatch-fancy-pypi-readme: depends_on when typo (#38103) 2023-06-03 09:57:03 -05:00
Massimiliano Culpo
ed76966a3a gnupg: add v2.4.2 (#38059)
* gnupg: add v2.4.2

* [@spackbot] updating style on behalf of alalazo

---------

Co-authored-by: alalazo <alalazo@users.noreply.github.com>
2023-06-02 09:28:54 -07:00
willdunklin
2015a51d1a sz: add versions v2.1.12.5 and v2.1.12.4 (#38060) 2023-06-02 09:28:05 -05:00
Manuela Kuhn
34b8fe827e py-flask: add 2.3.2, py-blinker: add 1.6.2, py-werkzeug: add 2.3.4 (#38025) 2023-06-02 05:57:22 -04:00
Manuela Kuhn
6f1ed9b2e4 py-exceptiongroup: add 1.1.1 (#38018) 2023-06-02 05:47:49 -04:00
M. Eric Irrgang
dd00f50943 Add py-gmxapi version 0.4.2 (#38053) 2023-06-02 03:07:34 -04:00
Sam Grayson
f0ec625321 singularityce: add v3.11.3 (#38055) 2023-06-02 08:04:39 +02:00
Manuela Kuhn
d406c371a8 py-formulaic: add 0.6.1 (#38035) 2023-06-01 19:23:15 -04:00
Sean Koyama
42d374a34d double-batched-fft-library: patch to add search paths to findOpenCL.cmake (#36355)
* double-batched-fft-library: PATCH: add search paths to find libOpenCL

* Apply patch up to version 0.3.6
2023-06-01 16:17:04 -07:00
Sean Koyama
d90e4fcc3d lua-luafilesystem: update source URL and improve rockspec detection (#36692)
* lua-luafilesystem: updated sources to new URL. Changed versioning to dot-separated versions.

* lua-luafilesystem: override install phase to find correct rockspec

* lua-luafilesystem: improved rockspec detection

* lua-luafilesystem: added lua version constraint for older versions
2023-06-01 16:15:42 -07:00
Manuela Kuhn
a44fde9dc9 py-docutils: add 0.20.1 (#38001) 2023-06-01 18:18:29 -04:00
Manuela Kuhn
9ac8841dab py-fonttools: add 4.39.4 (#38027) 2023-06-01 18:13:20 -04:00
Manuela Kuhn
a1f87638ec py-future: add 0.18.3 (#38041)
* py-future: add 0.18.3

* Update var/spack/repos/builtin/packages/py-future/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-06-01 17:48:13 -04:00
Manuela Kuhn
3b55e0a65d py-executing: add 1.2.0 (#38019) 2023-06-01 17:38:09 -04:00
Massimiliano Culpo
42667fe7fa Memoize a few hot functions during module file generation (#37739) 2023-06-01 13:36:42 -07:00
Ted Stern
cd27611d2f Adding libpsm3 package (#37444)
* Adding libpsm3 package
* Make changes suggested by flake8
* Make one more flake8-suggested change, blank line after 'import os'
* Change to standard header to pass flake8 tests
* Update doc string, remove unnecessary comments
* Reviewer-recommende changes
* Alphabetize variants
* Use helper functions
* Change quotes to pass spack style check
2023-06-01 13:01:43 -07:00
Massimiliano Culpo
b111d2172e py-archspec: add v0.2.1 (#38014) 2023-06-01 14:58:45 -05:00
Tobias Ribizel
055263fa3c Fix OpenCV detection on Ubuntu (#35336)
* fix OpenCV detection on Ubuntu

* Update package.py

* Simplify version detection

* remove superfluous `return`
2023-06-01 14:38:17 -05:00
Manuela Kuhn
f34f207bdc py-datalad-neuroimaging: add 0.3.3 (#38017) 2023-06-01 14:31:54 -05:00
snehring
0c9f0fd40d openssh: depend on krb5+shared when +gssapi (#38034) 2023-06-01 13:17:44 -04:00
pauleonix
24d5b1e645 asio: Add stable versions up to 1.28.0 (#38007)
Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

- Add pkgconfig dependency from 1.23.0 onward.
- Add conflict of old versions with new gcc due to missing includes.
- Deprecate uneven minor versions because they are not regarded as stable.
- Add maintainer
2023-06-01 11:09:27 +02:00
Mikael Simberg
616f7bcaef pika: add 0.16.0 and pika-algorithms 0.1.3 (#38021)
* pika: add 0.16.0

* pika-algorithms: add 0.1.3

---------

Co-authored-by: Alberto Invernizzi <9337627+albestro@users.noreply.github.com>
2023-06-01 04:18:26 -04:00
Greg Becker
dace0316a2 Spec.format: print false attributes if requested (#37932) 2023-06-01 09:08:45 +02:00
Greg Sjaardema
3bb86418b8 seacas: add 2023-05 release, update fmt dependency (#38008)
The fmt dependency for the previous release was incorrect as does not work with latest lib::fmt.  Fixed that specification
2023-06-01 02:48:50 -04:00
Veselin Dobrev
6f6489a2c7 xSDK examples v0.4.0 (#37295)
* [xsdk-examples] Initial commit for v0.4.0

* [xsdk-examples] v0.4.0 depends on xsdk@0.8.0

* add in missing xsdk dependencies

* [xsdk-examples] remove repeated 'depends_on' directive

* [xsdk-examples] simplify and extend a bit the package

[mfem] process more optional dependencies of HiOp

[strumpack, superlu-dist] add a workaround for an issue on Mac

* [mfem] fix the handling of the hiop dependency

* [@spackbot] updating style on behalf of v-dobrev

* [xsdk-examples] enable 'heffte' and 'tasmanian' if enabled in 'xsdk'

* [xsdk-examples] Add PUMI dependency

* [xsdk-examples] Add preCICE dependency

* [xsdk-examples] add +rocm

* heffte: add in a backport fix for building xsdk-examples with cuda

* [xsdk] Remove the explicit requirement for deal.II to be built +hdf5

* ENABLE_ROCM -> ENABLE_HIP

* [hiop] Workaround for CMake not finding Cray's BLAS (libsci)

[xsdk-examples] Set CUDA/HIP architectures; sync cuda/rocm variants with xsdk

* [@spackbot] updating style on behalf of v-dobrev

* [exago] Workaround for CMake not finding Cray's LAPACK/BLAS, libsci

[mfem] Tweaks for running tests under Flux and PBS

* [slate] Pass CUDA/HIP architectures to CMake

* [heffte] For newer CMake versions, set CMAKE_CUDA_ARCHITECTURES

* [hypre] Patch v2.26.0 to fix sequential compilation in 'src/seq_mv'

* [xsdk-examples] Some tweaks in dependencies and compilers used

* [xsdk] Make the 'trilinos' variant sticky

[xsdk-examples] Tweak dependencies

* [slate] Fix copy-paste error

* [xsdk-examples] Workaround for CMakePackage not having the legacy
   property 'build_directory'

* [xsdk-examples] Replace the testing branch used temporarily for v0.4.0 with
                the official release

---------

Co-authored-by: Satish Balay <balay@mcs.anl.gov>
2023-05-31 21:57:53 -04:00
Brian Van Essen
543b697df1 CachedCMakePackage: add CUDA/HIP options and improve independent builds (#37592)
* Add CMake options for building with CUDA/HIP support to
  CachedCMakePackages (intended to reduce duplication across packages
  building with +hip/+cuda and using CachedCMakePackage)
* Define generic variables like CMAKE_PREFIX_PATH for
  CachedCMakePackages (so that a user may invoke "cmake" themselves
  without needing to setthem on the command line).
* Make `lbann` a CachedCMakePackage.

Co-authored-by: Chris White <white238@llnl.gov>
2023-05-31 17:35:11 -07:00
QuellynSnead
042dc2e1d8 libtheora: enforce math library (libm.so) linkage (#37891) 2023-05-31 13:45:11 -07:00
Mosè Giordano
f745e49d9a julia: add patch to fix printing of BigFloat with MPFR v4.2 (#37992) 2023-05-31 15:32:12 -04:00
Michael Kuhn
eda21cdfba gcc: add 11.4.0 (#37988) 2023-05-31 09:15:45 -04:00
Adam J. Stewart
bc8b026072 py-pandas: add v2.0.2 (#38005) 2023-05-30 22:48:51 -04:00
Tiziano Müller
0f84782fcc Bugfix: cray manifest parsing regression (#37909)
fa7719a changed syntax for specifying exact versions, which are
required for some compiler specs (including those read as part
of parsing a Cray manifest). This fixes that and also makes a
couple other improvements to manifest parsing.

* Instantiate compiler specs with exact versions (fixes #37893)
* fix slingshot network detection (CPE 22.10+ has libcxi.so
  in /usr/lib64)
* "spack external find": add arg to ignore default dir for cray
  manifests
2023-05-30 18:03:44 -07:00
AMD Toolchain Support
43b86ce282 HPL: amdalloc with AOCC 4.0 (#37757)
* adding amdalloc when using aocc 4


* adding and libm for aocc3.2
2023-05-30 16:40:41 -07:00
AMD Toolchain Support
d30698d9a8 cp2k fixes for aocc (#37758) 2023-05-30 16:33:00 -07:00
Massimiliano Culpo
8e9efa86c8 Simplify implementation of "get_compiler_config" (#37989) 2023-05-30 15:11:33 -07:00
Jack Morrison
84faf5a6cf intel-mpi-benchmarks: Add MPI implementation check variant (#37363)
* Add MPI implementation check variant to Intel MPI Benchmarks

* [@spackbot] updating style on behalf of jack-morrison
2023-05-30 16:37:58 -05:00
Eric Berquist
9428749a3c Update SST packages to 13.0.0 (#37467)
* add sst-{core,elements,macro} v13.0.0

* Add newest DUMPI versions and remove unavailable ones

* update maintainer lists

* sst-core: tracking and profiling flags

* sst-elements with Pin requires the Pin location

* sst-core: Zoltan integration was removed in version 12

* spack style fixes

* sst-core: ensure Python is in the sst{sim,info}.x rpaths

* sst-macro: update homepage and maintainers

* spack style --fix
2023-05-30 16:35:33 -05:00
Michael Kuhn
efdac68c28 julia: fix build for @1.8.4:1.8.5 (#37990)
julia@1.8.4:1.8.5 fails to build because it does not find libstdc++ (see https://github.com/JuliaLang/julia/issues/47987).
2023-05-30 13:49:15 -07:00
Carlos Bederián
5398c31e82 ucx: add 1.14.1 (#37991) 2023-05-30 13:46:39 -07:00
Thomas Madlener
188168c476 podio: Add 0.16.5 tag (#37994) 2023-05-30 13:39:15 -07:00
Michael Kuhn
4af84ac208 gobject-introspection: add 1.76.1 (#37995) 2023-05-30 13:37:53 -07:00
Manuela Kuhn
deb8b51098 py-dunamai: add 1.17.0 (#38003) 2023-05-30 15:34:15 -04:00
Manuela Kuhn
0d582b2ea9 py-duecredit: add 0.9.2 (#38002) 2023-05-30 15:33:54 -04:00
Manuela Kuhn
f88b01c34b py-datalad-container: add 1.2.0 (#38000) 2023-05-30 15:28:34 -04:00
Manuela Kuhn
0533c6a1b8 py-datalad-metalad: add 0-4-17 and new dep py-datalad-deprecated (#37993)
* py-datalad-metalad: add 0-4-17 and new dep py-datalad-deprecated

* Fix style
2023-05-30 15:18:15 -04:00
Manuela Kuhn
f73d5c2b0e py-cryptography: add 40.0.2 (#37925)
* py-cryptography: add 40.0.2

* Add pkgconfig dependency
2023-05-30 10:26:17 -05:00
Tamara Dahlgren
567d0ee455 tests/hdf5: convert to new stand-alone test process (#35732) 2023-05-29 16:56:17 +02:00
Tamara Dahlgren
577df6f498 sqlite: convert to new stand-alone test process (#37722) 2023-05-29 07:59:23 -04:00
Harmen Stoppels
8790efbcfe Remove patchelf self-relocation (#33834) 2023-05-29 13:14:24 +02:00
Tamara Dahlgren
212b1edb6b tests/biobambam2: convert to new stand-alone test process (#35696) 2023-05-29 12:54:38 +02:00
snehring
d85a27f317 sentieon-genomics: replacing square brackets in help (#37622) 2023-05-29 12:52:36 +02:00
Chris White
5622afbfd1 amgx: add v2.2.0 and v2.3.0 (#37567) 2023-05-29 12:42:36 +02:00
Carlos Bederián
f345038317 nwchem: fix non-fftw fftw-api providers (#37442) 2023-05-29 12:41:41 +02:00
Michael Kuhn
e43d4cfee0 glib: add 2.76.3 and 2.76.2, update build systems (#37226)
This also converts the package to the new way of handling multiple build
systems.

Co-authored-by: michaelkuhn <michaelkuhn@users.noreply.github.com>
2023-05-29 06:38:57 -04:00
Vanessasaurus
7070658e2a Automated deployment to update package flux-core 2023-05-15 (#37684)
Co-authored-by: github-actions <github-actions@users.noreply.github.com>
2023-05-29 12:35:22 +02:00
dependabot[bot]
fc4b032fb4 build(deps): bump codecov/codecov-action from 3.1.3 to 3.1.4 (#37688)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 3.1.3 to 3.1.4.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](894ff025c7...eaaf4bedf3)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-29 12:34:34 +02:00
Vanessasaurus
8c97d8ad3f add flux-security variant to flux-core (#37689)
This will build flux-security separately to have a flux-imp
that can be defined in a flux broker.toml. Note that the user
that wants a multi-user setup is recommended to create a view,
and then a system/broker.toml in flux config directory that
points to it.

Signed-off-by: vsoch <vsoch@users.noreply.github.com>
Co-authored-by: vsoch <vsoch@users.noreply.github.com>
2023-05-29 12:34:07 +02:00
Alberto Invernizzi
26107fe6b2 highfive: add newer versions + add git repo (#37635)
* add versions
* add develop pointing to git@master
2023-05-29 06:09:02 -04:00
Tamara Dahlgren
9278c0df21 binutils: convert to new stand-alone test process (#37690) 2023-05-29 11:59:09 +02:00
Tamara Dahlgren
37e95713f4 libsigsegv: convert to new stand-alone test process (#37691) 2023-05-29 11:58:39 +02:00
SXS Bot
3ae8a3a517 spectre: add v2023.05.16 (#37716)
Co-authored-by: sxs-bot <sxs-bot@users.noreply.github.com>
2023-05-29 11:56:21 +02:00
Tamara Dahlgren
031af84e90 m4: convert to new stand-alone test process (#37723) 2023-05-29 11:49:28 +02:00
Annop Wongwathanarat
7d4b65491d armpl-gcc: add version 23.04.1 (#37907) 2023-05-29 05:49:19 -04:00
Harmen Stoppels
3038d1e7cd Use @= in some packages (#37737)
Change the pattern @x.y:x.y.0 -> @=x.y

Co-authored-by: haampie <haampie@users.noreply.github.com>
2023-05-29 11:47:00 +02:00
Lehman Garrison
b2e6ef97ce hdfview: add 3.1.4, 3.2.0, 3.3.0. Update dependencies. (#37745) 2023-05-29 11:41:44 +02:00
Tamara Dahlgren
e55236ce5b tests/arborx: convert to new stand-alone test process (#37778)
Co-authored-by: Andrey Prokopenko <andrey.prok@gmail.com>
2023-05-29 11:33:07 +02:00
Alec Scott
68dfd6ba6e hbase: add v2.5.3 (#37518)
Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-05-29 11:29:11 +02:00
Jim Galarowicz
38d2459f94 survey: add v1.0.8 (#37385) 2023-05-29 11:26:56 +02:00
Nicolas Cornu
e309f367af catch2: new versions (#37742) 2023-05-29 11:26:06 +02:00
Harmen Stoppels
3b59c95323 fix InternalConcretizerError msg (#37791) 2023-05-29 11:24:43 +02:00
Howard Pritchard
fddaeadff8 OPENMPI: disable use of sphinx (#37717)
Sphinx is used to build Open MPI manpages, etc. as part of the make dist
process to create release tarballs.  There should be no need/use to do
this within Spack.  Also some sites have older Sphinx installs which
aren't compatible with the needs of the Open MPI documentation.
For example, attempts to install openmpi@main fail at NERSC owing to
such a situation.

Since Spack normally is used to build from release tarballs, in which
the docs have already been installed, this should present no issues.

This configuration option will be ignored for older than 5.0.0 Open MPI releases.

Signed-off-by: Howard Pritchard <howardp@lanl.gov>
2023-05-29 11:23:42 +02:00
Joel Falcou
c85eaf9dc5 Add package for KUMI tuple library (#37795) 2023-05-29 11:23:06 +02:00
Brian Vanderwende
ddec7f8aec bbcp: fix cloning "master" version (#37802) 2023-05-29 11:21:48 +02:00
AMD Toolchain Support
f057d7154b NAMD: add AVXTILES support (#37040) 2023-05-29 11:10:09 +02:00
Tamara Dahlgren
a102950d67 berkeley-db: convert to new stand-alone test process (#35702) 2023-05-29 10:56:42 +02:00
Howard Pritchard
783be9b350 dealii - add platform-introspection variant (#37833)
This option is needed for DFT FE - or more accurately the check needs to
be checked off for a number of platforms or else the code doesn't work.

Signed-off-by: Howard Pritchard <howardp@lanl.gov>
2023-05-29 10:56:03 +02:00
Juan Miguel Carceller
27c8135207 xrootd: add patch for when libraries are installed in lib64 (#37858)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-05-29 10:36:57 +02:00
Tamara Dahlgren
77ce4701b9 Bugfix/tests: add slash to test log message (#37874) 2023-05-29 10:36:36 +02:00
Juan Miguel Carceller
73ad3f729e dd4hep: add patch to fix missing hits when using LCIO (#37854)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-05-29 10:35:14 +02:00
Jim Edwards
1e7a64ad85 parallelio: add v2.6.0 release and ncint variant (#37805) 2023-05-29 10:19:15 +02:00
Tamara Dahlgren
3a5864bcdb tests/sip: convert to new stand-alone test process (#35693) 2023-05-29 10:16:35 +02:00
Alec Scott
7e13a7dccb cbc: add v2.10.9 (#37974) 2023-05-29 04:04:28 -04:00
Alec Scott
e3249fa155 bedops: add v2.4.41 (#37972) 2023-05-29 04:04:06 -04:00
Thomas-Ulrich
0c20760576 pumi: fix simmodsuite base variant, and mpi lib name (#37401) 2023-05-29 09:59:32 +02:00
Alec Scott
7ee7995493 cracklib: add v2.9.9 (#37976) 2023-05-29 03:59:13 -04:00
Alec Scott
ba1fac1c31 cpio: add v2.14 (#37975) 2023-05-29 03:58:53 -04:00
Adam J. Stewart
b05f0ecb6f py-segmentation-models-pytorch: add v0.3.3 (#37970) 2023-05-29 09:48:32 +02:00
Alec Scott
d5c66b75c3 cyrus-sasl: add v2.1.28 (#37978) 2023-05-29 09:31:54 +02:00
Alec Scott
98303d6956 double-conversion: add v3.3.0 (#37979) 2023-05-29 09:31:38 +02:00
Alec Scott
4622d638a6 elfio: add v3.11 (#37980) 2023-05-29 09:31:23 +02:00
Alec Scott
02023265fc erfa: add v2.0.0 (#37981) 2023-05-29 09:31:09 +02:00
Alec Scott
8a075998f8 erlang: add v26.0 (#37982) 2023-05-29 09:30:28 +02:00
Alec Scott
f2f48b1872 fasttransforms: add v0.6.2 (#37983) 2023-05-29 09:30:10 +02:00
Alec Scott
168d63c447 glog: add v0.6.0 (#37985) 2023-05-29 09:29:34 +02:00
Alec Scott
c25d4cbc1d gradle: add v8.1.1 (#37986) 2023-05-29 09:29:07 +02:00
snehring
ccb07538f7 Beast2: add v2.7.4, add javafx (#37419) 2023-05-29 09:28:32 +02:00
Alec Scott
1356b13b2f form: add v4.3.1 (#37984) 2023-05-29 09:24:34 +02:00
Tamara Dahlgren
935f862863 tests/flibcpp: convert to new stand-alone test process (#37782) 2023-05-28 10:47:23 +02:00
Tamara Dahlgren
9f6d9df302 patchelf: convert to new stand-alone test process (#37831) 2023-05-28 10:46:23 +02:00
Tamara Dahlgren
65d33c02a1 gasnet: convert to new stand-alone test process (#35727) 2023-05-28 10:45:11 +02:00
Tamara Dahlgren
40073e7b21 hdf: convert to new stand-alone test process (#37843) 2023-05-28 10:44:42 +02:00
Tamara Dahlgren
752e02e2f2 tests/upcxx: convert to new stand-alone test process (#37832)
Co-authored-by: Dan Bonachea <dobonachea@lbl.gov>
2023-05-28 10:44:04 +02:00
Vanessasaurus
d717b3a33f Automated deployment to update package flux-core 2023-05-04 (#37421)
Co-authored-by: github-actions <github-actions@users.noreply.github.com>
2023-05-28 10:42:44 +02:00
Bruno Turcksin
9817f24c9a kokkos-nvcc-wrapper: Remove unnecessary dependencies (#37794) 2023-05-28 10:19:30 +02:00
Bruno Turcksin
1f7c4b0557 Kokkos: remove unused variants (#37800) 2023-05-28 10:18:53 +02:00
Xavier Delaruelle
6c42d2b7f7 modules: improve default naming scheme (#37808)
Change default naming scheme for tcl modules for a more user-friendly
experience. 

Change from flat projection to "per software name" projection.

Flat naming scheme restrains module selection capabilities. The
`{name}/{version}...` scheme make possible to use user-friendly
mechanisms:

* implicit defaults (`module load git`)
* extended default (`module load git/2`)
* advanced version specifiers (`module load git@2:`)
2023-05-28 10:06:30 +02:00
Tamara Dahlgren
8df036a5a5 tests/cmake: convert to new stand-alone test process (#37724) 2023-05-28 09:59:21 +02:00
dependabot[bot]
582ebee74c build(deps): bump actions/setup-python from 4.6.0 to 4.6.1 (#37894)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 4.6.0 to 4.6.1.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](57ded4d7d5...bd6b4b6205)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-28 09:58:14 +02:00
Annop Wongwathanarat
1017b9ddde acfl: add version 23.04.1 and fix checksums for 22.1 (#37908)
Checksums for 22.1 need updates due to an IT incident at developer.arm.com. The package tarballs needed to be recreated.
2023-05-28 09:57:31 +02:00
Thomas Madlener
80ae73119d whizard: Fix parallel build race condition (#37890) 2023-05-28 09:55:52 +02:00
Tamara Dahlgren
1d88f690a4 tests/darshan-runtime: convert to new stand-alone test process (#37838) 2023-05-28 09:46:31 +02:00
Filippo Spiga
fbb271d804 Adding NVIDIA HPC SDK 23.5 (#37913) 2023-05-28 09:45:08 +02:00
Hao Lyu
d6aac873b7 copy namelist and xml to ./bin (#37933) 2023-05-28 09:43:27 +02:00
Tamara Dahlgren
ab3ffd9361 archer: convert to new stand-alone test process (#35697) 2023-05-28 09:41:38 +02:00
Tamara Dahlgren
3b9454a5cc tests/bolt: convert to new stand-alone test process (#35695)
* bolt: convert to new stand-alone test process
* Remove redundant test_requires_compiler (so above directives)
2023-05-27 18:46:11 -07:00
Tamara Dahlgren
c8eb0f9361 tests/amrex: convert to new stand-alone test process (#35698)
* amrex: convert to new stand-alone test process
* smoke->stand-alone
2023-05-27 18:44:06 -07:00
George Young
fb0f14eb06 py-macs2: add 2.2.8, updated dependencies (#37944)
* py-macs2: add 2.2.8, updated dependencies

* Update package.py

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-05-27 14:29:12 -05:00
George Young
e489ee4e2e py-cutadapt: add 4.4, 4.3, 4.2 versions (#37929)
* py-cutadapt: add 4.4, 4.3, 4.2 versions

* Update var/spack/repos/builtin/packages/py-cutadapt/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-cutadapt/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update package.py

---------

Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-05-27 14:27:43 -05:00
Alex Richert
fcd49f2f08 Add shared and pic variants to libtiff (#37965)
* Add static-only option for libtiff

* update libtiff to add pic variant

* fix libtiff pic setting
2023-05-27 11:24:27 -05:00
Alex Richert
b3268c2703 freetype: add pic and shared variants (#37898) 2023-05-27 01:05:10 +02:00
George Young
d1bfcfafe3 py-multiqc: add 1.14, bump dependencies (#37946)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-05-26 17:55:03 -05:00
Manuela Kuhn
490c9f5e16 py-datalad-metadata-model: add 0.3.10 (#37937) 2023-05-26 17:28:36 -05:00
Manuela Kuhn
85628d1474 py-debugpy: add 1.6.7 (#37941) 2023-05-26 17:27:50 -05:00
Manuela Kuhn
720c34d18d py-distro: add 1.8.0 (#37942) 2023-05-26 17:27:06 -05:00
mschouler
cd175377ca Update melissa build (#37609)
* Remove deprecated package

* Add up-to-date melissa builds

* Remove blank lines and FIXME comments

* Use directive syntax for maintainers and remove unnecessary comments

* Remove unused function

* Deprecate former melissa recipe

* Change melissa python package name

* Update setuptools and rapidjson dependencies versions

* Fix mypy error

* Restore rapidjson version

* Variant simplification

* Make variants lower case

* Deprecate former omitted version

* Make torch version consistent with requirement file

* Fix variants definition

* Fix style error

---------

Co-authored-by: Marc Schouler <marc.schouler@inria.fr>
2023-05-26 17:26:29 -05:00
Manuela Kuhn
b91ec05e13 py-coloredlogs: add 15.0.1 and py-humanfriendly: add 10.0 (#37905) 2023-05-26 17:22:02 -05:00
Manuela Kuhn
3bb15f420b py-contourpy: add 1.0.7 (#37914) 2023-05-26 17:19:40 -05:00
Manuela Kuhn
124a81df5b py-coverage: add 5.5 (#37922) 2023-05-26 17:06:39 -05:00
Lee James O'Riordan
d9472c083d Update py-pennylane ecosystem to support v0.30.0 (#37763)
* Update PennyLane ecosystem for 0.30 release

* Update package dep versions

* Fix formatting

* Update dep versions

* Remove PL hard pin and rely on PLQ to define version

* Update var/spack/repos/builtin/packages/py-pennylane-lightning-kokkos/package.py

Co-authored-by: Vincent Michaud-Rioux <vincent.michaud-rioux@xanadu.ai>

* Convert pybind11 from build to link dep, and PL ver limit

---------

Co-authored-by: Vincent Michaud-Rioux <vincent.michaud-rioux@xanadu.ai>
2023-05-26 16:55:21 -05:00
Manuela Kuhn
ac2a5ef4dd py-beautifulsoup4: add 4.12.2 (#37820) 2023-05-26 16:54:43 -05:00
Manuela Kuhn
ea210a6acf py-chardet: add 5.1.0 (#37879)
* py-chardet: add 5.1.0

* Remove py-setuptools as run dependency
2023-05-26 16:51:54 -05:00
kwryankrattiger
afb3bef7af CI: Use relative path in default script (#36649) 2023-05-26 14:28:48 -06:00
George Young
b5b5881426 picard: add 3.0.0, switch to java@17: (#37948)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-05-26 15:38:26 -04:00
George Young
76fc7915a8 minimap2: adding 2.26 (#37945)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-05-26 10:12:14 -07:00
George Young
e7798b619b hyphy: add 2.5.51hf, update dependencies for switch to MPI (#37938)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-05-26 09:48:26 -07:00
Kai Torben Ohlhus
8ecef12a20 Strip inactive maintainer. (#36048) 2023-05-26 10:47:39 -04:00
Brian Spilner
694292ebbf cdo: add 2.2.0 (#37244) 2023-05-26 10:01:49 +02:00
Howard Pritchard
7f18f6f8a1 PMIx and PRRTe: disabled use of sphinx (#37750)
Related to https://github.com/spack/spack/pull/37717

No need to be rebuilding openmpi man pages and other docs in
spack as it almost always is used with release tarballs.

See #37717 for more details.

Signed-off-by: Howard Pritchard <howardp@lanl.gov>
2023-05-26 09:49:02 +02:00
John W. Parent
0b12a480eb Windows MSVC: do not set sdk version if installing sdk (#37930)
Note the win-sdk package is not installable and reports an error
which instructs the user how to add it. Without this fix, a
(more confusing) error occurs before this message can be generated.
2023-05-25 21:38:04 -04:00
George Young
2d91a79af3 fastp: add version 0.23.3, add build dependencies (#37931)
Co-authored-by: LMS Bioinformatics <bioinformatics@lms.mrc.ac.uk>
2023-05-25 21:28:13 -04:00
Leonard-Anderson-NNL
72fcee7227 gradle:add 7.3 (#37928)
Co-authored-by: Cloud User <leonardanderson@leonardander001.hzterscemazurawp3xenxzahla.bx.internal.cloudapp.net>
2023-05-25 20:55:09 -04:00
John W. Parent
d147ef231f Windows: fix "spack build-env" (#37923)
"spack build-env" was not generating proper environment variable
definitions on Windows; this commit updates the generated commands
to succeed with batch/PowerShell.
2023-05-25 17:08:15 -07:00
eugeneswalker
1c7af83d32 update ci ml darwin keypath (#37927) 2023-05-25 16:27:56 -07:00
John W. Parent
b982dfc071 Windows CI: add paraview deps nightly build (#37924)
Add a nightly job to attempt building all Paraview dependencies and
upload the results to cdash. This check doesn't affect the reported
build/test status of Spack. We are using this to monitor the state of
Windows support while working on more-robust checks (eventually the
Windows build will have to succeed to merge PRs to Spack).
2023-05-25 16:13:41 -07:00
H. Joe Lee
c0da8a00fc fix(protobuf-c): set version bound for protobuf dependency (#37917)
Fix #37887 GitLab CI failure.
2023-05-25 19:08:54 -04:00
H. Joe Lee
3f18f689d8 fix(dpdk): add a new version 23.03. (#37919)
Fix E4S GitLab CI issue #37887.
2023-05-25 18:58:41 -04:00
Simon Pintarelli
9dc4553cf3 sirius: add rocsolver/wannier90 (#37900)
* sirius: add rocsolver dependency for 7.5:
* add wannier90
2023-05-25 15:58:04 -07:00
Tim Haines
9a99c94b75 Dyninst: add standalone test (#37876)
* Dyninst: add standalone test
* Add docstring with description
* Don't use join_path for builtin path objects
* Whitespace
* Update format of docstring
2023-05-25 18:48:52 -04:00
John W. Parent
682f0b2a54 Protobuf package: CMake fix for Windows build (#37926)
Qualify reference with namespace. A pending upstream PR will eventually
make this unnecessary, so the patch is only applied for 3.22. versions.
2023-05-25 15:41:16 -07:00
Richard Berger
dbab0c1ff5 flecsi: disable cinch dependency for v1 release (#37857)
* flecsi: disable cinch dependency for v1 releases
* [@spackbot] updating style on behalf of rbberger

---------

Co-authored-by: rbberger <rbberger@users.noreply.github.com>
2023-05-25 14:59:45 -07:00
Xavier Delaruelle
2bf95f5340 environment-modules: fix @main version requirements (#37807)
Some requirements for @main version of environment-modules were missing:

* python (to build ChangeLog documentation file)
* py-sphinx@1.0: (to build man-pages, etc)

Also adding gzip, which is now required to build ChangeLog.gz (which is
now shipped instead of ChangeLog).

Other versions are not requiring these tools (as documentation is
pre-built in dist tarball).
2023-05-25 22:29:26 +02:00
Tamara Dahlgren
55561405b8 Bugfix/tests: write not append stand-alone test status (#37841) 2023-05-25 12:36:24 -07:00
H. Joe Lee
8eef458cea fix(pmdk): add pkconfig as dependency (#37896)
Fix #37887 failure.
2023-05-25 10:35:48 -07:00
Stephen Sachs
64eea9d996 [devito] Move to version 4.8.1 (#37915)
* [devito] Move to version 4.8.1

* Fix: Adding patch file

* Update var/spack/repos/builtin/packages/py-devito/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Update var/spack/repos/builtin/packages/py-devito/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* Addressing @adamjstewart comments

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-05-25 13:33:10 -04:00
Alex Richert
60b4e2128b Add shared variant to geos package (#37899)
Co-authored-by: alexrichert <alexrichert@gmail.com>
2023-05-25 11:42:51 -04:00
Adam J. Stewart
2f8cea2792 Add macOS ML CI stacks (#36586)
* Add macOS ML CI stacks

* torchmeta is no longer maintained and requires ancient PyTorch

* Add MXNet

* update darwin aarch64 stacks

* add darwin-aarch64 scoped config.yaml

* remove unnecessary cleanup job

* fix specifications

* fix labels

* fix labels

* fix indent on tags specification

* no tags for trigger jobs

* try overriding tags in stack spack.yaml

* do not use CI_STACK_CONFIG_SCOPES

* incorporate config:install_tree:root: overrides and compiler defs

* copy relevant ci-scoped config settings directly into stack spack.yaml

* remove build-job-remove

* spack ci generate: add debug flag

* include cdash config directly in stack spack.yaml

* customize build-job script section to avoid absolute paths

* add any-job specification

* tags: use aarch64-macos instead of aarch64

* generate tags: use aarch64-macos instead of aarch64

* do not add morepadding

* use shared mirror; comment out known failures

* remove any-job

* nproc || true

* comment out specs failing due to bazel from cache codesign issue

---------

Co-authored-by: eugeneswalker <eugenesunsetwalker@gmail.com>
2023-05-25 01:12:54 -04:00
M. Eric Irrgang
06f9bcf734 Update for py-gmxapi for 0.4.1. (#37834)
* Update for py-gmxapi for 0.4.1.

* Note 0.4.1 hash from PyPI.
* Note relaxed dependencies for future versions.

* Update var/spack/repos/builtin/packages/py-gmxapi/package.py
2023-05-24 22:03:10 -05:00
Manuela Kuhn
ee2725762f py-charset-normalizer: add 3.1.0 (#37880) 2023-05-24 21:57:29 -05:00
Manuela Kuhn
eace0a177c py-bids-validator: add 1.11.0 (#37845) 2023-05-24 21:36:45 -05:00
Manuela Kuhn
80c7d74707 py-bottleneck: add 1.3.7 (#37847) 2023-05-24 21:36:01 -05:00
Manuela Kuhn
a6f5bf821d py-certifi: add 2023.5.7 (#37848) 2023-05-24 21:35:13 -05:00
Manuela Kuhn
b214406253 py-attrs: add 23.1.0 (#37817)
* py-attrs: add 23.1.0

* Add missing dependency
2023-05-24 20:21:31 -05:00
Manuela Kuhn
5b003d80e5 py-babel: add 2.12.1 (#37818)
* py-babel: add 2.12.1

* Update var/spack/repos/builtin/packages/py-babel/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-05-24 20:13:02 -05:00
Adam J. Stewart
185b2d3ee7 py-rasterio: add v1.3.7 (#37886) 2023-05-24 18:48:16 -04:00
Adam J. Stewart
71bb2a1899 py-lightly: add v1.4.6 (#37885) 2023-05-24 16:43:07 -04:00
Nathalie Furmento
785c31b730 starpu: add release 1.4.1 (#37883) 2023-05-24 09:36:56 -07:00
QuellynSnead
175da4a88a paraview (protobuf failure) #37437 (#37440)
When attempting to build paraview@5.10.1 using a recent Intel
compiler (Classic or OneAPI) or the IBM XL compiler, the build
fails if the version of protobuf used is > 3.18
2023-05-24 11:09:48 -05:00
willdunklin
73fc1ef11c sensei: Allow Paraview 5.11 for sensei develop version (#37719) 2023-05-24 11:00:35 -05:00
Stephen Sachs
2d77e44f6f Pcluster local buildcache (#37852)
* [pcluster pipeline] Use local buildcache instead of upstream spack

Spack currently does not relocate compiler references from upstream spack
installations. When using a buildcache we don't need an upstream spack.

* gcc needs to be installed via postinstall to get correct deps

* quantum-espresso@gcc@12.3.0 returns ICE on neoverse_{n,v}1

* Force gitlab to pull the new container

* Revert "Force gitlab to pull the new container"

This reverts commit 3af5f4cd88.

Seems the gitlab version does not yet support "pull_policy" in .gitlab-ci.yml

* Gitlab keeps picking up wrong container. Renaming

* Update containers once more after failed build
2023-05-24 06:55:00 -07:00
Greg Becker
033599c4cd bugfix: env concretize after remove (#37877) 2023-05-24 15:41:57 +02:00
Harmen Stoppels
8096ed4b22 spack remove: fix traversal when user specs intersect (#37882)
drop unnecessary double loop over the matching user specs.
2023-05-24 09:23:46 -04:00
Simon Pintarelli
b49bfe25af update nlcglib package (#37578) 2023-05-24 11:17:15 +02:00
Houjun Tang
8b2f34d802 Add async vol v1.6 (#37875) 2023-05-24 01:47:46 -04:00
H. Joe Lee
3daed0d6a7 hdf5-vol-daos: add a new package (#35653)
* hdf5-vol-daos: add a new package
* hdf5-vol-daos: address @soumagne review

---------

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-05-23 23:42:42 -04:00
Glenn Johnson
d6c1f75e8d julia: remove myself from maintainers list (#37868) 2023-05-23 16:22:56 -05:00
Laura Weber
c80a4c1ddc Updated hash for latest maintenance release (2022.2.1) (#37842) 2023-05-23 14:08:55 -07:00
Glenn Johnson
466abcb62d gate: remove myself as maintainer (#37862) 2023-05-23 14:03:52 -07:00
Glenn Johnson
69e99f0c16 Remove myself as maintainer of R packages (#37859)
* Remove myself as maintainer of R packages
  I will no longer have the time to properly maintain these packages.
* fix flake8 test for import
2023-05-23 15:35:32 -05:00
Glenn Johnson
bbee6dfc58 bart: remove myself as maintainer (#37860) 2023-05-23 16:08:07 -04:00
Glenn Johnson
2d60cf120b heasoft: remove myself as maintainer (#37866) 2023-05-23 14:37:57 -05:00
Glenn Johnson
db17fc2f33 opencv: remove myself from maintainers list (#37870) 2023-05-23 14:34:52 -05:00
eugeneswalker
c62080d498 e4s ci: add dealii (#32484) 2023-05-23 21:34:31 +02:00
Glenn Johnson
f9bbe549fa gatetools: remove myself as maintainer (#37863) 2023-05-23 15:32:54 -04:00
H. Joe Lee
55d7fec69c daos: add a new package (#35649) 2023-05-23 21:30:23 +02:00
Glenn Johnson
e938907150 reditools: remove myself as maintainer (#37871) 2023-05-23 15:28:16 -04:00
Glenn Johnson
0c40b86e96 itk: remove myself as maintainer (#37867) 2023-05-23 15:27:55 -04:00
Glenn Johnson
3d4cf0d8eb mumax: remove myself as maintainer (#37869) 2023-05-23 15:23:28 -04:00
Glenn Johnson
966e19d278 gurobi: remove myself as maintainer (#37865) 2023-05-23 15:23:05 -04:00
Glenn Johnson
8f930462bd fplo: remove myself as maintainer (#37861) 2023-05-23 15:17:50 -04:00
kjrstory
bf4fccee15 New package: FDS (#37850) 2023-05-23 11:59:05 -07:00
Manuela Kuhn
784771a008 py-bleach: add 6.0.0 (#37846) 2023-05-23 11:50:53 -07:00
Glenn Johnson
e4a9d9ae5b Bioc updates (#37297)
* add version 1.48.0 to bioconductor package r-a4
* add version 1.48.0 to bioconductor package r-a4base
* add version 1.48.0 to bioconductor package r-a4classif
* add version 1.48.0 to bioconductor package r-a4core
* add version 1.48.0 to bioconductor package r-a4preproc
* add version 1.48.0 to bioconductor package r-a4reporting
* add version 1.54.0 to bioconductor package r-absseq
* add version 1.30.0 to bioconductor package r-acde
* add version 1.78.0 to bioconductor package r-acgh
* add version 2.56.0 to bioconductor package r-acme
* add version 1.70.0 to bioconductor package r-adsplit
* add version 1.72.0 to bioconductor package r-affxparser
* add version 1.78.0 to bioconductor package r-affy
* add version 1.76.0 to bioconductor package r-affycomp
* add version 1.58.0 to bioconductor package r-affycontam
* add version 1.72.0 to bioconductor package r-affycoretools
* add version 1.48.0 to bioconductor package r-affydata
* add version 1.52.0 to bioconductor package r-affyilm
* add version 1.70.0 to bioconductor package r-affyio
* add version 1.76.0 to bioconductor package r-affyplm
* add version 1.46.0 to bioconductor package r-affyrnadegradation
* add version 1.48.0 to bioconductor package r-agdex
* add version 3.32.0 to bioconductor package r-agilp
* add version 2.50.0 to bioconductor package r-agimicrorna
* add version 1.32.0 to bioconductor package r-aims
* add version 1.32.0 to bioconductor package r-aldex2
* add version 1.38.0 to bioconductor package r-allelicimbalance
* add version 1.26.0 to bioconductor package r-alpine
* add version 2.62.0 to bioconductor package r-altcdfenvs
* add version 2.24.0 to bioconductor package r-anaquin
* add version 1.28.0 to bioconductor package r-aneufinder
* add version 1.28.0 to bioconductor package r-aneufinderdata
* add version 1.72.0 to bioconductor package r-annaffy
* add version 1.78.0 to bioconductor package r-annotate
* add version 1.62.0 to bioconductor package r-annotationdbi
* add version 1.24.0 to bioconductor package r-annotationfilter
* add version 1.42.0 to bioconductor package r-annotationforge
* add version 3.8.0 to bioconductor package r-annotationhub
* add version 3.30.0 to bioconductor package r-aroma-light
* add version 1.32.0 to bioconductor package r-bamsignals
* add version 2.16.0 to bioconductor package r-beachmat
* add version 2.60.0 to bioconductor package r-biobase
* add version 2.8.0 to bioconductor package r-biocfilecache
* add version 0.46.0 to bioconductor package r-biocgeneric
* add version 1.10.0 to bioconductor package r-biocio
* add version 1.18.0 to bioconductor package r-biocneighbors
* add version 1.34.0 to bioconductor package r-biocparallel
* add version 1.16.0 to bioconductor package r-biocsingular
* add version 2.28.0 to bioconductor package r-biocstyle
* add version 3.17.1 to bioconductor package r-biocversion
* add version 2.56.0 to bioconductor package r-biomart
* add version 1.28.0 to bioconductor package r-biomformat
* add version 2.68.0 to bioconductor package r-biostrings
* add version 1.48.0 to bioconductor package r-biovizbase
* add version 1.10.0 to bioconductor package r-bluster
* add version 1.68.0 to bioconductor package r-bsgenome
* add version 1.36.0 to bioconductor package r-bsseq
* add version 1.42.0 to bioconductor package r-bumphunter
* add version 2.66.0 to bioconductor package r-category
* add version 2.30.0 to bioconductor package r-champ
* add version 2.32.0 to bioconductor package r-champdata
* add version 1.50.0 to bioconductor package r-chipseq
* add version 4.8.0 to bioconductor package r-clusterprofiler
* add version 1.36.0 to bioconductor package r-cner
* add version 1.32.0 to bioconductor package r-codex
* add version 2.16.0 to bioconductor package r-complexheatmap
* add version 1.74.0 to bioconductor package r-ctc
* add version 2.28.0 to bioconductor package r-decipher
* add version 0.26.0 to bioconductor package r-delayedarray
* add version 1.22.0 to bioconductor package r-delayedmatrixstats
* add version 1.40.0 to bioconductor package r-deseq2
* add version 1.46.0 to bioconductor package r-dexseq
* add version 1.42.0 to bioconductor package r-dirichletmultinomial
* add version 2.14.0 to bioconductor package r-dmrcate
* add version 1.74.0 to bioconductor package r-dnacopy
* add version 3.26.0 to bioconductor package r-dose
* add version 2.48.0 to bioconductor package r-dss
* add version 3.42.0 to bioconductor package r-edger
* add version 1.20.0 to bioconductor package r-enrichplot
* add version 2.24.0 to bioconductor package r-ensembldb
* add version 1.46.0 to bioconductor package r-exomecopy
* add version 2.8.0 to bioconductor package r-experimenthub
* add version 1.26.0 to bioconductor package r-fgsea
* add version 2.72.0 to bioconductor package r-gcrma
* add version 1.36.0 to bioconductor package r-gdsfmt
* add version 1.82.0 to bioconductor package r-genefilter
* add version 1.36.0 to bioconductor package r-genelendatabase
* add version 1.72.0 to bioconductor package r-genemeta
* add version 1.78.0 to bioconductor package r-geneplotter
* add version 1.22.0 to bioconductor package r-genie3
* add version 1.36.0 to bioconductor package r-genomeinfodb
* update r-genomeinfodbdata
* add version 1.36.0 to bioconductor package r-genomicalignments
* add version 1.52.0 to bioconductor package r-genomicfeatures
* add version 1.52.0 to bioconductor package r-genomicranges
* add version 2.68.0 to bioconductor package r-geoquery
* add version 1.48.0 to bioconductor package r-ggbio
* add version 3.8.0 to bioconductor package r-ggtree
* add version 2.10.0 to bioconductor package r-glimma
* add version 1.12.0 to bioconductor package r-glmgampoi
* add version 5.54.0 to bioconductor package r-globaltest
* update r-go-db
* add version 1.20.0 to bioconductor package r-gofuncr
* add version 2.26.0 to bioconductor package r-gosemsim
* add version 1.52.0 to bioconductor package r-goseq
* add version 2.66.0 to bioconductor package r-gostats
* add version 1.78.0 to bioconductor package r-graph
* add version 1.62.0 to bioconductor package r-gseabase
* add version 1.32.0 to bioconductor package r-gtrellis
* add version 1.44.0 to bioconductor package r-gviz
* add version 1.28.0 to bioconductor package r-hdf5array
* add version 1.72.0 to bioconductor package r-hypergraph
* add version 1.36.0 to bioconductor package r-illumina450probevariants-db
* add version 0.42.0 to bioconductor package r-illuminaio
* add version 1.74.0 to bioconductor package r-impute
* add version 1.38.0 to bioconductor package r-interactivedisplaybase
* add version 2.34.0 to bioconductor package r-iranges
* add version 1.60.0 to bioconductor package r-kegggraph
* add version 1.40.0 to bioconductor package r-keggrest
* add version 3.56.0 to bioconductor package r-limma
* add version 2.52.0 to bioconductor package r-lumi
* add version 1.76.0 to bioconductor package r-makecdfenv
* add version 1.78.0 to bioconductor package r-marray
* add version 1.12.0 to bioconductor package r-matrixgenerics
* add version 1.8.0 to bioconductor package r-metapod
* add version 2.46.0 to bioconductor package r-methylumi
* add version 1.46.0 to bioconductor package r-minfi
* add version 1.34.0 to bioconductor package r-missmethyl
* add version 1.80.0 to bioconductor package r-mlinterfaces
* add version 1.12.0 to bioconductor package r-mscoreutils
* add version 2.26.0 to bioconductor package r-msnbase
* add version 2.56.0 to bioconductor package r-multtest
* add version 1.38.0 to bioconductor package r-mzid
* add version 2.34.0 to bioconductor package r-mzr
* add version 1.62.0 to bioconductor package r-oligoclasses
* update r-org-hs-eg-db
* add version 1.42.0 to bioconductor package r-organismdbi
* add version 1.40.0 to bioconductor package r-pathview
* add version 1.92.0 to bioconductor package r-pcamethods
* update r-pfam-db
* add version 1.44.0 to bioconductor package r-phyloseq
* add version 1.62.0 to bioconductor package r-preprocesscore
* add version 1.32.0 to bioconductor package r-protgenerics
* add version 1.34.0 to bioconductor package r-quantro
* add version 2.32.0 to bioconductor package r-qvalue
* add version 1.76.0 to bioconductor package r-rbgl
* add version 2.40.0 to bioconductor package r-reportingtools
* add version 2.44.0 to bioconductor package r-rgraphviz
* add version 2.44.0 to bioconductor package r-rhdf5
* add version 1.12.0 to bioconductor package r-rhdf5filters
* add version 1.22.0 to bioconductor package r-rhdf5lib
* add version 1.76.0 to bioconductor package r-roc
* add version 1.28.0 to bioconductor package r-rots
* add version 2.16.0 to bioconductor package r-rsamtools
* add version 1.60.0 to bioconductor package r-rtracklayer
* add version 0.38.0 to bioconductor package r-s4vectors
* add version 1.8.0 to bioconductor package r-scaledmatrix
* add version 1.28.0 to bioconductor package r-scater
* add version 1.14.0 to bioconductor package r-scdblfinder
* add version 1.28.0 to bioconductor package r-scran
* add version 1.10.0 to bioconductor package r-scuttle
* add version 1.66.0 to bioconductor package r-seqlogo
* add version 1.58.0 to bioconductor package r-shortread
* add version 1.74.0 to bioconductor package r-siggenes
* add version 1.22.0 to bioconductor package r-singlecellexperiment
* add version 1.34.0 to bioconductor package r-snprelate
* add version 1.50.0 to bioconductor package r-snpstats
* add version 2.36.0 to bioconductor package r-somaticsignatures
* add version 1.12.0 to bioconductor package r-sparsematrixstats
* add version 1.40.0 to bioconductor package r-spem
* add version 1.38.0 to bioconductor package r-sseq
* add version 1.30.0 to bioconductor package r-summarizedexperiment
* add version 3.48.0 to bioconductor package r-sva
* add version 1.38.0 to bioconductor package r-tfbstools
* add version 1.22.0 to bioconductor package r-tmixclust
* add version 2.52.0 to bioconductor package r-topgo
* add version 1.24.0 to bioconductor package r-treeio
* add version 1.28.0 to bioconductor package r-tximport
* add version 1.28.0 to bioconductor package r-tximportdata
* add version 1.46.0 to bioconductor package r-variantannotation
* add version 3.68.0 to bioconductor package r-vsn
* add version 2.6.0 to bioconductor package r-watermelon
* add version 2.46.0 to bioconductor package r-xde
* add version 1.58.0 to bioconductor package r-xmapbridge
* add version 0.40.0 to bioconductor package r-xvector
* add version 1.26.0 to bioconductor package r-yapsa
* add version 1.26.0 to bioconductor package r-yarn
* add version 1.46.0 to bioconductor package r-zlibbioc
* Revert "add version 1.82.0 to bioconductor package r-genefilter"
  This reverts commit 1702071c6d.
* Revert "add version 0.38.0 to bioconductor package r-s4vectors"
  This reverts commit 58a7df2387.
* add version 0.38.0 to bioconductor package r-s4vectors
* Revert "add version 1.28.0 to bioconductor package r-aneufinder"
  This reverts commit 0a1f59de6c.
* add version 1.28.0 to bioconductor package r-aneufinder
* Revert "add version 2.16.0 to bioconductor package r-beachmat"
  This reverts commit cd49fb8e4c.
* add version 2.16.0 to bioconductor package r-beachmat
* Revert "add version 4.8.0 to bioconductor package r-clusterprofiler"
  This reverts commit 6e9a951cbe.
* add version 4.8.0 to bioconductor package r-clusterprofiler
* Fix syntax error
* r-genefilter: add version 1.82.0
* new package: r-basilisk-utils
* new package: r-basilisk
* new package: r-densvis
* new package: r-dir-expiry
* r-affyplm: add zlib dependency
* r-cner: add zlib dependency
* r-mzr: add zlib dependency
* r-rhdf5filters: add zstd dependency
* r-shortread: add zlib dependency
* r-snpstats: add zlib dependency

---------

Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
2023-05-23 11:40:00 -07:00
snehring
a6886983dc usalign: new package (#37646)
* usalign: adding new package
* usalign: updating shasum, adding note about distribution
2023-05-23 11:30:40 -07:00
Andrey Parfenov
93a34a9635 hpcg: apply patch with openmp pragma changes for intel and oneapi compilers (#37856)
Signed-off-by: Andrey Parfenov <andrey.parfenov@intel.com>
2023-05-23 11:52:45 -04:00
Todd Gamblin
91a54029f9 libgcrypt: patch 1.10.2 on macos (#37844)
macOS doesn't have `getrandom`, and 1.10.2 fails to compile because of this.

There's an upstream fix at https://dev.gnupg.org/T6442 that will be in the next
`libgcrypt` release, but the patch is available now.
2023-05-23 06:03:13 -04:00
Juan Miguel Carceller
5400b49ed6 dd4hep: add LD_LIBRARY_PATH for plugins for Gaudi (#37824)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-05-23 10:28:26 +01:00
Juan Miguel Carceller
c17fc3c0c1 gaudi: add gaudi to LD_LIBRARY_PATH (#37821)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-05-23 10:27:55 +01:00
Juan Miguel Carceller
6f248836ea dd4hep: restrict podio versions (#37699)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-05-23 10:20:31 +01:00
snehring
693c1821b0 py-pastml: adding version for compatibility with py-topiary-asr (#37828) 2023-05-22 14:44:00 -05:00
Manuela Kuhn
62afe3bd5a py-asttokens: add 2.2.1 (#37816) 2023-05-22 14:40:08 -05:00
genric
53a756d045 py-dask: add v2023.4.1 (#37550)
* py-dask: add v2023.4.1

* address review comments
2023-05-22 14:29:23 -05:00
Adam J. Stewart
321b687ae6 py-huggingface-hub: add v0.14.1, cli variant (#37815) 2023-05-22 11:19:41 -07:00
Adam J. Stewart
c8617f0574 py-fiona: add v1.9.4 (#37780) 2023-05-22 13:17:13 -05:00
Adam J. Stewart
7843e2ead0 azcopy: add new package (#37693) 2023-05-22 11:09:06 -07:00
Juan Miguel Carceller
dca3d071d7 gaudi: fix issue with fmt::format (#37810)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
2023-05-22 10:33:05 -07:00
eugeneswalker
436f077482 tau %oneapi: -Wno-error=implicit-function-declaration (#37829) 2023-05-22 13:13:02 -04:00
simonleary-umass-edu
ab3f705019 deleted package.py better error message (#37814)
adds the namespace to the exception object's string representation
2023-05-22 09:59:07 -07:00
Tamara Dahlgren
d739989ec8 swig: convert to new stand-alone test process (#37786) 2023-05-22 09:39:30 -07:00
Jordan Galby
52ee1967d6 llvm: Fix hwloc@1 and hwloc@:2.3 compatibility (#35387) 2023-05-22 10:28:57 -05:00
Andrey Prokopenko
1af7284b5d arborx: new version 1.4 (#37809) 2023-05-21 12:25:53 -07:00
Todd Gamblin
e1bcefd805 Update CHANGELOG.md for v0.20.0 2023-05-21 01:48:34 +02:00
Manuela Kuhn
2159b0183d py-argcomplete: add 3.0.8 (#37797)
* py-argcomplete: add 3.0.8

* Update var/spack/repos/builtin/packages/py-argcomplete/package.py

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>

* [@spackbot] updating style on behalf of manuelakuhn

---------

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2023-05-20 11:31:28 -05:00
1675 changed files with 32397 additions and 17113 deletions

View File

@@ -5,3 +5,8 @@ updates:
directory: "/"
schedule:
interval: "daily"
# Requirements to build documentation
- package-ecosystem: "pip"
directory: "/lib/spack/docs"
schedule:
interval: "daily"

View File

@@ -17,10 +17,13 @@ concurrency:
jobs:
# Run audits on all the packages in the built-in repository
package-audits:
runs-on: ubuntu-latest
runs-on: ${{ matrix.operating_system }}
strategy:
matrix:
operating_system: ["ubuntu-latest", "macos-latest"]
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # @v2
with:
python-version: ${{inputs.python_version}}
- name: Install Python packages
@@ -38,7 +41,7 @@ jobs:
run: |
. share/spack/setup-env.sh
$(which spack) audit packages
- uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2 # @v2.1.0
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d # @v2.1.0
if: ${{ inputs.with_coverage == 'true' }}
with:
flags: unittests,linux,audits
flags: unittests,audits

View File

@@ -24,7 +24,7 @@ jobs:
make patch unzip which xz python3 python3-devel tree \
cmake bison bison-devel libstdc++-static
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- name: Setup non-root user
@@ -62,7 +62,7 @@ jobs:
make patch unzip xz-utils python3 python3-dev tree \
cmake bison
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- name: Setup non-root user
@@ -99,7 +99,7 @@ jobs:
bzip2 curl file g++ gcc gfortran git gnupg2 gzip \
make patch unzip xz-utils python3 python3-dev tree
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- name: Setup non-root user
@@ -133,7 +133,7 @@ jobs:
make patch unzip which xz python3 python3-devel tree \
cmake bison
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- name: Setup repo
@@ -158,7 +158,7 @@ jobs:
run: |
brew install cmake bison@2.7 tree
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- name: Bootstrap clingo
run: |
source share/spack/setup-env.sh
@@ -179,7 +179,7 @@ jobs:
run: |
brew install tree
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- name: Bootstrap clingo
run: |
set -ex
@@ -204,7 +204,7 @@ jobs:
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- name: Setup repo
@@ -247,7 +247,7 @@ jobs:
bzip2 curl file g++ gcc patchelf gfortran git gzip \
make patch unzip xz-utils python3 python3-dev tree
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- name: Setup non-root user
@@ -283,7 +283,7 @@ jobs:
make patch unzip xz-utils python3 python3-dev tree \
gawk
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- name: Setup non-root user
@@ -316,7 +316,7 @@ jobs:
# Remove GnuPG since we want to bootstrap it
sudo rm -rf /usr/local/bin/gpg
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- name: Bootstrap GnuPG
run: |
source share/spack/setup-env.sh
@@ -333,7 +333,7 @@ jobs:
# Remove GnuPG since we want to bootstrap it
sudo rm -rf /usr/local/bin/gpg
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- name: Bootstrap GnuPG
run: |
source share/spack/setup-env.sh

View File

@@ -49,14 +49,14 @@ jobs:
[almalinux8, 'linux/amd64,linux/arm64,linux/ppc64le', 'almalinux:8'],
[almalinux9, 'linux/amd64,linux/arm64,linux/ppc64le', 'almalinux:9'],
[rockylinux8, 'linux/amd64,linux/arm64', 'rockylinux:8'],
[rockylinux9, 'linux/amd64,linux/arm64,linux/ppc64le', 'rockylinux:9'],
[rockylinux9, 'linux/amd64,linux/arm64', 'rockylinux:9'],
[fedora37, 'linux/amd64,linux/arm64,linux/ppc64le', 'fedora:37'],
[fedora38, 'linux/amd64,linux/arm64,linux/ppc64le', 'fedora:38']]
name: Build ${{ matrix.dockerfile[0] }}
if: github.repository == 'spack/spack'
steps:
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
- name: Set Container Tag Normal (Nightly)
run: |
@@ -92,13 +92,13 @@ jobs:
path: dockerfiles
- name: Set up QEMU
uses: docker/setup-qemu-action@e81a89b1732b9c48d79cd809d8d81d79c4647a18 # @v1
uses: docker/setup-qemu-action@2b82ce82d56a2a04d2637cd93a637ae1b359c0a7 # @v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@4b4e9c3e2d4531116a6f8ba8e71fc6e2cb6e6c8c # @v1
uses: docker/setup-buildx-action@4c0219f9ac95b02789c1075625400b2acbff50b1 # @v1
- name: Log in to GitHub Container Registry
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # @v1
uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc # @v1
with:
registry: ghcr.io
username: ${{ github.actor }}
@@ -106,13 +106,13 @@ jobs:
- name: Log in to DockerHub
if: github.event_name != 'pull_request'
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # @v1
uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc # @v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build & Deploy ${{ matrix.dockerfile[0] }}
uses: docker/build-push-action@3b5e8027fcad23fda98b2e3ac259d8d67585f671 # @v2
uses: docker/build-push-action@2eb1c1961a95fc15694676618e422e8ba1d63825 # @v2
with:
context: dockerfiles/${{ matrix.dockerfile[0] }}
platforms: ${{ matrix.dockerfile[1] }}

View File

@@ -35,7 +35,7 @@ jobs:
core: ${{ steps.filter.outputs.core }}
packages: ${{ steps.filter.outputs.packages }}
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
if: ${{ github.event_name == 'push' }}
with:
fetch-depth: 0

View File

@@ -0,0 +1,31 @@
name: Windows Paraview Nightly
on:
schedule:
- cron: '0 2 * * *' # Run at 2 am
defaults:
run:
shell:
powershell Invoke-Expression -Command "./share/spack/qa/windows_test_setup.ps1"; {0}
jobs:
build-paraview-deps:
runs-on: windows-latest
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1
with:
python-version: 3.9
- name: Install Python packages
run: |
python -m pip install --upgrade pip six pywin32 setuptools coverage
- name: Build Test
run: |
spack compiler find
spack external find cmake ninja win-sdk win-wdk wgl msmpi
spack -d install -y --cdash-upload-url https://cdash.spack.io/submit.php?project=Spack+on+Windows --cdash-track Nightly --only dependencies paraview
exit 0

View File

@@ -47,10 +47,10 @@ jobs:
on_develop: false
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b # @v2
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # @v2
with:
python-version: ${{ matrix.python-version }}
- name: Install System packages
@@ -87,17 +87,17 @@ jobs:
UNIT_TEST_COVERAGE: ${{ matrix.python-version == '3.11' }}
run: |
share/spack/qa/run-unit-tests
- uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d
with:
flags: unittests,linux,${{ matrix.concretizer }}
# Test shell integration
shell:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b # @v2
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # @v2
with:
python-version: '3.11'
- name: Install System packages
@@ -118,7 +118,7 @@ jobs:
COVERAGE: true
run: |
share/spack/qa/run-shell-tests
- uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d
with:
flags: shelltests,linux
@@ -133,7 +133,7 @@ jobs:
dnf install -y \
bzip2 curl file gcc-c++ gcc gcc-gfortran git gnupg2 gzip \
make patch tcl unzip which xz
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
- name: Setup repo and non-root user
run: |
git --version
@@ -152,10 +152,10 @@ jobs:
clingo-cffi:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b # @v2
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # @v2
with:
python-version: '3.11'
- name: Install System packages
@@ -176,7 +176,7 @@ jobs:
SPACK_TEST_SOLVER: clingo
run: |
share/spack/qa/run-unit-tests
- uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2 # @v2.1.0
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d # @v2.1.0
with:
flags: unittests,linux,clingo
# Run unit tests on MacOS
@@ -186,10 +186,10 @@ jobs:
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b # @v2
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # @v2
with:
python-version: ${{ matrix.python-version }}
- name: Install Python packages
@@ -211,6 +211,6 @@ jobs:
$(which spack) solve zlib
common_args=(--dist loadfile --tx '4*popen//python=./bin/spack-tmpconfig python -u ./bin/spack python' -x)
$(which spack) unit-test --cov --cov-config=pyproject.toml --cov-report=xml:coverage.xml "${common_args[@]}"
- uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d
with:
flags: unittests,macos

View File

@@ -18,8 +18,8 @@ jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # @v2
with:
python-version: '3.11'
cache: 'pip'
@@ -35,10 +35,10 @@ jobs:
style:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b # @v2
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # @v2
with:
python-version: '3.11'
cache: 'pip'
@@ -68,7 +68,7 @@ jobs:
dnf install -y \
bzip2 curl file gcc-c++ gcc gcc-gfortran git gnupg2 gzip \
make patch tcl unzip which xz
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # @v2
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # @v2
- name: Setup repo and non-root user
run: |
git --version
@@ -81,6 +81,7 @@ jobs:
shell: runuser -u spack-test -- bash {0}
run: |
source share/spack/setup-env.sh
spack debug report
spack -d bootstrap now --dev
spack style -t black
spack unit-test -V

View File

@@ -15,10 +15,10 @@ jobs:
unit-tests:
runs-on: windows-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1
with:
python-version: 3.9
- name: Install Python packages
@@ -33,16 +33,16 @@ jobs:
./share/spack/qa/validate_last_exit.ps1
coverage combine -a
coverage xml
- uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d
with:
flags: unittests,windows
unit-tests-cmd:
runs-on: windows-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1
with:
python-version: 3.9
- name: Install Python packages
@@ -57,16 +57,16 @@ jobs:
./share/spack/qa/validate_last_exit.ps1
coverage combine -a
coverage xml
- uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d
with:
flags: unittests,windows
build-abseil:
runs-on: windows-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
with:
fetch-depth: 0
- uses: actions/setup-python@57ded4d7d5e986d7296eab16560982c6dd7c923b
- uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1
with:
python-version: 3.9
- name: Install Python packages

View File

@@ -1,10 +1,16 @@
version: 2
build:
os: "ubuntu-22.04"
apt_packages:
- graphviz
tools:
python: "3.11"
sphinx:
configuration: lib/spack/docs/conf.py
fail_on_warning: true
python:
version: 3.7
install:
- requirements: lib/spack/docs/requirements.txt

View File

@@ -1,3 +1,239 @@
# v0.20.1 (2023-07-10)
## Spack Bugfixes
- Spec removed from an environment where not actually removed if `--force` was not given (#37877)
- Speed-up module file generation (#37739)
- Hotfix for a few recipes that treat CMake as a link dependency (#35816)
- Fix re-running stand-alone test a second time, which was getting a trailing spurious failure (#37840)
- Fixed reading JSON manifest on Cray, reporting non-concrete specs (#37909)
- Fixed a few bugs when generating Dockerfiles from Spack (#37766,#37769)
- Fixed a few long-standing bugs when generating module files (#36678,#38347,#38465,#38455)
- Fixed issues with building Python extensions using an external Python (#38186)
- Fixed compiler removal from command line (#38057)
- Show external status as [e] (#33792)
- Backported `archspec` fixes (#37793)
- Improved a few error messages (#37791)
# v0.20.0 (2023-05-21)
`v0.20.0` is a major feature release.
## Features in this release
1. **`requires()` directive and enhanced package requirements**
We've added some more enhancements to requirements in Spack (#36286).
There is a new `requires()` directive for packages. `requires()` is the opposite of
`conflicts()`. You can use it to impose constraints on this package when certain
conditions are met:
```python
requires(
"%apple-clang",
when="platform=darwin",
msg="This package builds only with clang on macOS"
)
```
More on this in [the docs](
https://spack.rtfd.io/en/latest/packaging_guide.html#conflicts-and-requirements).
You can also now add a `when:` clause to `requires:` in your `packages.yaml`
configuration or in an environment:
```yaml
packages:
openmpi:
require:
- any_of: ["%gcc"]
when: "@:4.1.4"
message: "Only OpenMPI 4.1.5 and up can build with fancy compilers"
```
More details can be found [here](
https://spack.readthedocs.io/en/latest/build_settings.html#package-requirements)
2. **Exact versions**
Spack did not previously have a way to distinguish a version if it was a prefix of
some other version. For example, `@3.2` would match `3.2`, `3.2.1`, `3.2.2`, etc. You
can now match *exactly* `3.2` with `@=3.2`. This is useful, for example, if you need
to patch *only* the `3.2` version of a package. The new syntax is described in [the docs](
https://spack.readthedocs.io/en/latest/basic_usage.html#version-specifier).
Generally, when writing packages, you should prefer to use ranges like `@3.2` over
the specific versions, as this allows the concretizer more leeway when selecting
versions of dependencies. More details and recommendations are in the [packaging guide](
https://spack.readthedocs.io/en/latest/packaging_guide.html#ranges-versus-specific-versions).
See #36273 for full details on the version refactor.
3. **New testing interface**
Writing package tests is now much simpler with a new [test interface](
https://spack.readthedocs.io/en/latest/packaging_guide.html#stand-alone-tests).
Writing a test is now as easy as adding a method that starts with `test_`:
```python
class MyPackage(Package):
...
def test_always_fails(self):
"""use assert to always fail"""
assert False
def test_example(self):
"""run installed example"""
example = which(self.prefix.bin.example)
example()
```
You can use Python's native `assert` statement to implement your checks -- no more
need to fiddle with `run_test` or other test framework methods. Spack will
introspect the class and run `test_*` methods when you run `spack test`,
4. **More stable concretization**
* Now, `spack concretize` will *only* concretize the new portions of the environment
and will not change existing parts of an environment unless you specify `--force`.
This has always been true for `unify:false`, but not for `unify:true` and
`unify:when_possible` environments. Now it is true for all of them (#37438, #37681).
* The concretizer has a new `--reuse-deps` argument that *only* reuses dependencies.
That is, it will always treat the *roots* of your environment as it would with
`--fresh`. This allows you to upgrade just the roots of your environment while
keeping everything else stable (#30990).
5. **Weekly develop snapshot releases**
Since last year, we have maintained a buildcache of `develop` at
https://binaries.spack.io/develop, but the cache can grow to contain so many builds
as to be unwieldy. When we get a stable `develop` build, we snapshot the release and
add a corresponding tag the Spack repository. So, you can use a stack from a specific
day. There are now tags in the spack repository like:
* `develop-2023-05-14`
* `develop-2023-05-18`
that correspond to build caches like:
* https://binaries.spack.io/develop-2023-05-14/e4s
* https://binaries.spack.io/develop-2023-05-18/e4s
We plan to store these snapshot releases weekly.
6. **Specs in buildcaches can be referenced by hash.**
* Previously, you could run `spack buildcache list` and see the hashes in
buildcaches, but referring to them by hash would fail.
* You can now run commands like `spack spec` and `spack install` and refer to
buildcache hashes directly, e.g. `spack install /abc123` (#35042)
7. **New package and buildcache index websites**
Our public websites for searching packages have been completely revamped and updated.
You can check them out here:
* *Package Index*: https://packages.spack.io
* *Buildcache Index*: https://cache.spack.io
Both are searchable and more interactive than before. Currently major releases are
shown; UI for browsing `develop` snapshots is coming soon.
8. **Default CMake and Meson build types are now Release**
Spack has historically defaulted to building with optimization and debugging, but
packages like `llvm` can be enormous with debug turned on. Our default build type for
all Spack packages is now `Release` (#36679, #37436). This has a number of benefits:
* much smaller binaries;
* higher default optimization level; and
* defining `NDEBUG` disables assertions, which may lead to further speedups.
You can still get the old behavior back through requirements and package preferences.
## Other new commands and directives
* `spack checksum` can automatically add new versions to package (#24532)
* new command: `spack pkg grep` to easily search package files (#34388)
* New `maintainers` directive (#35083)
* Add `spack buildcache push` (alias to `buildcache create`) (#34861)
* Allow using `-j` to control the parallelism of concretization (#37608)
* Add `--exclude` option to 'spack external find' (#35013)
## Other new features of note
* editing: add higher-precedence `SPACK_EDITOR` environment variable
* Many YAML formatting improvements from updating `ruamel.yaml` to the latest version
supporting Python 3.6. (#31091, #24885, #37008).
* Requirements and preferences should not define (non-git) versions (#37687, #37747)
* Environments now store spack version/commit in `spack.lock` (#32801)
* User can specify the name of the `packages` subdirectory in repositories (#36643)
* Add container images supporting RHEL alternatives (#36713)
* make version(...) kwargs explicit (#36998)
## Notable refactors
* buildcache create: reproducible tarballs (#35623)
* Bootstrap most of Spack dependencies using environments (#34029)
* Split `satisfies(..., strict=True/False)` into two functions (#35681)
* spack install: simplify behavior when inside environments (#35206)
## Binary cache and stack updates
* Major simplification of CI boilerplate in stacks (#34272, #36045)
* Many improvements to our CI pipeline's reliability
## Removals, Deprecations, and disablements
* Module file generation is disabled by default; you'll need to enable it to use it (#37258)
* Support for Python 2 was deprecated in `v0.19.0` and has been removed. `v0.20.0` only
supports Python 3.6 and higher.
* Deprecated target names are no longer recognized by Spack. Use generic names instead:
* `graviton` is now `cortex_a72`
* `graviton2` is now `neoverse_n1`
* `graviton3` is now `neoverse_v1`
* `blacklist` and `whitelist` in module configuration were deprecated in `v0.19.0` and are
removed in this release. Use `exclude` and `include` instead.
* The `ignore=` parameter of the `extends()` directive has been removed. It was not used by
any builtin packages and is no longer needed to avoid conflicts in environment views (#35588).
* Support for the old YAML buildcache format has been removed. It was deprecated in `v0.19.0` (#34347).
* `spack find --bootstrap` has been removed. It was deprecated in `v0.19.0`. Use `spack
--bootstrap find` instead (#33964).
* `spack bootstrap trust` and `spack bootstrap untrust` are now removed, having been
deprecated in `v0.19.0`. Use `spack bootstrap enable` and `spack bootstrap disable`.
* The `--mirror-name`, `--mirror-url`, and `--directory` options to buildcache and
mirror commands were deprecated in `v0.19.0` and have now been removed. They have been
replaced by positional arguments (#37457).
* Deprecate `env:` as top level environment key (#37424)
* deprecate buildcache create --rel, buildcache install --allow-root (#37285)
* Support for very old perl-like spec format strings (e.g., `$_$@$%@+$+$=`) has been
removed (#37425). This was deprecated in in `v0.15` (#10556).
## Notable Bugfixes
* bugfix: don't fetch package metadata for unknown concrete specs (#36990)
* Improve package source code context display on error (#37655)
* Relax environment manifest filename requirements and lockfile identification criteria (#37413)
* `installer.py`: drop build edges of installed packages by default (#36707)
* Bugfix: package requirements with git commits (#35057, #36347)
* Package requirements: allow single specs in requirement lists (#36258)
* conditional variant values: allow boolean (#33939)
* spack uninstall: follow run/link edges on --dependents (#34058)
## Spack community stats
* 7,179 total packages, 499 new since `v0.19.0`
* 329 new Python packages
* 31 new R packages
* 336 people contributed to this release
* 317 committers to packages
* 62 committers to core
# v0.19.1 (2023-02-07)
### Spack Bugfixes

View File

@@ -25,8 +25,6 @@ exit 1
# Line above is a shell no-op, and ends a python multi-line comment.
# The code above runs this file with our preferred python interpreter.
from __future__ import print_function
import os
import os.path
import sys

View File

@@ -214,7 +214,7 @@ goto :end_switch
if defined _sp_args (
if NOT "%_sp_args%"=="%_sp_args:--help=%" (
goto :default_case
) else if NOT "%_sp_args%"=="%_sp_args: -h=%" (
) else if NOT "%_sp_args%"=="%_sp_args:-h=%" (
goto :default_case
) else if NOT "%_sp_args%"=="%_sp_args:--bat=%" (
goto :default_case

132
bin/spack.ps1 Normal file
View File

@@ -0,0 +1,132 @@
# 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)
# #######################################################################
function Compare-CommonArgs {
$CMDArgs = $args[0]
# These aruments take precedence and call for no futher parsing of arguments
# invoke actual Spack entrypoint with that context and exit after
"--help", "-h", "--version", "-V" | ForEach-Object {
$arg_opt = $_
if(($CMDArgs) -and ([bool]($CMDArgs.Where({$_ -eq $arg_opt})))) {
return $true
}
}
return $false
}
function Read-SpackArgs {
$SpackCMD_params = @()
$SpackSubCommand = $NULL
$SpackSubCommandArgs = @()
$args_ = $args[0]
$args_ | ForEach-Object {
if (!$SpackSubCommand) {
if($_.SubString(0,1) -eq "-")
{
$SpackCMD_params += $_
}
else{
$SpackSubCommand = $_
}
}
else{
$SpackSubCommandArgs += $_
}
}
return $SpackCMD_params, $SpackSubCommand, $SpackSubCommandArgs
}
function Invoke-SpackCD {
if (Compare-CommonArgs $SpackSubCommandArgs) {
python $Env:SPACK_ROOT/bin/spack cd -h
}
else {
$LOC = $(python $Env:SPACK_ROOT/bin/spack location $SpackSubCommandArgs)
if (($NULL -ne $LOC)){
if ( Test-Path -Path $LOC){
Set-Location $LOC
}
else{
exit 1
}
}
else {
exit 1
}
}
}
function Invoke-SpackEnv {
if (Compare-CommonArgs $SpackSubCommandArgs[0]) {
python $Env:SPACK_ROOT/bin/spack env -h
}
else {
$SubCommandSubCommand = $SpackSubCommandArgs[0]
$SubCommandSubCommandArgs = $SpackSubCommandArgs[1..$SpackSubCommandArgs.Count]
switch ($SubCommandSubCommand) {
"activate" {
if (Compare-CommonArgs $SubCommandSubCommandArgs) {
python $Env:SPACK_ROOT/bin/spack env activate $SubCommandSubCommandArgs
}
elseif ([bool]($SubCommandSubCommandArgs.Where({$_ -eq "--pwsh"}))) {
python $Env:SPACK_ROOT/bin/spack env activate $SubCommandSubCommandArgs
}
elseif (!$SubCommandSubCommandArgs) {
python $Env:SPACK_ROOT/bin/spack env activate $SubCommandSubCommandArgs
}
else {
$SpackEnv = $(python $Env:SPACK_ROOT/bin/spack $SpackCMD_params env activate "--pwsh" $SubCommandSubCommandArgs)
$ExecutionContext.InvokeCommand($SpackEnv)
}
}
"deactivate" {
if ([bool]($SubCommandSubCommandArgs.Where({$_ -eq "--pwsh"}))) {
python $Env:SPACK_ROOT/bin/spack env deactivate $SubCommandSubCommandArgs
}
elseif($SubCommandSubCommandArgs) {
python $Env:SPACK_ROOT/bin/spack env deactivate -h
}
else {
$SpackEnv = $(python $Env:SPACK_ROOT/bin/spack $SpackCMD_params env deactivate --pwsh)
$ExecutionContext.InvokeCommand($SpackEnv)
}
}
default {python $Env:SPACK_ROOT/bin/spack $SpackCMD_params $SpackSubCommand $SpackSubCommandArgs}
}
}
}
function Invoke-SpackLoad {
if (Compare-CommonArgs $SpackSubCommandArgs) {
python $Env:SPACK_ROOT/bin/spack $SpackCMD_params $SpackSubCommand $SpackSubCommandArgs
}
elseif ([bool]($SpackSubCommandArgs.Where({($_ -eq "--pwsh") -or ($_ -eq "--list")}))) {
python $Env:SPACK_ROOT/bin/spack $SpackCMD_params $SpackSubCommand $SpackSubCommandArgs
}
else {
$SpackEnv = $(python $Env:SPACK_ROOT/bin/spack $SpackCMD_params $SpackSubCommand "--pwsh" $SpackSubCommandArgs)
$ExecutionContext.InvokeCommand($SpackEnv)
}
}
$SpackCMD_params, $SpackSubCommand, $SpackSubCommandArgs = Read-SpackArgs $args
if (Compare-CommonArgs $SpackCMD_params) {
python $Env:SPACK_ROOT/bin/spack $SpackCMD_params $SpackSubCommand $SpackSubCommandArgs
exit $LASTEXITCODE
}
# Process Spack commands with special conditions
# all other commands are piped directly to Spack
switch($SpackSubCommand)
{
"cd" {Invoke-SpackCD}
"env" {Invoke-SpackEnv}
"load" {Invoke-SpackLoad}
"unload" {Invoke-SpackLoad}
default {python $Env:SPACK_ROOT/bin/spack $SpackCMD_params $SpackSubCommand $SpackSubCommandArgs}
}

View File

@@ -216,10 +216,11 @@ config:
# manipulation by unprivileged user (e.g. AFS)
allow_sgid: true
# Whether to set the terminal title to display status information during
# building and installing packages. This gives information about Spack's
# current progress as well as the current and total number of packages.
terminal_title: false
# Whether to show status information during building and installing packages.
# This gives information about Spack's current progress as well as the current
# and total number of packages. Information is shown both in the terminal
# title and inline.
install_status: true
# Number of seconds a buildcache's index.json is cached locally before probing
# for updates, within a single Spack invocation. Defaults to 10 minutes.

View File

@@ -1,2 +1,4 @@
mirrors:
spack-public: https://mirror.spack.io
spack-public:
binary: false
url: https://mirror.spack.io

View File

@@ -49,6 +49,7 @@ packages:
pbs: [openpbs, torque]
pil: [py-pillow]
pkgconfig: [pkgconf, pkg-config]
qmake: [qt-base, qt]
rpc: [libtirpc]
scalapack: [netlib-scalapack, amdscalapack]
sycl: [hipsycl]

View File

@@ -0,0 +1,16 @@
# 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)
# The name of the Pygments (syntax highlighting) style to use.
# We use our own extension of the default style with a few modifications
from pygments.styles.default import DefaultStyle
from pygments.token import Generic
class SpackStyle(DefaultStyle):
styles = DefaultStyle.styles.copy()
background_color = "#f4f4f8"
styles[Generic.Output] = "#355"
styles[Generic.Prompt] = "bold #346ec9"

View File

@@ -48,14 +48,10 @@ Here is an example where a build cache is created in a local directory named
.. code-block:: console
$ spack buildcache push --allow-root ./spack-cache ninja
$ spack buildcache push ./spack-cache ninja
==> Pushing binary packages to file:///home/spackuser/spack/spack-cache/build_cache
Not that ``ninja`` must be installed locally for this to work.
We're using the ``--allow-root`` flag to tell Spack that is OK when any of
the binaries we're pushing contain references to the local Spack install
directory.
Note that ``ninja`` must be installed locally for this to work.
Once you have a build cache, you can add it as a mirror, discussed next.
@@ -147,7 +143,7 @@ and then install from it exclusively, you would do:
$ spack mirror add E4S https://cache.e4s.io
$ spack buildcache keys --install --trust
$ spack install --use-buildache only <package>
$ spack install --use-buildcache only <package>
We use ``--install`` and ``--trust`` to say that we are installing keys to our
keyring, and trusting all downloaded keys.

View File

@@ -76,6 +76,53 @@ To build with with ``icx``, do ::
spack install patchelf%oneapi
Using oneAPI Spack environment
-------------------------------
In this example, we build lammps with ``icx`` using Spack environment for oneAPI packages created by Intel. The
compilers are installed with Spack like in example above.
Install the oneAPI compilers::
spack install intel-oneapi-compilers
Add the compilers to your ``compilers.yaml`` so Spack can use them::
spack compiler add `spack location -i intel-oneapi-compilers`/compiler/latest/linux/bin/intel64
spack compiler add `spack location -i intel-oneapi-compilers`/compiler/latest/linux/bin
Verify that the compilers are available::
spack compiler list
Clone `spack-configs <https://github.com/spack/spack-configs>`_ repo and activate Intel oneAPI CPU environment::
git clone https://github.com/spack/spack-configs
spack env activate spack-configs/INTEL/CPU
spack concretize -f
`Intel oneAPI CPU environment <https://github.com/spack/spack-configs/blob/main/INTEL/CPU/spack.yaml>`_ contains applications tested and validated by Intel, this list is constantly extended. And currently it supports:
- `GROMACS <https://www.gromacs.org/>`_
- `HPCG <https://www.hpcg-benchmark.org/>`_
- `HPL <https://netlib.org/benchmark/hpl/>`_
- `LAMMPS <https://www.lammps.org/#gsc.tab=0>`_
- `OpenFOAM <https://www.openfoam.com/>`_
- `STREAM <https://www.cs.virginia.edu/stream/>`_
- `WRF <https://github.com/wrf-model/WRF>`_
To build lammps with oneAPI compiler from this environment just run::
spack install lammps
Compiled binaries can be find using::
spack cd -i lammps
You can do the same for all other applications from this environment.
Using oneAPI MPI to Satisfy a Virtual Dependence
------------------------------------------------------

View File

@@ -32,7 +32,7 @@ By default, these phases run:
.. code-block:: console
$ python configure.py --bindir ... --destdir ...
$ sip-build --verbose --target-dir ...
$ make
$ make install
@@ -41,30 +41,30 @@ By default, these phases run:
Important files
^^^^^^^^^^^^^^^
Each SIP package comes with a custom ``configure.py`` build script,
written in Python. This script contains instructions to build the project.
Each SIP package comes with a custom configuration file written in Python.
For newer packages, this is called ``project.py``, while in older packages,
it may be called ``configure.py``. This script contains instructions to build
the project.
^^^^^^^^^^^^^^^^^^^^^^^^^
Build system dependencies
^^^^^^^^^^^^^^^^^^^^^^^^^
``SIPPackage`` requires several dependencies. Python is needed to run
the ``configure.py`` build script, and to run the resulting Python
libraries. Qt is needed to provide the ``qmake`` command. SIP is also
needed to build the package. All of these dependencies are automatically
added via the base class
``SIPPackage`` requires several dependencies. Python and SIP are needed at build-time
to run the aforementioned configure script. Python is also needed at run-time to
actually use the installed Python library. And as we are building Python bindings
for C/C++ libraries, Python is also needed as a link dependency. All of these
dependencies are automatically added via the base class.
.. code-block:: python
extends('python')
extends("python", type=("build", "link", "run"))
depends_on("py-sip", type="build")
depends_on('qt', type='build')
depends_on('py-sip', type='build')
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Passing arguments to ``configure.py``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Passing arguments to ``sip-build``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Each phase comes with a ``<phase_args>`` function that can be used to pass
arguments to that particular phase. For example, if you need to pass
@@ -72,11 +72,11 @@ arguments to the configure phase, you can use:
.. code-block:: python
def configure_args(self, spec, prefix):
return ['--no-python-dbus']
def configure_args(self):
return ["--no-python-dbus"]
A list of valid options can be found by running ``python configure.py --help``.
A list of valid options can be found by running ``sip-build --help``.
^^^^^^^
Testing

View File

@@ -97,9 +97,7 @@ class PatchedPythonDomain(PythonDomain):
def resolve_xref(self, env, fromdocname, builder, typ, target, node, contnode):
if "refspecific" in node:
del node["refspecific"]
return super(PatchedPythonDomain, self).resolve_xref(
env, fromdocname, builder, typ, target, node, contnode
)
return super().resolve_xref(env, fromdocname, builder, typ, target, node, contnode)
#
@@ -149,7 +147,6 @@ def setup(sphinx):
# Get nice vector graphics
graphviz_output_format = "svg"
# Add any paths that contain templates here, relative to this directory.
templates_path = ["_templates"]
@@ -217,6 +214,7 @@ def setup(sphinx):
# Spack classes that intersphinx is unable to resolve
("py:class", "spack.version.StandardVersion"),
("py:class", "spack.spec.DependencySpec"),
("py:class", "spack.spec.SpecfileReaderBase"),
("py:class", "spack.install_test.Pb"),
]
@@ -233,30 +231,8 @@ def setup(sphinx):
# If true, sectionauthor and moduleauthor directives will be shown in the
# output. They are ignored by default.
# show_authors = False
# The name of the Pygments (syntax highlighting) style to use.
# We use our own extension of the default style with a few modifications
from pygments.style import Style
from pygments.styles.default import DefaultStyle
from pygments.token import Comment, Generic, Text
class SpackStyle(DefaultStyle):
styles = DefaultStyle.styles.copy()
background_color = "#f4f4f8"
styles[Generic.Output] = "#355"
styles[Generic.Prompt] = "bold #346ec9"
import pkg_resources
dist = pkg_resources.Distribution(__file__)
sys.path.append(".") # make 'conf' module findable
ep = pkg_resources.EntryPoint.parse("spack = conf:SpackStyle", dist=dist)
dist._ep_map = {"pygments.styles": {"plugin1": ep}}
pkg_resources.working_set.add(dist)
pygments_style = "spack"
sys.path.append("./_pygments")
pygments_style = "style.SpackStyle"
# A list of ignored prefixes for module index sorting.
# modindex_common_prefix = []
@@ -341,16 +317,15 @@ class SpackStyle(DefaultStyle):
# Output file base name for HTML help builder.
htmlhelp_basename = "Spackdoc"
# -- Options for LaTeX output --------------------------------------------------
latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
#'papersize': 'letterpaper',
# 'papersize': 'letterpaper',
# The font size ('10pt', '11pt' or '12pt').
#'pointsize': '10pt',
# 'pointsize': '10pt',
# Additional stuff for the LaTeX preamble.
#'preamble': '',
# 'preamble': '',
}
# Grouping the document tree into LaTeX files. List of tuples

View File

@@ -292,12 +292,13 @@ It is also worth noting that:
non_bindable_shared_objects = ["libinterface.so"]
----------------------
``terminal_title``
``install_status``
----------------------
By setting this option to ``true``, Spack will update the terminal's title to
provide information about its current progress as well as the current and
total package numbers.
When set to ``true``, Spack will show information about its current progress
as well as the current and total package numbers. Progress is shown both
in the terminal title and inline. Setting it to ``false`` will not show any
progress information.
To work properly, this requires your terminal to reset its title after
Spack has finished its work, otherwise Spack's status information will

View File

@@ -636,7 +636,7 @@ to customize the generation of container recipes:
- No
* - ``os_packages:command``
- Tool used to manage system packages
- ``apt``, ``yum``, ``zypper``, ``apk``, ``yum_amazon``
- ``apt``, ``yum``, ``dnf``, ``dnf_epel``, ``zypper``, ``apk``, ``yum_amazon``
- Only with custom base images
* - ``os_packages:update``
- Whether or not to update the list of available packages

View File

@@ -916,9 +916,9 @@ function, as shown in the example below:
.. code-block:: yaml
projections:
zlib: {name}-{version}
^mpi: {name}-{version}/{^mpi.name}-{^mpi.version}-{compiler.name}-{compiler.version}
all: {name}-{version}/{compiler.name}-{compiler.version}
zlib: "{name}-{version}"
^mpi: "{name}-{version}/{^mpi.name}-{^mpi.version}-{compiler.name}-{compiler.version}"
all: "{name}-{version}/{compiler.name}-{compiler.version}"
The entries in the projections configuration file must all be either
specs or the keyword ``all``. For each spec, the projection used will
@@ -1132,11 +1132,11 @@ index once every package is pushed. Note how this target uses the generated
example/push/%: example/install/%
@mkdir -p $(dir $@)
$(info About to push $(SPEC) to a buildcache)
$(SPACK) -e . buildcache create --allow-root --only=package --directory $(BUILDCACHE_DIR) /$(HASH)
$(SPACK) -e . buildcache push --allow-root --only=package $(BUILDCACHE_DIR) /$(HASH)
@touch $@
push: $(addprefix example/push/,$(example/SPACK_PACKAGE_IDS))
$(info Updating the buildcache index)
$(SPACK) -e . buildcache update-index --directory $(BUILDCACHE_DIR)
$(SPACK) -e . buildcache update-index $(BUILDCACHE_DIR)
$(info Done!)
@touch $@

View File

@@ -317,7 +317,7 @@ installed, but you know that new compilers have been added to your
.. code-block:: console
$ module load gcc-4.9.0
$ module load gcc/4.9.0
$ spack compiler find
==> Added 1 new compiler to ~/.spack/linux/compilers.yaml
gcc@4.9.0

View File

@@ -76,6 +76,7 @@ or refer to the full manual below.
chain
extensions
pipelines
signing
.. toctree::
:maxdepth: 2

View File

@@ -35,27 +35,27 @@ showing lots of installed packages:
$ module avail
--------------------------------------------------------------- ~/spack/share/spack/modules/linux-ubuntu14-x86_64 ---------------------------------------------------------------
autoconf-2.69-gcc-4.8-qextxkq hwloc-1.11.6-gcc-6.3.0-akcisez m4-1.4.18-gcc-4.8-ev2znoc openblas-0.2.19-gcc-6.3.0-dhkmed6 py-setuptools-34.2.0-gcc-6.3.0-fadur4s
automake-1.15-gcc-4.8-maqvukj isl-0.18-gcc-4.8-afi6taq m4-1.4.18-gcc-6.3.0-uppywnz openmpi-2.1.0-gcc-6.3.0-go2s4z5 py-six-1.10.0-gcc-6.3.0-p4dhkaw
binutils-2.28-gcc-4.8-5s7c6rs libiconv-1.15-gcc-4.8-at46wg3 mawk-1.3.4-gcc-4.8-acjez57 openssl-1.0.2k-gcc-4.8-dkls5tk python-2.7.13-gcc-6.3.0-tyehea7
bison-3.0.4-gcc-4.8-ek4luo5 libpciaccess-0.13.4-gcc-6.3.0-gmufnvh mawk-1.3.4-gcc-6.3.0-ostdoms openssl-1.0.2k-gcc-6.3.0-gxgr5or readline-7.0-gcc-4.8-xhufqhn
bzip2-1.0.6-gcc-4.8-iffrxzn libsigsegv-2.11-gcc-4.8-pp2cvte mpc-1.0.3-gcc-4.8-g5mztc5 pcre-8.40-gcc-4.8-r5pbrxb readline-7.0-gcc-6.3.0-zzcyicg
bzip2-1.0.6-gcc-6.3.0-bequudr libsigsegv-2.11-gcc-6.3.0-7enifnh mpfr-3.1.5-gcc-4.8-o7xm7az perl-5.24.1-gcc-4.8-dg5j65u sqlite-3.8.5-gcc-6.3.0-6zoruzj
cmake-3.7.2-gcc-6.3.0-fowuuby libtool-2.4.6-gcc-4.8-7a523za mpich-3.2-gcc-6.3.0-dmvd3aw perl-5.24.1-gcc-6.3.0-6uzkpt6 tar-1.29-gcc-4.8-wse2ass
curl-7.53.1-gcc-4.8-3fz46n6 libtool-2.4.6-gcc-6.3.0-n7zmbzt ncurses-6.0-gcc-4.8-dcpe7ia pkg-config-0.29.2-gcc-4.8-ib33t75 tcl-8.6.6-gcc-4.8-tfxzqbr
expat-2.2.0-gcc-4.8-mrv6bd4 libxml2-2.9.4-gcc-4.8-ryzxnsu ncurses-6.0-gcc-6.3.0-ucbhcdy pkg-config-0.29.2-gcc-6.3.0-jpgubk3 util-macros-1.19.1-gcc-6.3.0-xorz2x2
flex-2.6.3-gcc-4.8-yf345oo libxml2-2.9.4-gcc-6.3.0-rltzsdh netlib-lapack-3.6.1-gcc-6.3.0-js33dog py-appdirs-1.4.0-gcc-6.3.0-jxawmw7 xz-5.2.3-gcc-4.8-mew4log
gcc-6.3.0-gcc-4.8-24puqve lmod-7.4.1-gcc-4.8-je4srhr netlib-scalapack-2.0.2-gcc-6.3.0-5aidk4l py-numpy-1.12.0-gcc-6.3.0-oemmoeu xz-5.2.3-gcc-6.3.0-3vqeuvb
gettext-0.19.8.1-gcc-4.8-yymghlh lua-5.3.4-gcc-4.8-im75yaz netlib-scalapack-2.0.2-gcc-6.3.0-hjsemcn py-packaging-16.8-gcc-6.3.0-i2n3dtl zip-3.0-gcc-4.8-rwar22d
gmp-6.1.2-gcc-4.8-5ub2wu5 lua-luafilesystem-1_6_3-gcc-4.8-wkey3nl netlib-scalapack-2.0.2-gcc-6.3.0-jva724b py-pyparsing-2.1.10-gcc-6.3.0-tbo6gmw zlib-1.2.11-gcc-4.8-pgxsxv7
help2man-1.47.4-gcc-4.8-kcnqmau lua-luaposix-33.4.0-gcc-4.8-mdod2ry netlib-scalapack-2.0.2-gcc-6.3.0-rgqfr6d py-scipy-0.19.0-gcc-6.3.0-kr7nat4 zlib-1.2.11-gcc-6.3.0-7cqp6cj
autoconf/2.69-gcc-4.8-qextxkq hwloc/1.11.6-gcc-6.3.0-akcisez m4/1.4.18-gcc-4.8-ev2znoc openblas/0.2.19-gcc-6.3.0-dhkmed6 py-setuptools/34.2.0-gcc-6.3.0-fadur4s
automake/1.15-gcc-4.8-maqvukj isl/0.18-gcc-4.8-afi6taq m4/1.4.18-gcc-6.3.0-uppywnz openmpi/2.1.0-gcc-6.3.0-go2s4z5 py-six/1.10.0-gcc-6.3.0-p4dhkaw
binutils/2.28-gcc-4.8-5s7c6rs libiconv/1.15-gcc-4.8-at46wg3 mawk/1.3.4-gcc-4.8-acjez57 openssl/1.0.2k-gcc-4.8-dkls5tk python/2.7.13-gcc-6.3.0-tyehea7
bison/3.0.4-gcc-4.8-ek4luo5 libpciaccess/0.13.4-gcc-6.3.0-gmufnvh mawk/1.3.4-gcc-6.3.0-ostdoms openssl/1.0.2k-gcc-6.3.0-gxgr5or readline/7.0-gcc-4.8-xhufqhn
bzip2/1.0.6-gcc-4.8-iffrxzn libsigsegv/2.11-gcc-4.8-pp2cvte mpc/1.0.3-gcc-4.8-g5mztc5 pcre/8.40-gcc-4.8-r5pbrxb readline/7.0-gcc-6.3.0-zzcyicg
bzip2/1.0.6-gcc-6.3.0-bequudr libsigsegv/2.11-gcc-6.3.0-7enifnh mpfr/3.1.5-gcc-4.8-o7xm7az perl/5.24.1-gcc-4.8-dg5j65u sqlite/3.8.5-gcc-6.3.0-6zoruzj
cmake/3.7.2-gcc-6.3.0-fowuuby libtool/2.4.6-gcc-4.8-7a523za mpich/3.2-gcc-6.3.0-dmvd3aw perl/5.24.1-gcc-6.3.0-6uzkpt6 tar/1.29-gcc-4.8-wse2ass
curl/7.53.1-gcc-4.8-3fz46n6 libtool/2.4.6-gcc-6.3.0-n7zmbzt ncurses/6.0-gcc-4.8-dcpe7ia pkg-config/0.29.2-gcc-4.8-ib33t75 tcl/8.6.6-gcc-4.8-tfxzqbr
expat/2.2.0-gcc-4.8-mrv6bd4 libxml2/2.9.4-gcc-4.8-ryzxnsu ncurses/6.0-gcc-6.3.0-ucbhcdy pkg-config/0.29.2-gcc-6.3.0-jpgubk3 util-macros/1.19.1-gcc-6.3.0-xorz2x2
flex/2.6.3-gcc-4.8-yf345oo libxml2/2.9.4-gcc-6.3.0-rltzsdh netlib-lapack/3.6.1-gcc-6.3.0-js33dog py-appdirs/1.4.0-gcc-6.3.0-jxawmw7 xz/5.2.3-gcc-4.8-mew4log
gcc/6.3.0-gcc-4.8-24puqve lmod/7.4.1-gcc-4.8-je4srhr netlib-scalapack/2.0.2-gcc-6.3.0-5aidk4l py-numpy/1.12.0-gcc-6.3.0-oemmoeu xz/5.2.3-gcc-6.3.0-3vqeuvb
gettext/0.19.8.1-gcc-4.8-yymghlh lua/5.3.4-gcc-4.8-im75yaz netlib-scalapack/2.0.2-gcc-6.3.0-hjsemcn py-packaging/16.8-gcc-6.3.0-i2n3dtl zip/3.0-gcc-4.8-rwar22d
gmp/6.1.2-gcc-4.8-5ub2wu5 lua-luafilesystem/1_6_3-gcc-4.8-wkey3nl netlib-scalapack/2.0.2-gcc-6.3.0-jva724b py-pyparsing/2.1.10-gcc-6.3.0-tbo6gmw zlib/1.2.11-gcc-4.8-pgxsxv7
help2man/1.47.4-gcc-4.8-kcnqmau lua-luaposix/33.4.0-gcc-4.8-mdod2ry netlib-scalapack/2.0.2-gcc-6.3.0-rgqfr6d py-scipy/0.19.0-gcc-6.3.0-kr7nat4 zlib/1.2.11-gcc-6.3.0-7cqp6cj
The names should look familiar, as they resemble the output from ``spack find``.
For example, you could type the following command to load the ``cmake`` module:
.. code-block:: console
$ module load cmake-3.7.2-gcc-6.3.0-fowuuby
$ module load cmake/3.7.2-gcc-6.3.0-fowuuby
Neither of these is particularly pretty, easy to remember, or easy to
type. Luckily, Spack offers many facilities for customizing the module
@@ -275,10 +275,12 @@ of the installed software. For instance, in the snippet below:
set:
BAR: 'bar'
# This anonymous spec selects any package that
# depends on openmpi. The double colon at the
# depends on mpi. The double colon at the
# end clears the set of rules that matched so far.
^openmpi::
^mpi::
environment:
prepend_path:
PATH: '{^mpi.prefix}/bin'
set:
BAR: 'baz'
# Selects any zlib package
@@ -293,7 +295,9 @@ of the installed software. For instance, in the snippet below:
- FOOBAR
you are instructing Spack to set the environment variable ``BAR=bar`` for every module,
unless the associated spec satisfies ``^openmpi`` in which case ``BAR=baz``.
unless the associated spec satisfies the abstract dependency ``^mpi`` in which case
``BAR=baz``, and the directory containing the respective MPI executables is prepended
to the ``PATH`` variable.
In addition in any spec that satisfies ``zlib`` the value ``foo`` will be
prepended to ``LD_LIBRARY_PATH`` and in any spec that satisfies ``zlib%gcc@4.8``
the variable ``FOOBAR`` will be unset.
@@ -396,28 +400,30 @@ that are already in the Lmod hierarchy.
.. note::
Tcl modules
Tcl modules also allow for explicit conflicts between modulefiles.
Tcl and Lua modules also allow for explicit conflicts between modulefiles.
.. code-block:: yaml
.. code-block:: yaml
modules:
default:
enable:
- tcl
tcl:
projections:
all: '{name}/{version}-{compiler.name}-{compiler.version}'
all:
conflict:
- '{name}'
- 'intel/14.0.1'
modules:
default:
enable:
- tcl
tcl:
projections:
all: '{name}/{version}-{compiler.name}-{compiler.version}'
all:
conflict:
- '{name}'
- 'intel/14.0.1'
will create module files that will conflict with ``intel/14.0.1`` and with the
base directory of the same module, effectively preventing the possibility to
load two or more versions of the same software at the same time. The tokens
that are available for use in this directive are the same understood by
the :meth:`~spack.spec.Spec.format` method.
will create module files that will conflict with ``intel/14.0.1`` and with the
base directory of the same module, effectively preventing the possibility to
load two or more versions of the same software at the same time. The tokens
that are available for use in this directive are the same understood by the
:meth:`~spack.spec.Spec.format` method.
For Lmod and Environment Modules versions prior 4.2, it is important to
express the conflict on both modulefiles conflicting with each other.
.. note::
@@ -779,35 +785,35 @@ cut-and-pasted into a shell script. For example:
$ spack module tcl loads --dependencies py-numpy git
# bzip2@1.0.6%gcc@4.9.3=linux-x86_64
module load bzip2-1.0.6-gcc-4.9.3-ktnrhkrmbbtlvnagfatrarzjojmkvzsx
module load bzip2/1.0.6-gcc-4.9.3-ktnrhkrmbbtlvnagfatrarzjojmkvzsx
# ncurses@6.0%gcc@4.9.3=linux-x86_64
module load ncurses-6.0-gcc-4.9.3-kaazyneh3bjkfnalunchyqtygoe2mncv
module load ncurses/6.0-gcc-4.9.3-kaazyneh3bjkfnalunchyqtygoe2mncv
# zlib@1.2.8%gcc@4.9.3=linux-x86_64
module load zlib-1.2.8-gcc-4.9.3-v3ufwaahjnviyvgjcelo36nywx2ufj7z
module load zlib/1.2.8-gcc-4.9.3-v3ufwaahjnviyvgjcelo36nywx2ufj7z
# sqlite@3.8.5%gcc@4.9.3=linux-x86_64
module load sqlite-3.8.5-gcc-4.9.3-a3eediswgd5f3rmto7g3szoew5nhehbr
module load sqlite/3.8.5-gcc-4.9.3-a3eediswgd5f3rmto7g3szoew5nhehbr
# readline@6.3%gcc@4.9.3=linux-x86_64
module load readline-6.3-gcc-4.9.3-se6r3lsycrwxyhreg4lqirp6xixxejh3
module load readline/6.3-gcc-4.9.3-se6r3lsycrwxyhreg4lqirp6xixxejh3
# python@3.5.1%gcc@4.9.3=linux-x86_64
module load python-3.5.1-gcc-4.9.3-5q5rsrtjld4u6jiicuvtnx52m7tfhegi
module load python/3.5.1-gcc-4.9.3-5q5rsrtjld4u6jiicuvtnx52m7tfhegi
# py-setuptools@20.5%gcc@4.9.3=linux-x86_64
module load py-setuptools-20.5-gcc-4.9.3-4qr2suj6p6glepnedmwhl4f62x64wxw2
module load py-setuptools/20.5-gcc-4.9.3-4qr2suj6p6glepnedmwhl4f62x64wxw2
# py-nose@1.3.7%gcc@4.9.3=linux-x86_64
module load py-nose-1.3.7-gcc-4.9.3-pwhtjw2dvdvfzjwuuztkzr7b4l6zepli
module load py-nose/1.3.7-gcc-4.9.3-pwhtjw2dvdvfzjwuuztkzr7b4l6zepli
# openblas@0.2.17%gcc@4.9.3+shared=linux-x86_64
module load openblas-0.2.17-gcc-4.9.3-pw6rmlom7apfsnjtzfttyayzc7nx5e7y
module load openblas/0.2.17-gcc-4.9.3-pw6rmlom7apfsnjtzfttyayzc7nx5e7y
# py-numpy@1.11.0%gcc@4.9.3+blas+lapack=linux-x86_64
module load py-numpy-1.11.0-gcc-4.9.3-mulodttw5pcyjufva4htsktwty4qd52r
module load py-numpy/1.11.0-gcc-4.9.3-mulodttw5pcyjufva4htsktwty4qd52r
# curl@7.47.1%gcc@4.9.3=linux-x86_64
module load curl-7.47.1-gcc-4.9.3-ohz3fwsepm3b462p5lnaquv7op7naqbi
module load curl/7.47.1-gcc-4.9.3-ohz3fwsepm3b462p5lnaquv7op7naqbi
# autoconf@2.69%gcc@4.9.3=linux-x86_64
module load autoconf-2.69-gcc-4.9.3-bkibjqhgqm5e3o423ogfv2y3o6h2uoq4
module load autoconf/2.69-gcc-4.9.3-bkibjqhgqm5e3o423ogfv2y3o6h2uoq4
# cmake@3.5.0%gcc@4.9.3~doc+ncurses+openssl~qt=linux-x86_64
module load cmake-3.5.0-gcc-4.9.3-x7xnsklmgwla3ubfgzppamtbqk5rwn7t
module load cmake/3.5.0-gcc-4.9.3-x7xnsklmgwla3ubfgzppamtbqk5rwn7t
# expat@2.1.0%gcc@4.9.3=linux-x86_64
module load expat-2.1.0-gcc-4.9.3-6pkz2ucnk2e62imwakejjvbv6egncppd
module load expat/2.1.0-gcc-4.9.3-6pkz2ucnk2e62imwakejjvbv6egncppd
# git@2.8.0-rc2%gcc@4.9.3+curl+expat=linux-x86_64
module load git-2.8.0-rc2-gcc-4.9.3-3bib4hqtnv5xjjoq5ugt3inblt4xrgkd
module load git/2.8.0-rc2-gcc-4.9.3-3bib4hqtnv5xjjoq5ugt3inblt4xrgkd
The script may be further edited by removing unnecessary modules.
@@ -826,12 +832,12 @@ For example, consider the following on one system:
.. code-block:: console
$ module avail
linux-SuSE11-x86_64/antlr-2.7.7-gcc-5.3.0-bdpl46y
linux-SuSE11-x86_64/antlr/2.7.7-gcc-5.3.0-bdpl46y
$ spack module tcl loads antlr # WRONG!
# antlr@2.7.7%gcc@5.3.0~csharp+cxx~java~python arch=linux-SuSE11-x86_64
module load antlr-2.7.7-gcc-5.3.0-bdpl46y
module load antlr/2.7.7-gcc-5.3.0-bdpl46y
$ spack module tcl loads --prefix linux-SuSE11-x86_64/ antlr
# antlr@2.7.7%gcc@5.3.0~csharp+cxx~java~python arch=linux-SuSE11-x86_64
module load linux-SuSE11-x86_64/antlr-2.7.7-gcc-5.3.0-bdpl46y
module load linux-SuSE11-x86_64/antlr/2.7.7-gcc-5.3.0-bdpl46y

View File

@@ -121,7 +121,7 @@ Since v0.19, Spack supports two ways of writing a package recipe. The most comm
def url_for_version(self, version):
if version >= Version("2.1.1"):
return super(Openjpeg, self).url_for_version(version)
return super().url_for_version(version)
url_fmt = "https://github.com/uclouvain/openjpeg/archive/version.{0}.tar.gz"
return url_fmt.format(version)
@@ -155,7 +155,7 @@ builder class explicitly. Using the same example as above, this reads:
def url_for_version(self, version):
if version >= Version("2.1.1"):
return super(Openjpeg, self).url_for_version(version)
return super().url_for_version(version)
url_fmt = "https://github.com/uclouvain/openjpeg/archive/version.{0}.tar.gz"
return url_fmt.format(version)
@@ -3071,7 +3071,7 @@ follows:
# The library provided by the bar virtual package
@property
def bar_libs(self):
return find_libraries("libFooBar", root=sef.home, recursive=True)
return find_libraries("libFooBar", root=self.home, recursive=True)
# The baz virtual package home
@property

View File

@@ -1,13 +1,13 @@
# These dependencies should be installed using pip in order
# to build the documentation.
sphinx>=3.4,!=4.1.2,!=5.1.0
sphinxcontrib-programoutput
sphinx-design
sphinx-rtd-theme
python-levenshtein
# Restrict to docutils <0.17 to workaround a list rendering issue in sphinx.
# https://stackoverflow.com/questions/67542699
docutils <0.17
pygments <2.13
urllib3 <2
sphinx==6.2.1
sphinxcontrib-programoutput==0.17
sphinx_design==0.4.1
sphinx-rtd-theme==1.2.2
python-levenshtein==0.21.1
docutils==0.18.1
pygments==2.15.1
urllib3==2.0.3
pytest==7.4.0
isort==5.12.0
black==23.1.0
flake8==6.0.0
mypy==1.4.1

478
lib/spack/docs/signing.rst Normal file
View File

@@ -0,0 +1,478 @@
.. Copyright 2013-2022 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)
.. _signing:
=====================
Spack Package Signing
=====================
The goal of package signing in Spack is to provide data integrity
assurances around official packages produced by the automated Spack CI
pipelines. These assurances directly address the security of Spacks
software supply chain by explaining why a security-conscious user can
be reasonably justified in the belief that packages installed via Spack
have an uninterrupted auditable trail back to change management
decisions judged to be appropriate by the Spack maintainers. This is
achieved through cryptographic signing of packages built by Spack CI
pipelines based on code that has been transparently reviewed and
approved on GitHub. This document describes the signing process for
interested users.
.. _risks:
------------------------------
Risks, Impact and Threat Model
------------------------------
This document addresses the approach taken to safeguard Spacks
reputation with regard to the integrity of the package data produced by
Spacks CI pipelines. It does not address issues of data confidentiality
(Spack is intended to be largely open source) or availability (efforts
are described elsewhere). With that said the main reputational risk can
be broadly categorized as a loss of faith in the data integrity due to a
breach of the private key used to sign packages. Remediation of a
private key breach would require republishing the public key with a
revocation certificate, generating a new signing key, an assessment and
potential rebuild/resigning of all packages since the key was breached,
and finally direct intervention by every spack user to update their copy
of Spacks public keys used for local verification.
The primary threat model used in mitigating the risks of these stated
impacts is one of individual error not malicious intent or insider
threat. The primary objective is to avoid the above impacts by making a
private key breach nearly impossible due to oversight or configuration
error. Obvious and straightforward measures are taken to mitigate issues
of malicious interference in data integrity and insider threats but
these attack vectors are not systematically addressed. It should be hard
to exfiltrate the private key intentionally, and almost impossible to
leak the key by accident.
.. _overview:
-----------------
Pipeline Overview
-----------------
Spack pipelines build software through progressive stages where packages
in later stages nominally depend on packages built in earlier stages.
For both technical and design reasons these dependencies are not
implemented through the default GitLab artifacts mechanism; instead
built packages are uploaded to AWS S3 mirrors (buckets) where they are
retrieved by subsequent stages in the pipeline. Two broad categories of
pipelines exist: Pull Request (PR) pipelines and Develop/Release
pipelines.
- PR pipelines are launched in response to pull requests made by
trusted and untrusted users. Packages built on these pipelines upload
code to quarantined AWS S3 locations which cache the built packages
for the purposes of review and iteration on the changes proposed in
the pull request. Packages built on PR pipelines can come from
untrusted users so signing of these pipelines is not implemented.
Jobs in these pipelines are executed via normal GitLab runners both
within the AWS GitLab infrastructure and at affiliated institutions.
- Develop and Release pipelines **sign** the packages they produce and carry
strong integrity assurances that trace back to auditable change management
decisions. These pipelines only run after members from a trusted group of
reviewers verify that the proposed changes in a pull request are appropriate.
Once the PR is merged, or a release is cut, a pipeline is run on protected
GitLab runners which provide access to the required signing keys within the
job. Intermediary keys are used to sign packages in each stage of the
pipeline as they are built and a final job officially signs each package
external to any specific packages build environment. An intermediate key
exists in the AWS infrastructure and for each affiliated instritution that
maintains protected runners. The runners that execute these pipelines
exclusively accept jobs from protected branches meaning the intermediate keys
are never exposed to unreviewed code and the official keys are never exposed
to any specific build environment.
.. _key_architecture:
----------------
Key Architecture
----------------
Spacks CI process uses public-key infrastructure (PKI) based on GNU Privacy
Guard (gpg) keypairs to sign public releases of spack package metadata, also
called specs. Two classes of GPG keys are involved in the process to reduce the
impact of an individual private key compromise, these key classes are the
*Intermediate CI Key* and *Reputational Key*. Each of these keys has signing
sub-keys that are used exclusively for signing packages. This can be confusing
so for the purpose of this explanation well refer to Root and Signing keys.
Each key has a private and a public component as well as one or more identities
and zero or more signatures.
-------------------
Intermediate CI Key
-------------------
The Intermediate key class is used to sign and verify packages between stages
within a develop or release pipeline. An intermediate key exists for the AWS
infrastructure as well as each affiliated institution that maintains protected
runners. These intermediate keys are made available to the GitLab execution
environment building the package so that the packages dependencies may be
verified by the Signing Intermediate CI Public Key and the final package may be
signed by the Signing Intermediate CI Private Key.
+---------------------------------------------------------------------------------------------------------+
| **Intermediate CI Key (GPG)** |
+==================================================+======================================================+
| Root Intermediate CI Private Key (RSA 4096)# | Root Intermediate CI Public Key (RSA 4096) |
+--------------------------------------------------+------------------------------------------------------+
| Signing Intermediate CI Private Key (RSA 4096) | Signing Intermediate CI Public Key (RSA 4096) |
+--------------------------------------------------+------------------------------------------------------+
| Identity: “Intermediate CI Key <maintainers@spack.io>” |
+---------------------------------------------------------------------------------------------------------+
| Signatures: None |
+---------------------------------------------------------------------------------------------------------+
The *Root intermediate CI Private Key*\ Is stripped out of the GPG key and
stored offline completely separate from Spacks infrastructure. This allows the
core development team to append revocation certificates to the GPG key and
issue new sub-keys for use in the pipeline. It is our expectation that this
will happen on a semi regular basis. A corollary of this is that *this key
should not be used to verify package integrity outside the internal CI process.*
----------------
Reputational Key
----------------
The Reputational Key is the public facing key used to sign complete groups of
development and release packages. Only one key pair exsits in this class of
keys. In contrast to the Intermediate CI Key the Reputational Key *should* be
used to verify package integrity. At the end of develop and release pipeline a
final pipeline job pulls down all signed package metadata built by the pipeline,
verifies they were signed with an Intermediate CI Key, then strips the
Intermediate CI Key signature from the package and re-signs them with the
Signing Reputational Private Key. The officially signed packages are then
uploaded back to the AWS S3 mirror. Please note that separating use of the
reputational key into this final job is done to prevent leakage of the key in a
spack package. Because the Signing Reputational Private Key is never exposed to
a build job it cannot accidentally end up in any built package.
+---------------------------------------------------------------------------------------------------------+
| **Reputational Key (GPG)** |
+==================================================+======================================================+
| Root Reputational Private Key (RSA 4096)# | Root Reputational Public Key (RSA 4096) |
+--------------------------------------------------+------------------------------------------------------+
| Signing Reputational Private Key (RSA 4096) | Signing Reputational Public Key (RSA 4096) |
+--------------------------------------------------+------------------------------------------------------+
| Identity: “Spack Project <maintainers@spack.io>” |
+---------------------------------------------------------------------------------------------------------+
| Signatures: Signed by core development team [#f1]_ |
+---------------------------------------------------------------------------------------------------------+
The Root Reputational Private Key is stripped out of the GPG key and stored
offline completely separate from Spacks infrastructure. This allows the core
development team to append revocation certificates to the GPG key in the
unlikely event that the Signing Reputation Private Key is compromised. In
general it is the expectation that rotating this key will happen infrequently if
at all. This should allow relatively transparent verification for the end-user
community without needing deep familiarity with GnuPG or Public Key
Infrastructure.
.. _build_cache_format:
------------------
Build Cache Format
------------------
A binary package consists of a metadata file unambiguously defining the
built package (and including other details such as how to relocate it)
and the installation directory of the package stored as a compressed
archive file. The metadata files can either be unsigned, in which case
the contents are simply the json-serialized concrete spec plus metadata,
or they can be signed, in which case the json-serialized concrete spec
plus metadata is wrapped in a gpg cleartext signature. Built package
metadata files are named to indicate the operating system and
architecture for which the package was built as well as the compiler
used to build it and the packages name and version. For example::
linux-ubuntu18.04-haswell-gcc-7.5.0-zlib-1.2.12-llv2ysfdxnppzjrt5ldybb5c52qbmoow.spec.json.sig
would contain the concrete spec and binary metadata for a binary package
of ``zlib@1.2.12``, built for the ``ubuntu`` operating system and ``haswell``
architecture. The id of the built package exists in the name of the file
as well (after the package name and version) and in this case begins
with ``llv2ys``. The id distinguishes a particular built package from all
other built packages with the same os/arch, compiler, name, and version.
Below is an example of a signed binary package metadata file. Such a
file would live in the ``build_cache`` directory of a binary mirror::
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
{
"spec": {
<concrete-spec-contents-omitted>
},
"buildcache_layout_version": 1,
"binary_cache_checksum": {
"hash_algorithm": "sha256",
"hash": "4f1e46452c35a5e61bcacca205bae1bfcd60a83a399af201a29c95b7cc3e1423"
}
}
-----BEGIN PGP SIGNATURE-----
iQGzBAEBCgAdFiEETZn0sLle8jIrdAPLx/P+voVcifMFAmKAGvwACgkQx/P+voVc
ifNoVgv/VrhA+wurVs5GB9PhmMA1m5U/AfXZb4BElDRwpT8ZcTPIv5X8xtv60eyn
4EOneGVbZoMThVxgev/NKARorGmhFXRqhWf+jknJZ1dicpqn/qpv34rELKUpgXU+
QDQ4d1P64AIdTczXe2GI9ZvhOo6+bPvK7LIsTkBbtWmopkomVxF0LcMuxAVIbA6b
887yBvVO0VGlqRnkDW7nXx49r3AG2+wDcoU1f8ep8QtjOcMNaPTPJ0UnjD0VQGW6
4ZFaGZWzdo45MY6tF3o5mqM7zJkVobpoW3iUz6J5tjz7H/nMlGgMkUwY9Kxp2PVH
qoj6Zip3LWplnl2OZyAY+vflPFdFh12Xpk4FG7Sxm/ux0r+l8tCAPvtw+G38a5P7
QEk2JBr8qMGKASmnRlJUkm1vwz0a95IF3S9YDfTAA2vz6HH3PtsNLFhtorfx8eBi
Wn5aPJAGEPOawEOvXGGbsH4cDEKPeN0n6cy1k92uPEmBLDVsdnur8q42jk5c2Qyx
j3DXty57
=3gvm
-----END PGP SIGNATURE-----
If a user has trusted the public key associated with the private key
used to sign the above spec file, the signature can be verified with
gpg, as follows::
$ gpg verify linux-ubuntu18.04-haswell-gcc-7.5.0-zlib-1.2.12-llv2ysfdxnppzjrt5ldybb5c52qbmoow.spec.json.sig
The metadata (regardless whether signed or unsigned) contains the checksum
of the ``.spack`` file containing the actual installation. The checksum should
be compared to a checksum computed locally on the ``.spack`` file to ensure the
contents have not changed since the binary spec plus metadata were signed. The
``.spack`` files are actually tarballs containing the compressed archive of the
install tree. These files, along with the metadata files, live within the
``build_cache`` directory of the mirror, and together are organized as follows::
build_cache/
# unsigned metadata (for indexing, contains sha256 of .spack file)
<arch>-<compiler>-<name>-<ver>-24zvipcqgg2wyjpvdq2ajy5jnm564hen.spec.json
# clearsigned metadata (same as above, but signed)
<arch>-<compiler>-<name>-<ver>-24zvipcqgg2wyjpvdq2ajy5jnm564hen.spec.json.sig
<arch>/
<compiler>/
<name>-<ver>/
# tar.gz-compressed prefix (may support more compression formats later)
<arch>-<compiler>-<name>-<ver>-24zvipcqgg2wyjpvdq2ajy5jnm564hen.spack
Uncompressing and extracting the ``.spack`` file results in the install tree.
This is in contrast to previous versions of spack, where the ``.spack`` file
contained a (duplicated) metadata file, a signature file and a nested tarball
containing the install tree.
.. _internal_implementation:
-----------------------
Internal Implementation
-----------------------
The technical implementation of the pipeline signing process includes components
defined in Amazon Web Services, the Kubernetes cluster, at affilicated
institutions, and the GitLab/GitLab Runner deployment. We present the techincal
implementation in two interdependent sections. The first addresses how secrets
are managed through the lifecycle of a develop or release pipeline. The second
section describes how Gitlab Runner and pipelines are configured and managed to
support secure automated signing.
Secrets Management
^^^^^^^^^^^^^^^^^^
As stated above the Root Private Keys (intermediate and reputational)
are stripped from the GPG keys and stored outside Spacks
infrastructure.
.. warning::
**TODO**
- Explanation here about where and how access is handled for these keys.
- Both Root private keys are protected with strong passwords
- Who has access to these and how?
**Intermediate CI Key**
-----------------------
Multiple intermediate CI signing keys exist, one Intermediate CI Key for jobs
run in AWS, and one key for each affiliated institution (e.g. Univerity of
Oregon). Here we describe how the Intermediate CI Key is managed in AWS:
The Intermediate CI Key (including the Signing Intermediate CI Private Key is
exported as an ASCII armored file and stored in a Kubernetes secret called
``spack-intermediate-ci-signing-key``. For convenience sake, this same secret
contains an ASCII-armored export of just the *public* components of the
Reputational Key. This secret also contains the *public* components of each of
the affiliated institutions' Intermediate CI Key. These are potentially needed
to verify dependent packages which may have been found in the public mirror or
built by a protected job running on an affiliated institution's infrastrcuture
in an earlier stage of the pipeline.
Procedurally the ``spack-intermediate-ci-signing-key`` secret is used in
the following way:
1. A ``large-arm-prot`` or ``large-x86-prot`` protected runner picks up
a job tagged ``protected`` from a protected GitLab branch. (See
`Protected Runners and Reserved Tags <#_8bawjmgykv0b>`__).
2. Based on its configuration, the runner creates a job Pod in the
pipeline namespace and mounts the spack-intermediate-ci-signing-key
Kubernetes secret into the build container
3. The Intermediate CI Key, affiliated institutions' public key and the
Reputational Public Key are imported into a keyring by the ``spack gpg …``
sub-command. This is initiated by the jobs build script which is created by
the generate job at the beginning of the pipeline.
4. Assuming the package has dependencies those specs are verified using
the keyring.
5. The package is built and the spec.json is generated
6. The spec.json is signed by the keyring and uploaded to the mirrors
build cache.
**Reputational Key**
--------------------
Because of the increased impact to end users in the case of a private
key breach, the Reputational Key is managed separately from the
Intermediate CI Keys and has additional controls. First, the Reputational
Key was generated outside of Spacks infrastructure and has been signed
by the core development team. The Reputational Key (along with the
Signing Reputational Private Key) was then ASCII armor exported to a
file. Unlike the Intermediate CI Key this exported file is not stored as
a base64 encoded secret in Kubernetes. Instead\ *the key file
itself*\ is encrypted and stored in Kubernetes as the
``spack-signing-key-encrypted`` secret in the pipeline namespace.
The encryption of the exported Reputational Key (including the Signing
Reputational Private Key) is handled by `AWS Key Management Store (KMS) data
keys
<https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#data-keys>`__.
The private key material is decrypted and imported at the time of signing into a
memory mounted temporary directory holding the keychain. The signing job uses
the `AWS Encryption SDK
<https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/crypto-cli.html>`__
(i.e. ``aws-encryption-cli``) to decrypt the Reputational Key. Permission to
decrypt the key is granted to the job Pod through a Kubernetes service account
specifically used for this, and only this, function. Finally, for convenience
sake, this same secret contains an ASCII-armored export of the *public*
components of the Intermediate CI Keys and the Reputational Key. This allows the
signing script to verify that packages were built by the pipeline (both on AWS
or at affiliated institutions), or signed previously as a part of a different
pipeline. This is is done *before* importing decrypting and importing the
Signing Reputational Private Key material and officially signing the packages.
Procedurally the ``spack-singing-key-encrypted`` secret is used in the
following way:
1. The ``spack-package-signing-gitlab-runner`` protected runner picks
up a job tagged ``notary`` from a protected GitLab branch (See
`Protected Runners and Reserved Tags <#_8bawjmgykv0b>`__).
2. Based on its configuration, the runner creates a job pod in the
pipeline namespace. The job is run in a stripped down purpose-built
image ``ghcr.io/spack/notary:latest`` Docker image. The runner is
configured to only allow running jobs with this image.
3. The runner also mounts the ``spack-signing-key-encrypted`` secret to
a path on disk. Note that this becomes several files on disk, the
public components of the Intermediate CI Keys, the public components
of the Reputational CI, and an AWS KMS encrypted file containing the
Singing Reputational Private Key.
4. In addition to the secret, the runner creates a tmpfs memory mounted
directory where the GnuPG keyring will be created to verify, and
then resign the package specs.
5. The job script syncs all spec.json.sig files from the build cache to
a working directory in the jobs execution environment.
6. The job script then runs the ``sign.sh`` script built into the
notary Docker image.
7. The ``sign.sh`` script imports the public components of the
Reputational and Intermediate CI Keys and uses them to verify good
signatures on the spec.json.sig files. If any signed spec does not
verify the job immediately fails.
8. Assuming all specs are verified, the ``sign.sh`` script then unpacks
the spec json data from the signed file in preparation for being
re-signed with the Reputational Key.
9. The private components of the Reputational Key are decrypted to
standard out using ``aws-encryption-cli`` directly into a ``gpg
import …`` statement which imports the key into the
keyring mounted in-memory.
10. The private key is then used to sign each of the json specs and the
keyring is removed from disk.
11. The re-signed json specs are resynced to the AWS S3 Mirror and the
public signing of the packages for the develop or release pipeline
that created them is complete.
Non service-account access to the private components of the Reputational
Key that are managed through access to the symmetric secret in KMS used
to encrypt the data key (which in turn is used to encrypt the GnuPG key
- See:\ `Encryption SDK
Documentation <https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/crypto-cli-examples.html#cli-example-encrypt-file>`__).
A small trusted subset of the core development team are the only
individuals with access to this symmetric key.
.. _protected_runners:
Protected Runners and Reserved Tags
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Spack has a large number of Gitlab Runners operating in its build farm.
These include runners deployed in the AWS Kubernetes cluster as well as
runners deployed at affiliated institutions. The majority of runners are
shared runners that operate across projects in gitlab.spack.io. These
runners pick up jobs primarily from the spack/spack project and execute
them in PR pipelines.
A small number of runners operating on AWS and at affiliated institutions are
registered as specific *protected* runners on the spack/spack project. In
addition to protected runners there are protected branches on the spack/spack
project. These are the ``develop`` branch, any release branch (i.e. managed with
the ``releases/v*`` wildcard) and any tag branch (managed with the ``v*``
wildcard) Finally Spacks pipeline generation code reserves certain tags to make
sure jobs are routed to the correct runners, these tags are ``public``,
``protected``, and ``notary``. Understanding how all this works together to
protect secrets and provide integrity assurances can be a little confusing so
lets break these down:
- **Protected Branches**- Protected branches in Spack prevent anyone
other than Maintainers in GitLab from pushing code. In the case of
Spack the only Maintainer level entity pushing code to protected
branches is Spack bot. Protecting branches also marks them in such a
way that Protected Runners will only run jobs from those branches
- **Protected Runners**- Protected Runners only run jobs from protected
branches. Because protected runners have access to secrets, it's critical
that they not run Jobs from untrusted code (i.e. PR branches). If they did it
would be possible for a PR branch to tag a job in such a way that a protected
runner executed that job and mounted secrets into a code execution
environment that had not been reviewed by Spack maintainers. Note however
that in the absence of tagging used to route jobs, public runners *could* run
jobs from protected branches. No secrets would be at risk of being breached
because non-protected runners do not have access to those secrets; lack of
secrets would, however, cause the jobs to fail.
- **Reserved Tags**- To mitigate the issue of public runners picking up
protected jobs Spack uses a small set of “reserved” job tags (Note that these
are *job* tags not git tags). These tags are “public”, “private”, and
“notary.” The majority of jobs executed in Spacks GitLab instance are
executed via a ``generate`` job. The generate job code systematically ensures
that no user defined configuration sets these tags. Instead, the ``generate``
job sets these tags based on rules related to the branch where this pipeline
originated. If the job is a part of a pipeline on a PR branch it sets the
``public`` tag. If the job is part of a pipeline on a protected branch it
sets the ``protected`` tag. Finally if the job is the package signing job and
it is running on a pipeline that is part of a protected branch then it sets
the ``notary`` tag.
Protected Runners are configured to only run jobs from protected branches. Only
jobs running in pipelines on protected branches are tagged with ``protected`` or
``notary`` tags. This tightly couples jobs on protected branches to protected
runners that provide access to the secrets required to sign the built packages.
The secrets are can **only** be accessed via:
1. Runners under direct control of the core development team.
2. Runners under direct control of trusted maintainers at affiliated institutions.
3. By code running the automated pipeline that has been reviewed by the
Spack maintainers and judged to be appropriate.
Other attempts (either through malicious intent or incompetence) can at
worst grab jobs intended for protected runners which will cause those
jobs to fail alerting both Spack maintainers and the core development
team.
.. [#f1]
The Reputational Key has also cross signed core development team
keys.

428
lib/spack/env/cc vendored
View File

@@ -416,30 +416,14 @@ input_command="$*"
# The lists are all bell-separated to be as flexible as possible, as their
# contents may come from the command line, from ' '-separated lists,
# ':'-separated lists, etc.
include_dirs_list=""
lib_dirs_list=""
rpath_dirs_list=""
system_include_dirs_list=""
system_lib_dirs_list=""
system_rpath_dirs_list=""
isystem_system_include_dirs_list=""
isystem_include_dirs_list=""
libs_list=""
other_args_list=""
# Global state for keeping track of -Wl,-rpath -Wl,/path
wl_expect_rpath=no
# Same, but for -Xlinker -rpath -Xlinker /path
xlinker_expect_rpath=no
parse_Wl() {
while [ $# -ne 0 ]; do
if [ "$wl_expect_rpath" = yes ]; then
if system_dir "$1"; then
append system_rpath_dirs_list "$1"
append return_system_rpath_dirs_list "$1"
else
append rpath_dirs_list "$1"
append return_rpath_dirs_list "$1"
fi
wl_expect_rpath=no
else
@@ -449,9 +433,9 @@ parse_Wl() {
if [ -z "$arg" ]; then
shift; continue
elif system_dir "$arg"; then
append system_rpath_dirs_list "$arg"
append return_system_rpath_dirs_list "$arg"
else
append rpath_dirs_list "$arg"
append return_rpath_dirs_list "$arg"
fi
;;
--rpath=*)
@@ -459,9 +443,9 @@ parse_Wl() {
if [ -z "$arg" ]; then
shift; continue
elif system_dir "$arg"; then
append system_rpath_dirs_list "$arg"
append return_system_rpath_dirs_list "$arg"
else
append rpath_dirs_list "$arg"
append return_rpath_dirs_list "$arg"
fi
;;
-rpath|--rpath)
@@ -475,7 +459,7 @@ parse_Wl() {
return 1
;;
*)
append other_args_list "-Wl,$1"
append return_other_args_list "-Wl,$1"
;;
esac
fi
@@ -483,177 +467,210 @@ parse_Wl() {
done
}
categorize_arguments() {
while [ $# -ne 0 ]; do
unset IFS
# an RPATH to be added after the case statement.
rp=""
return_other_args_list=""
return_isystem_was_used=""
return_isystem_system_include_dirs_list=""
return_isystem_include_dirs_list=""
return_system_include_dirs_list=""
return_include_dirs_list=""
return_system_lib_dirs_list=""
return_lib_dirs_list=""
return_system_rpath_dirs_list=""
return_rpath_dirs_list=""
# Multiple consecutive spaces in the command line can
# result in blank arguments
if [ -z "$1" ]; then
shift
continue
fi
# Global state for keeping track of -Wl,-rpath -Wl,/path
wl_expect_rpath=no
if [ -n "${SPACK_COMPILER_FLAGS_KEEP}" ] ; then
# NOTE: the eval is required to allow `|` alternatives inside the variable
eval "\
case \"\$1\" in
$SPACK_COMPILER_FLAGS_KEEP)
append other_args_list \"\$1\"
# Same, but for -Xlinker -rpath -Xlinker /path
xlinker_expect_rpath=no
while [ $# -ne 0 ]; do
# an RPATH to be added after the case statement.
rp=""
# Multiple consecutive spaces in the command line can
# result in blank arguments
if [ -z "$1" ]; then
shift
continue
fi
if [ -n "${SPACK_COMPILER_FLAGS_KEEP}" ] ; then
# NOTE: the eval is required to allow `|` alternatives inside the variable
eval "\
case \"\$1\" in
$SPACK_COMPILER_FLAGS_KEEP)
append return_other_args_list \"\$1\"
shift
continue
;;
esac
"
fi
# the replace list is a space-separated list of pipe-separated pairs,
# the first in each pair is the original prefix to be matched, the
# second is the replacement prefix
if [ -n "${SPACK_COMPILER_FLAGS_REPLACE}" ] ; then
for rep in ${SPACK_COMPILER_FLAGS_REPLACE} ; do
before=${rep%|*}
after=${rep#*|}
eval "\
stripped=\"\${1##$before}\"
"
if [ "$stripped" = "$1" ] ; then
continue
fi
replaced="$after$stripped"
# it matched, remove it
shift
continue
if [ -z "$replaced" ] ; then
# completely removed, continue OUTER loop
continue 2
fi
# re-build argument list with replacement
set -- "$replaced" "$@"
done
fi
case "$1" in
-isystem*)
arg="${1#-isystem}"
return_isystem_was_used=true
if [ -z "$arg" ]; then shift; arg="$1"; fi
if system_dir "$arg"; then
append return_isystem_system_include_dirs_list "$arg"
else
append return_isystem_include_dirs_list "$arg"
fi
;;
-I*)
arg="${1#-I}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
if system_dir "$arg"; then
append return_system_include_dirs_list "$arg"
else
append return_include_dirs_list "$arg"
fi
;;
-L*)
arg="${1#-L}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
if system_dir "$arg"; then
append return_system_lib_dirs_list "$arg"
else
append return_lib_dirs_list "$arg"
fi
;;
-l*)
# -loopopt=0 is generated erroneously in autoconf <= 2.69,
# and passed by ifx to the linker, which confuses it with a
# library. Filter it out.
# TODO: generalize filtering of args with an env var, so that
# TODO: we do not have to special case this here.
if { [ "$mode" = "ccld" ] || [ $mode = "ld" ]; } \
&& [ "$1" != "${1#-loopopt}" ]; then
shift
continue
fi
arg="${1#-l}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
append return_other_args_list "-l$arg"
;;
-Wl,*)
IFS=,
if ! parse_Wl ${1#-Wl,}; then
append return_other_args_list "$1"
fi
unset IFS
;;
-Xlinker)
shift
if [ $# -eq 0 ]; then
# -Xlinker without value: let the compiler error about it.
append return_other_args_list -Xlinker
xlinker_expect_rpath=no
break
elif [ "$xlinker_expect_rpath" = yes ]; then
# Register the path of -Xlinker -rpath <other args> -Xlinker <path>
if system_dir "$1"; then
append return_system_rpath_dirs_list "$1"
else
append return_rpath_dirs_list "$1"
fi
xlinker_expect_rpath=no
else
case "$1" in
-rpath=*)
arg="${1#-rpath=}"
if system_dir "$arg"; then
append return_system_rpath_dirs_list "$arg"
else
append return_rpath_dirs_list "$arg"
fi
;;
--rpath=*)
arg="${1#--rpath=}"
if system_dir "$arg"; then
append return_system_rpath_dirs_list "$arg"
else
append return_rpath_dirs_list "$arg"
fi
;;
-rpath|--rpath)
xlinker_expect_rpath=yes
;;
"$dtags_to_strip")
;;
*)
append return_other_args_list -Xlinker
append return_other_args_list "$1"
;;
esac
fi
;;
"$dtags_to_strip")
;;
*)
append return_other_args_list "$1"
;;
esac
"
fi
# the replace list is a space-separated list of pipe-separated pairs,
# the first in each pair is the original prefix to be matched, the
# second is the replacement prefix
if [ -n "${SPACK_COMPILER_FLAGS_REPLACE}" ] ; then
for rep in ${SPACK_COMPILER_FLAGS_REPLACE} ; do
before=${rep%|*}
after=${rep#*|}
eval "\
stripped=\"\${1##$before}\"
"
if [ "$stripped" = "$1" ] ; then
continue
fi
shift
done
replaced="$after$stripped"
# it matched, remove it
shift
if [ -z "$replaced" ] ; then
# completely removed, continue OUTER loop
continue 2
fi
# re-build argument list with replacement
set -- "$replaced" "$@"
done
# We found `-Xlinker -rpath` but no matching value `-Xlinker /path`. Just append
# `-Xlinker -rpath` again and let the compiler or linker handle the error during arg
# parsing.
if [ "$xlinker_expect_rpath" = yes ]; then
append return_other_args_list -Xlinker
append return_other_args_list -rpath
fi
case "$1" in
-isystem*)
arg="${1#-isystem}"
isystem_was_used=true
if [ -z "$arg" ]; then shift; arg="$1"; fi
if system_dir "$arg"; then
append isystem_system_include_dirs_list "$arg"
else
append isystem_include_dirs_list "$arg"
fi
;;
-I*)
arg="${1#-I}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
if system_dir "$arg"; then
append system_include_dirs_list "$arg"
else
append include_dirs_list "$arg"
fi
;;
-L*)
arg="${1#-L}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
if system_dir "$arg"; then
append system_lib_dirs_list "$arg"
else
append lib_dirs_list "$arg"
fi
;;
-l*)
# -loopopt=0 is generated erroneously in autoconf <= 2.69,
# and passed by ifx to the linker, which confuses it with a
# library. Filter it out.
# TODO: generalize filtering of args with an env var, so that
# TODO: we do not have to special case this here.
if { [ "$mode" = "ccld" ] || [ $mode = "ld" ]; } \
&& [ "$1" != "${1#-loopopt}" ]; then
shift
continue
fi
arg="${1#-l}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
append other_args_list "-l$arg"
;;
-Wl,*)
IFS=,
if ! parse_Wl ${1#-Wl,}; then
append other_args_list "$1"
fi
unset IFS
;;
-Xlinker)
shift
if [ $# -eq 0 ]; then
# -Xlinker without value: let the compiler error about it.
append other_args_list -Xlinker
xlinker_expect_rpath=no
break
elif [ "$xlinker_expect_rpath" = yes ]; then
# Register the path of -Xlinker -rpath <other args> -Xlinker <path>
if system_dir "$1"; then
append system_rpath_dirs_list "$1"
else
append rpath_dirs_list "$1"
fi
xlinker_expect_rpath=no
else
case "$1" in
-rpath=*)
arg="${1#-rpath=}"
if system_dir "$arg"; then
append system_rpath_dirs_list "$arg"
else
append rpath_dirs_list "$arg"
fi
;;
--rpath=*)
arg="${1#--rpath=}"
if system_dir "$arg"; then
append system_rpath_dirs_list "$arg"
else
append rpath_dirs_list "$arg"
fi
;;
-rpath|--rpath)
xlinker_expect_rpath=yes
;;
"$dtags_to_strip")
;;
*)
append other_args_list -Xlinker
append other_args_list "$1"
;;
esac
fi
;;
"$dtags_to_strip")
;;
*)
append other_args_list "$1"
;;
esac
shift
done
# Same, but for -Wl flags.
if [ "$wl_expect_rpath" = yes ]; then
append return_other_args_list -Wl,-rpath
fi
}
# We found `-Xlinker -rpath` but no matching value `-Xlinker /path`. Just append
# `-Xlinker -rpath` again and let the compiler or linker handle the error during arg
# parsing.
if [ "$xlinker_expect_rpath" = yes ]; then
append other_args_list -Xlinker
append other_args_list -rpath
fi
# Same, but for -Wl flags.
if [ "$wl_expect_rpath" = yes ]; then
append other_args_list -Wl,-rpath
fi
categorize_arguments "$@"
include_dirs_list="$return_include_dirs_list"
lib_dirs_list="$return_lib_dirs_list"
rpath_dirs_list="$return_rpath_dirs_list"
system_include_dirs_list="$return_system_include_dirs_list"
system_lib_dirs_list="$return_system_lib_dirs_list"
system_rpath_dirs_list="$return_system_rpath_dirs_list"
isystem_was_used="$return_isystem_was_used"
isystem_system_include_dirs_list="$return_isystem_system_include_dirs_list"
isystem_include_dirs_list="$return_isystem_include_dirs_list"
other_args_list="$return_other_args_list"
#
# Add flags from Spack's cppflags, cflags, cxxflags, fcflags, fflags, and
@@ -673,12 +690,14 @@ elif [ "$SPACK_ADD_DEBUG_FLAGS" = "custom" ]; then
extend flags_list SPACK_DEBUG_FLAGS
fi
spack_flags_list=""
# Fortran flags come before CPPFLAGS
case "$mode" in
cc|ccld)
case $lang_flags in
F)
extend flags_list SPACK_FFLAGS
extend spack_flags_list SPACK_FFLAGS
;;
esac
;;
@@ -687,7 +706,7 @@ esac
# C preprocessor flags come before any C/CXX flags
case "$mode" in
cpp|as|cc|ccld)
extend flags_list SPACK_CPPFLAGS
extend spack_flags_list SPACK_CPPFLAGS
;;
esac
@@ -697,10 +716,10 @@ case "$mode" in
cc|ccld)
case $lang_flags in
C)
extend flags_list SPACK_CFLAGS
extend spack_flags_list SPACK_CFLAGS
;;
CXX)
extend flags_list SPACK_CXXFLAGS
extend spack_flags_list SPACK_CXXFLAGS
;;
esac
@@ -712,10 +731,25 @@ esac
# Linker flags
case "$mode" in
ld|ccld)
extend flags_list SPACK_LDFLAGS
extend spack_flags_list SPACK_LDFLAGS
;;
esac
IFS="$lsep"
categorize_arguments $spack_flags_list
unset IFS
spack_flags_include_dirs_list="$return_include_dirs_list"
spack_flags_lib_dirs_list="$return_lib_dirs_list"
spack_flags_rpath_dirs_list="$return_rpath_dirs_list"
spack_flags_system_include_dirs_list="$return_system_include_dirs_list"
spack_flags_system_lib_dirs_list="$return_system_lib_dirs_list"
spack_flags_system_rpath_dirs_list="$return_system_rpath_dirs_list"
spack_flags_isystem_was_used="$return_isystem_was_used"
spack_flags_isystem_system_include_dirs_list="$return_isystem_system_include_dirs_list"
spack_flags_isystem_include_dirs_list="$return_isystem_include_dirs_list"
spack_flags_other_args_list="$return_other_args_list"
# On macOS insert headerpad_max_install_names linker flag
if [ "$mode" = ld ] || [ "$mode" = ccld ]; then
if [ "${SPACK_SHORT_SPEC#*darwin}" != "${SPACK_SHORT_SPEC}" ]; then
@@ -741,6 +775,8 @@ if [ "$mode" = ccld ] || [ "$mode" = ld ]; then
extend lib_dirs_list SPACK_LINK_DIRS
fi
libs_list=""
# add RPATHs if we're in in any linking mode
case "$mode" in
ld|ccld)
@@ -769,12 +805,16 @@ args_list="$flags_list"
# Insert include directories just prior to any system include directories
# NOTE: adding ${lsep} to the prefix here turns every added element into two
extend args_list spack_flags_include_dirs_list "-I"
extend args_list include_dirs_list "-I"
extend args_list spack_flags_isystem_include_dirs_list "-isystem${lsep}"
extend args_list isystem_include_dirs_list "-isystem${lsep}"
case "$mode" in
cpp|cc|as|ccld)
if [ "$isystem_was_used" = "true" ]; then
if [ "$spack_flags_isystem_was_used" = "true" ]; then
extend args_list SPACK_INCLUDE_DIRS "-isystem${lsep}"
elif [ "$isystem_was_used" = "true" ]; then
extend args_list SPACK_INCLUDE_DIRS "-isystem${lsep}"
else
extend args_list SPACK_INCLUDE_DIRS "-I"
@@ -782,11 +822,15 @@ case "$mode" in
;;
esac
extend args_list spack_flags_system_include_dirs_list -I
extend args_list system_include_dirs_list -I
extend args_list spack_flags_isystem_system_include_dirs_list "-isystem${lsep}"
extend args_list isystem_system_include_dirs_list "-isystem${lsep}"
# Library search paths
extend args_list spack_flags_lib_dirs_list "-L"
extend args_list lib_dirs_list "-L"
extend args_list spack_flags_system_lib_dirs_list "-L"
extend args_list system_lib_dirs_list "-L"
# RPATHs arguments
@@ -795,20 +839,25 @@ case "$mode" in
if [ -n "$dtags_to_add" ] ; then
append args_list "$linker_arg$dtags_to_add"
fi
extend args_list spack_flags_rpath_dirs_list "$rpath"
extend args_list rpath_dirs_list "$rpath"
extend args_list spack_flags_system_rpath_dirs_list "$rpath"
extend args_list system_rpath_dirs_list "$rpath"
;;
ld)
if [ -n "$dtags_to_add" ] ; then
append args_list "$dtags_to_add"
fi
extend args_list spack_flags_rpath_dirs_list "-rpath${lsep}"
extend args_list rpath_dirs_list "-rpath${lsep}"
extend args_list spack_flags_system_rpath_dirs_list "-rpath${lsep}"
extend args_list system_rpath_dirs_list "-rpath${lsep}"
;;
esac
# Other arguments from the input command
extend args_list other_args_list
extend args_list spack_flags_other_args_list
# Inject SPACK_LDLIBS, if supplied
extend args_list libs_list "-l"
@@ -864,3 +913,4 @@ fi
# Execute the full command, preserving spaces with IFS set
# to the alarm bell separator.
IFS="$lsep"; exec $full_command_list

View File

@@ -65,9 +65,6 @@
up to date with CTest, just make sure the ``*_matches`` and
``*_exceptions`` lists are kept up to date with CTest's build handler.
"""
from __future__ import print_function
from __future__ import division
import re
import math
import multiprocessing
@@ -211,7 +208,7 @@
]
class LogEvent(object):
class LogEvent:
"""Class representing interesting events (e.g., errors) in a build log."""
def __init__(self, text, line_no,
source_file=None, source_line_no=None,
@@ -348,7 +345,7 @@ def _parse_unpack(args):
return _parse(*args)
class CTestLogParser(object):
class CTestLogParser:
"""Log file parser that extracts errors and warnings."""
def __init__(self, profile=False):
# whether to record timing information

View File

@@ -3,33 +3,42 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import abc
import argparse
import errno
import io
import re
import sys
from argparse import ArgumentParser
from typing import IO, Any, Iterable, List, Optional, Sequence, Tuple, Union
class Command(object):
class Command:
"""Parsed representation of a command from argparse.
This is a single command from an argparse parser. ``ArgparseWriter``
creates these and returns them from ``parse()``, and it passes one of
these to each call to ``format()`` so that we can take an action for
a single command.
Parts of a Command:
- prog: command name (str)
- description: command description (str)
- usage: command usage (str)
- positionals: list of positional arguments (list)
- optionals: list of optional arguments (list)
- subcommands: list of subcommand parsers (list)
This is a single command from an argparse parser. ``ArgparseWriter`` creates these and returns
them from ``parse()``, and it passes one of these to each call to ``format()`` so that we can
take an action for a single command.
"""
def __init__(self, prog, description, usage, positionals, optionals, subcommands):
def __init__(
self,
prog: str,
description: Optional[str],
usage: str,
positionals: List[Tuple[str, Optional[Iterable[Any]], Union[int, str, None], str]],
optionals: List[Tuple[Sequence[str], List[str], str, Union[int, str, None], str]],
subcommands: List[Tuple[ArgumentParser, str, str]],
) -> None:
"""Initialize a new Command instance.
Args:
prog: Program name.
description: Command description.
usage: Command usage.
positionals: List of positional arguments.
optionals: List of optional arguments.
subcommands: List of subcommand parsers.
"""
self.prog = prog
self.description = description
self.usage = usage
@@ -38,35 +47,34 @@ def __init__(self, prog, description, usage, positionals, optionals, subcommands
self.subcommands = subcommands
# NOTE: The only reason we subclass argparse.HelpFormatter is to get access
# to self._expand_help(), ArgparseWriter is not intended to be used as a
# formatter_class.
class ArgparseWriter(argparse.HelpFormatter):
"""Analyzes an argparse ArgumentParser for easy generation of help."""
# NOTE: The only reason we subclass argparse.HelpFormatter is to get access to self._expand_help(),
# ArgparseWriter is not intended to be used as a formatter_class.
class ArgparseWriter(argparse.HelpFormatter, abc.ABC):
"""Analyze an argparse ArgumentParser for easy generation of help."""
def __init__(self, prog, out=None, aliases=False):
"""Initializes a new ArgparseWriter instance.
def __init__(self, prog: str, out: IO = sys.stdout, aliases: bool = False) -> None:
"""Initialize a new ArgparseWriter instance.
Parameters:
prog (str): the program name
out (file object): the file to write to (default sys.stdout)
aliases (bool): whether or not to include subparsers for aliases
Args:
prog: Program name.
out: File object to write to.
aliases: Whether or not to include subparsers for aliases.
"""
super(ArgparseWriter, self).__init__(prog)
super().__init__(prog)
self.level = 0
self.prog = prog
self.out = sys.stdout if out is None else out
self.out = out
self.aliases = aliases
def parse(self, parser, prog):
"""Parses the parser object and returns the relavent components.
def parse(self, parser: ArgumentParser, prog: str) -> Command:
"""Parse the parser object and return the relavent components.
Parameters:
parser (argparse.ArgumentParser): the parser
prog (str): the command name
Args:
parser: Command parser.
prog: Program name.
Returns:
(Command) information about the command from the parser
Information about the command from the parser.
"""
self.parser = parser
@@ -80,8 +88,7 @@ def parse(self, parser, prog):
groups = parser._mutually_exclusive_groups
usage = fmt._format_usage(None, actions, groups, "").strip()
# Go through actions and split them into optionals, positionals,
# and subcommands
# Go through actions and split them into optionals, positionals, and subcommands
optionals = []
positionals = []
subcommands = []
@@ -89,74 +96,97 @@ def parse(self, parser, prog):
if action.option_strings:
flags = action.option_strings
dest_flags = fmt._format_action_invocation(action)
help = self._expand_help(action) if action.help else ""
help = help.replace("\n", " ")
optionals.append((flags, dest_flags, help))
nargs = action.nargs
help = (
self._expand_help(action)
if action.help and action.help != argparse.SUPPRESS
else ""
)
help = help.split("\n")[0]
if action.choices is not None:
dest = [str(choice) for choice in action.choices]
else:
dest = [action.dest]
optionals.append((flags, dest, dest_flags, nargs, help))
elif isinstance(action, argparse._SubParsersAction):
for subaction in action._choices_actions:
subparser = action._name_parser_map[subaction.dest]
subcommands.append((subparser, subaction.dest))
help = (
self._expand_help(subaction)
if subaction.help and action.help != argparse.SUPPRESS
else ""
)
help = help.split("\n")[0]
subcommands.append((subparser, subaction.dest, help))
# Look for aliases of the form 'name (alias, ...)'
if self.aliases:
if self.aliases and isinstance(subaction.metavar, str):
match = re.match(r"(.*) \((.*)\)", subaction.metavar)
if match:
aliases = match.group(2).split(", ")
for alias in aliases:
subparser = action._name_parser_map[alias]
subcommands.append((subparser, alias))
help = (
self._expand_help(subaction)
if subaction.help and action.help != argparse.SUPPRESS
else ""
)
help = help.split("\n")[0]
subcommands.append((subparser, alias, help))
else:
args = fmt._format_action_invocation(action)
help = self._expand_help(action) if action.help else ""
help = help.replace("\n", " ")
positionals.append((args, help))
help = (
self._expand_help(action)
if action.help and action.help != argparse.SUPPRESS
else ""
)
help = help.split("\n")[0]
positionals.append((args, action.choices, action.nargs, help))
return Command(prog, description, usage, positionals, optionals, subcommands)
def format(self, cmd):
"""Returns the string representation of a single node in the
parser tree.
@abc.abstractmethod
def format(self, cmd: Command) -> str:
"""Return the string representation of a single node in the parser tree.
Override this in subclasses to define how each subcommand
should be displayed.
Override this in subclasses to define how each subcommand should be displayed.
Parameters:
(Command): parsed information about a command or subcommand
Args:
cmd: Parsed information about a command or subcommand.
Returns:
str: the string representation of this subcommand
String representation of this subcommand.
"""
raise NotImplementedError
def _write(self, parser, prog, level=0):
"""Recursively writes a parser.
def _write(self, parser: ArgumentParser, prog: str, level: int = 0) -> None:
"""Recursively write a parser.
Parameters:
parser (argparse.ArgumentParser): the parser
prog (str): the command name
level (int): the current level
Args:
parser: Command parser.
prog: Program name.
level: Current level.
"""
self.level = level
cmd = self.parse(parser, prog)
self.out.write(self.format(cmd))
for subparser, prog in cmd.subcommands:
for subparser, prog, help in cmd.subcommands:
self._write(subparser, prog, level=level + 1)
def write(self, parser):
def write(self, parser: ArgumentParser) -> None:
"""Write out details about an ArgumentParser.
Args:
parser (argparse.ArgumentParser): the parser
parser: Command parser.
"""
try:
self._write(parser, self.prog)
except IOError as e:
except BrokenPipeError:
# Swallow pipe errors
# Raises IOError in Python 2 and BrokenPipeError in Python 3
if e.errno != errno.EPIPE:
raise
pass
_rst_levels = ["=", "-", "^", "~", ":", "`"]
@@ -165,21 +195,33 @@ def write(self, parser):
class ArgparseRstWriter(ArgparseWriter):
"""Write argparse output as rst sections."""
def __init__(self, prog, out=None, aliases=False, rst_levels=_rst_levels):
"""Create a new ArgparseRstWriter.
def __init__(
self,
prog: str,
out: IO = sys.stdout,
aliases: bool = False,
rst_levels: Sequence[str] = _rst_levels,
) -> None:
"""Initialize a new ArgparseRstWriter instance.
Parameters:
prog (str): program name
out (file object): file to write to
aliases (bool): whether or not to include subparsers for aliases
rst_levels (list of str): list of characters
for rst section headings
Args:
prog: Program name.
out: File object to write to.
aliases: Whether or not to include subparsers for aliases.
rst_levels: List of characters for rst section headings.
"""
out = sys.stdout if out is None else out
super(ArgparseRstWriter, self).__init__(prog, out, aliases)
super().__init__(prog, out, aliases)
self.rst_levels = rst_levels
def format(self, cmd):
def format(self, cmd: Command) -> str:
"""Return the string representation of a single node in the parser tree.
Args:
cmd: Parsed information about a command or subcommand.
Returns:
String representation of a node.
"""
string = io.StringIO()
string.write(self.begin_command(cmd.prog))
@@ -190,13 +232,13 @@ def format(self, cmd):
if cmd.positionals:
string.write(self.begin_positionals())
for args, help in cmd.positionals:
for args, choices, nargs, help in cmd.positionals:
string.write(self.positional(args, help))
string.write(self.end_positionals())
if cmd.optionals:
string.write(self.begin_optionals())
for flags, dest_flags, help in cmd.optionals:
for flags, dest, dest_flags, nargs, help in cmd.optionals:
string.write(self.optional(dest_flags, help))
string.write(self.end_optionals())
@@ -205,7 +247,15 @@ def format(self, cmd):
return string.getvalue()
def begin_command(self, prog):
def begin_command(self, prog: str) -> str:
"""Text to print before a command.
Args:
prog: Program name.
Returns:
Text before a command.
"""
return """
----
@@ -218,10 +268,26 @@ def begin_command(self, prog):
prog.replace(" ", "-"), prog, self.rst_levels[self.level] * len(prog)
)
def description(self, description):
def description(self, description: str) -> str:
"""Description of a command.
Args:
description: Command description.
Returns:
Description of a command.
"""
return description + "\n\n"
def usage(self, usage):
def usage(self, usage: str) -> str:
"""Example usage of a command.
Args:
usage: Command usage.
Returns:
Usage of a command.
"""
return """\
.. code-block:: console
@@ -231,10 +297,24 @@ def usage(self, usage):
usage
)
def begin_positionals(self):
def begin_positionals(self) -> str:
"""Text to print before positional arguments.
Returns:
Positional arguments header.
"""
return "\n**Positional arguments**\n\n"
def positional(self, name, help):
def positional(self, name: str, help: str) -> str:
"""Description of a positional argument.
Args:
name: Argument name.
help: Help text.
Returns:
Positional argument description.
"""
return """\
{0}
{1}
@@ -243,13 +323,32 @@ def positional(self, name, help):
name, help
)
def end_positionals(self):
def end_positionals(self) -> str:
"""Text to print after positional arguments.
Returns:
Positional arguments footer.
"""
return ""
def begin_optionals(self):
def begin_optionals(self) -> str:
"""Text to print before optional arguments.
Returns:
Optional arguments header.
"""
return "\n**Optional arguments**\n\n"
def optional(self, opts, help):
def optional(self, opts: str, help: str) -> str:
"""Description of an optional argument.
Args:
opts: Optional argument.
help: Help text.
Returns:
Optional argument description.
"""
return """\
``{0}``
{1}
@@ -258,10 +357,23 @@ def optional(self, opts, help):
opts, help
)
def end_optionals(self):
def end_optionals(self) -> str:
"""Text to print after optional arguments.
Returns:
Optional arguments footer.
"""
return ""
def begin_subcommands(self, subcommands):
def begin_subcommands(self, subcommands: List[Tuple[ArgumentParser, str, str]]) -> str:
"""Table with links to other subcommands.
Arguments:
subcommands: List of subcommands.
Returns:
Subcommand linking text.
"""
string = """
**Subcommands**
@@ -270,116 +382,8 @@ def begin_subcommands(self, subcommands):
"""
for cmd, _ in subcommands:
for cmd, _, _ in subcommands:
prog = re.sub(r"^[^ ]* ", "", cmd.prog)
string += " * :ref:`{0} <{1}>`\n".format(prog, cmd.prog.replace(" ", "-"))
return string + "\n"
class ArgparseCompletionWriter(ArgparseWriter):
"""Write argparse output as shell programmable tab completion functions."""
def format(self, cmd):
"""Returns the string representation of a single node in the
parser tree.
Override this in subclasses to define how each subcommand
should be displayed.
Parameters:
(Command): parsed information about a command or subcommand
Returns:
str: the string representation of this subcommand
"""
assert cmd.optionals # we should always at least have -h, --help
assert not (cmd.positionals and cmd.subcommands) # one or the other
# We only care about the arguments/flags, not the help messages
positionals = []
if cmd.positionals:
positionals, _ = zip(*cmd.positionals)
optionals, _, _ = zip(*cmd.optionals)
subcommands = []
if cmd.subcommands:
_, subcommands = zip(*cmd.subcommands)
# Flatten lists of lists
optionals = [x for xx in optionals for x in xx]
return (
self.start_function(cmd.prog)
+ self.body(positionals, optionals, subcommands)
+ self.end_function(cmd.prog)
)
def start_function(self, prog):
"""Returns the syntax needed to begin a function definition.
Parameters:
prog (str): the command name
Returns:
str: the function definition beginning
"""
name = prog.replace("-", "_").replace(" ", "_")
return "\n_{0}() {{".format(name)
def end_function(self, prog=None):
"""Returns the syntax needed to end a function definition.
Parameters:
prog (str or None): the command name
Returns:
str: the function definition ending
"""
return "}\n"
def body(self, positionals, optionals, subcommands):
"""Returns the body of the function.
Parameters:
positionals (list): list of positional arguments
optionals (list): list of optional arguments
subcommands (list): list of subcommand parsers
Returns:
str: the function body
"""
return ""
def positionals(self, positionals):
"""Returns the syntax for reporting positional arguments.
Parameters:
positionals (list): list of positional arguments
Returns:
str: the syntax for positional arguments
"""
return ""
def optionals(self, optionals):
"""Returns the syntax for reporting optional flags.
Parameters:
optionals (list): list of optional arguments
Returns:
str: the syntax for optional flags
"""
return ""
def subcommands(self, subcommands):
"""Returns the syntax for reporting subcommands.
Parameters:
subcommands (list): list of subcommand parsers
Returns:
str: the syntax for subcommand parsers
"""
return ""

View File

@@ -402,7 +402,7 @@ def groupid_to_group(x):
os.remove(backup_filename)
class FileFilter(object):
class FileFilter:
"""Convenience class for calling ``filter_file`` a lot."""
def __init__(self, *filenames):
@@ -610,6 +610,8 @@ def chgrp(path, group, follow_symlinks=True):
gid = grp.getgrnam(group).gr_gid
else:
gid = group
if os.stat(path).st_gid == gid:
return
if follow_symlinks:
os.chown(path, -1, gid)
else:
@@ -1336,7 +1338,7 @@ def lexists_islink_isdir(path):
return True, is_link, is_dir
class BaseDirectoryVisitor(object):
class BaseDirectoryVisitor:
"""Base class and interface for :py:func:`visit_directory_tree`."""
def visit_file(self, root, rel_path, depth):
@@ -1890,7 +1892,7 @@ class HeaderList(FileList):
include_regex = re.compile(r"(.*?)(\binclude\b)(.*)")
def __init__(self, files):
super(HeaderList, self).__init__(files)
super().__init__(files)
self._macro_definitions = []
self._directories = None
@@ -1916,7 +1918,7 @@ def _default_directories(self):
"""Default computation of directories based on the list of
header files.
"""
dir_list = super(HeaderList, self).directories
dir_list = super().directories
values = []
for d in dir_list:
# If the path contains a subdirectory named 'include' then stop
@@ -2352,7 +2354,7 @@ def find_all_libraries(root, recursive=False):
)
class WindowsSimulatedRPath(object):
class WindowsSimulatedRPath:
"""Class representing Windows filesystem rpath analog
One instance of this class is associated with a package (only on Windows)

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import division
import collections.abc
import contextlib
import functools
@@ -768,10 +766,10 @@ def pretty_seconds(seconds):
class RequiredAttributeError(ValueError):
def __init__(self, message):
super(RequiredAttributeError, self).__init__(message)
super().__init__(message)
class ObjectWrapper(object):
class ObjectWrapper:
"""Base class that wraps an object. Derived classes can add new behavior
while staying undercover.
@@ -798,7 +796,7 @@ def __init__(self, wrapped_object):
self.__dict__ = wrapped_object.__dict__
class Singleton(object):
class Singleton:
"""Simple wrapper for lazily initialized singleton objects."""
def __init__(self, factory):
@@ -823,7 +821,7 @@ def __getattr__(self, name):
# 'instance'/'_instance' to be defined or it will enter an infinite
# loop, so protect against that here.
if name in ["_instance", "instance"]:
raise AttributeError()
raise AttributeError(f"cannot create {name}")
return getattr(self.instance, name)
def __getitem__(self, name):
@@ -845,27 +843,6 @@ def __repr__(self):
return repr(self.instance)
class LazyReference(object):
"""Lazily evaluated reference to part of a singleton."""
def __init__(self, ref_function):
self.ref_function = ref_function
def __getattr__(self, name):
if name == "ref_function":
raise AttributeError()
return getattr(self.ref_function(), name)
def __getitem__(self, name):
return self.ref_function()[name]
def __str__(self):
return str(self.ref_function())
def __repr__(self):
return repr(self.ref_function())
def load_module_from_file(module_name, module_path):
"""Loads a python module from the path of the corresponding file.
@@ -943,7 +920,7 @@ def _wrapper(args):
return _wrapper
class Devnull(object):
class Devnull:
"""Null stream with less overhead than ``os.devnull``.
See https://stackoverflow.com/a/2929954.
@@ -1060,7 +1037,7 @@ def __str__(self):
return str(self.data)
class GroupedExceptionHandler(object):
class GroupedExceptionHandler:
"""A generic mechanism to coalesce multiple exceptions and preserve tracebacks."""
def __init__(self):
@@ -1091,7 +1068,7 @@ def grouped_message(self, with_tracebacks: bool = True) -> str:
return "due to the following failures:\n{0}".format("\n".join(each_exception_message))
class GroupedExceptionForwarder(object):
class GroupedExceptionForwarder:
"""A contextmanager to capture exceptions and forward them to a
GroupedExceptionHandler."""
@@ -1111,7 +1088,7 @@ def __exit__(self, exc_type, exc_value, tb):
return True
class classproperty(object):
class classproperty:
"""Non-data descriptor to evaluate a class-level property. The function that performs
the evaluation is injected at creation time and take an instance (could be None) and
an owner (i.e. the class that originated the instance)

View File

@@ -5,8 +5,6 @@
"""LinkTree class for setting up trees of symbolic links."""
from __future__ import print_function
import filecmp
import os
import shutil
@@ -287,7 +285,7 @@ def visit_symlinked_file(self, root, rel_path, depth):
self.visit_file(root, rel_path, depth)
class LinkTree(object):
class LinkTree:
"""Class to create trees of symbolic links from a source directory.
LinkTree objects are constructed with a source root. Their
@@ -432,12 +430,12 @@ class MergeConflictError(Exception):
class ConflictingSpecsError(MergeConflictError):
def __init__(self, spec_1, spec_2):
super(MergeConflictError, self).__init__(spec_1, spec_2)
super().__init__(spec_1, spec_2)
class SingleMergeConflictError(MergeConflictError):
def __init__(self, path):
super(MergeConflictError, self).__init__("Package merge blocked by file: %s" % path)
super().__init__("Package merge blocked by file: %s" % path)
class MergeConflictSummary(MergeConflictError):
@@ -452,4 +450,4 @@ def __init__(self, conflicts):
msg += "\n `{0}` and `{1}` both project to `{2}`".format(
conflict.src_a, conflict.src_b, conflict.dst
)
super(MergeConflictSummary, self).__init__(msg)
super().__init__(msg)

View File

@@ -9,9 +9,10 @@
import sys
import time
from datetime import datetime
from types import TracebackType
from typing import IO, Any, Callable, ContextManager, Dict, Generator, Optional, Tuple, Type, Union
import llnl.util.tty as tty
from llnl.util.lang import pretty_seconds
from llnl.util import lang, tty
import spack.util.string
@@ -34,12 +35,15 @@
]
#: A useful replacement for functions that should return True when not provided
#: for example.
true_fn = lambda: True
ReleaseFnType = Optional[Callable[[], bool]]
class OpenFile(object):
def true_fn() -> bool:
"""A function that always returns True."""
return True
class OpenFile:
"""Record for keeping track of open lockfiles (with reference counting).
There's really only one ``OpenFile`` per inode, per process, but we record the
@@ -48,12 +52,12 @@ class OpenFile(object):
file descriptors as well in the future.
"""
def __init__(self, fh):
def __init__(self, fh: IO) -> None:
self.fh = fh
self.refs = 0
class OpenFileTracker(object):
class OpenFileTracker:
"""Track open lockfiles, to minimize number of open file descriptors.
The ``fcntl`` locks that Spack uses are associated with an inode and a process.
@@ -78,11 +82,11 @@ class OpenFileTracker(object):
work in Python and assume the GIL.
"""
def __init__(self):
def __init__(self) -> None:
"""Create a new ``OpenFileTracker``."""
self._descriptors = {}
self._descriptors: Dict[Any, OpenFile] = {}
def get_fh(self, path):
def get_fh(self, path: str) -> IO:
"""Get a filehandle for a lockfile.
This routine will open writable files for read/write even if you're asking
@@ -90,7 +94,7 @@ def get_fh(self, path):
(write) lock later if requested.
Arguments:
path (str): path to lock file we want a filehandle for
path: path to lock file we want a filehandle for
"""
# Open writable files as 'r+' so we can upgrade to write later
os_mode, fh_mode = (os.O_RDWR | os.O_CREAT), "r+"
@@ -157,7 +161,7 @@ def purge(self):
#: Open file descriptors for locks in this process. Used to prevent one process
#: from opening the sam file many times for different byte range locks
file_tracker = OpenFileTracker()
FILE_TRACKER = OpenFileTracker()
def _attempts_str(wait_time, nattempts):
@@ -166,10 +170,10 @@ def _attempts_str(wait_time, nattempts):
return ""
attempts = spack.util.string.plural(nattempts, "attempt")
return " after {} and {}".format(pretty_seconds(wait_time), attempts)
return " after {} and {}".format(lang.pretty_seconds(wait_time), attempts)
class LockType(object):
class LockType:
READ = 0
WRITE = 1
@@ -188,11 +192,11 @@ def to_module(tid):
return lock
@staticmethod
def is_valid(op):
def is_valid(op: int) -> bool:
return op == LockType.READ or op == LockType.WRITE
class Lock(object):
class Lock:
"""This is an implementation of a filesystem lock using Python's lockf.
In Python, ``lockf`` actually calls ``fcntl``, so this should work with
@@ -207,7 +211,16 @@ class Lock(object):
overlapping byte ranges in the same file).
"""
def __init__(self, path, start=0, length=0, default_timeout=None, debug=False, desc=""):
def __init__(
self,
path: str,
*,
start: int = 0,
length: int = 0,
default_timeout: Optional[float] = None,
debug: bool = False,
desc: str = "",
) -> None:
"""Construct a new lock on the file at ``path``.
By default, the lock applies to the whole file. Optionally,
@@ -220,17 +233,17 @@ def __init__(self, path, start=0, length=0, default_timeout=None, debug=False, d
beginning of the file.
Args:
path (str): path to the lock
start (int): optional byte offset at which the lock starts
length (int): optional number of bytes to lock
default_timeout (int): number of seconds to wait for lock attempts,
path: path to the lock
start: optional byte offset at which the lock starts
length: optional number of bytes to lock
default_timeout: seconds to wait for lock attempts,
where None means to wait indefinitely
debug (bool): debug mode specific to locking
desc (str): optional debug message lock description, which is
debug: debug mode specific to locking
desc: optional debug message lock description, which is
helpful for distinguishing between different Spack locks.
"""
self.path = path
self._file = None
self._file: Optional[IO] = None
self._reads = 0
self._writes = 0
@@ -242,7 +255,7 @@ def __init__(self, path, start=0, length=0, default_timeout=None, debug=False, d
self.debug = debug
# optional debug description
self.desc = " ({0})".format(desc) if desc else ""
self.desc = f" ({desc})" if desc else ""
# If the user doesn't set a default timeout, or if they choose
# None, 0, etc. then lock attempts will not time out (unless the
@@ -250,11 +263,15 @@ def __init__(self, path, start=0, length=0, default_timeout=None, debug=False, d
self.default_timeout = default_timeout or None
# PID and host of lock holder (only used in debug mode)
self.pid = self.old_pid = None
self.host = self.old_host = None
self.pid: Optional[int] = None
self.old_pid: Optional[int] = None
self.host: Optional[str] = None
self.old_host: Optional[str] = None
@staticmethod
def _poll_interval_generator(_wait_times=None):
def _poll_interval_generator(
_wait_times: Optional[Tuple[float, float, float]] = None
) -> Generator[float, None, None]:
"""This implements a backoff scheme for polling a contended resource
by suggesting a succession of wait times between polls.
@@ -277,21 +294,21 @@ def _poll_interval_generator(_wait_times=None):
num_requests += 1
yield wait_time
def __repr__(self):
def __repr__(self) -> str:
"""Formal representation of the lock."""
rep = "{0}(".format(self.__class__.__name__)
for attr, value in self.__dict__.items():
rep += "{0}={1}, ".format(attr, value.__repr__())
return "{0})".format(rep.strip(", "))
def __str__(self):
def __str__(self) -> str:
"""Readable string (with key fields) of the lock."""
location = "{0}[{1}:{2}]".format(self.path, self._start, self._length)
timeout = "timeout={0}".format(self.default_timeout)
activity = "#reads={0}, #writes={1}".format(self._reads, self._writes)
return "({0}, {1}, {2})".format(location, timeout, activity)
def _lock(self, op, timeout=None):
def _lock(self, op: int, timeout: Optional[float] = None) -> Tuple[float, int]:
"""This takes a lock using POSIX locks (``fcntl.lockf``).
The lock is implemented as a spin lock using a nonblocking call
@@ -310,7 +327,7 @@ def _lock(self, op, timeout=None):
# Create file and parent directories if they don't exist.
if self._file is None:
self._ensure_parent_directory()
self._file = file_tracker.get_fh(self.path)
self._file = FILE_TRACKER.get_fh(self.path)
if LockType.to_module(op) == fcntl.LOCK_EX and self._file.mode == "r":
# Attempt to upgrade to write lock w/a read-only file.
@@ -319,7 +336,7 @@ def _lock(self, op, timeout=None):
self._log_debug(
"{} locking [{}:{}]: timeout {}".format(
op_str.lower(), self._start, self._length, pretty_seconds(timeout or 0)
op_str.lower(), self._start, self._length, lang.pretty_seconds(timeout or 0)
)
)
@@ -343,15 +360,20 @@ def _lock(self, op, timeout=None):
total_wait_time = time.time() - start_time
raise LockTimeoutError(op_str.lower(), self.path, total_wait_time, num_attempts)
def _poll_lock(self, op):
def _poll_lock(self, op: int) -> bool:
"""Attempt to acquire the lock in a non-blocking manner. Return whether
the locking attempt succeeds
"""
assert self._file is not None, "cannot poll a lock without the file being set"
module_op = LockType.to_module(op)
try:
# Try to get the lock (will raise if not available.)
fcntl.lockf(
self._file, module_op | fcntl.LOCK_NB, self._length, self._start, os.SEEK_SET
self._file.fileno(),
module_op | fcntl.LOCK_NB,
self._length,
self._start,
os.SEEK_SET,
)
# help for debugging distributed locking
@@ -377,7 +399,7 @@ def _poll_lock(self, op):
return False
def _ensure_parent_directory(self):
def _ensure_parent_directory(self) -> str:
parent = os.path.dirname(self.path)
# relative paths to lockfiles in the current directory have no parent
@@ -396,20 +418,22 @@ def _ensure_parent_directory(self):
raise
return parent
def _read_log_debug_data(self):
def _read_log_debug_data(self) -> None:
"""Read PID and host data out of the file if it is there."""
assert self._file is not None, "cannot read debug log without the file being set"
self.old_pid = self.pid
self.old_host = self.host
line = self._file.read()
if line:
pid, host = line.strip().split(",")
_, _, self.pid = pid.rpartition("=")
_, _, pid = pid.rpartition("=")
_, _, self.host = host.rpartition("=")
self.pid = int(self.pid)
self.pid = int(pid)
def _write_log_debug_data(self):
def _write_log_debug_data(self) -> None:
"""Write PID and host data to the file, recording old values."""
assert self._file is not None, "cannot write debug log without the file being set"
self.old_pid = self.pid
self.old_host = self.host
@@ -423,20 +447,21 @@ def _write_log_debug_data(self):
self._file.flush()
os.fsync(self._file.fileno())
def _unlock(self):
def _unlock(self) -> None:
"""Releases a lock using POSIX locks (``fcntl.lockf``)
Releases the lock regardless of mode. Note that read locks may
be masquerading as write locks, but this removes either.
"""
fcntl.lockf(self._file, fcntl.LOCK_UN, self._length, self._start, os.SEEK_SET)
file_tracker.release_by_fh(self._file)
assert self._file is not None, "cannot unlock without the file being set"
fcntl.lockf(self._file.fileno(), fcntl.LOCK_UN, self._length, self._start, os.SEEK_SET)
FILE_TRACKER.release_by_fh(self._file)
self._file = None
self._reads = 0
self._writes = 0
def acquire_read(self, timeout=None):
def acquire_read(self, timeout: Optional[float] = None) -> bool:
"""Acquires a recursive, shared lock for reading.
Read and write locks can be acquired and released in arbitrary
@@ -461,7 +486,7 @@ def acquire_read(self, timeout=None):
self._reads += 1
return False
def acquire_write(self, timeout=None):
def acquire_write(self, timeout: Optional[float] = None) -> bool:
"""Acquires a recursive, exclusive lock for writing.
Read and write locks can be acquired and released in arbitrary
@@ -491,7 +516,7 @@ def acquire_write(self, timeout=None):
self._writes += 1
return False
def is_write_locked(self):
def is_write_locked(self) -> bool:
"""Check if the file is write locked
Return:
@@ -508,7 +533,7 @@ def is_write_locked(self):
return False
def downgrade_write_to_read(self, timeout=None):
def downgrade_write_to_read(self, timeout: Optional[float] = None) -> None:
"""
Downgrade from an exclusive write lock to a shared read.
@@ -527,7 +552,7 @@ def downgrade_write_to_read(self, timeout=None):
else:
raise LockDowngradeError(self.path)
def upgrade_read_to_write(self, timeout=None):
def upgrade_read_to_write(self, timeout: Optional[float] = None) -> None:
"""
Attempts to upgrade from a shared read lock to an exclusive write.
@@ -546,7 +571,7 @@ def upgrade_read_to_write(self, timeout=None):
else:
raise LockUpgradeError(self.path)
def release_read(self, release_fn=None):
def release_read(self, release_fn: ReleaseFnType = None) -> bool:
"""Releases a read lock.
Arguments:
@@ -582,7 +607,7 @@ def release_read(self, release_fn=None):
self._reads -= 1
return False
def release_write(self, release_fn=None):
def release_write(self, release_fn: ReleaseFnType = None) -> bool:
"""Releases a write lock.
Arguments:
@@ -623,65 +648,65 @@ def release_write(self, release_fn=None):
else:
return False
def cleanup(self):
def cleanup(self) -> None:
if self._reads == 0 and self._writes == 0:
os.unlink(self.path)
else:
raise LockError("Attempting to cleanup active lock.")
def _get_counts_desc(self):
def _get_counts_desc(self) -> str:
return (
"(reads {0}, writes {1})".format(self._reads, self._writes) if tty.is_verbose() else ""
)
def _log_acquired(self, locktype, wait_time, nattempts):
def _log_acquired(self, locktype, wait_time, nattempts) -> None:
attempts_part = _attempts_str(wait_time, nattempts)
now = datetime.now()
desc = "Acquired at %s" % now.strftime("%H:%M:%S.%f")
self._log_debug(self._status_msg(locktype, "{0}{1}".format(desc, attempts_part)))
def _log_acquiring(self, locktype):
def _log_acquiring(self, locktype) -> None:
self._log_debug(self._status_msg(locktype, "Acquiring"), level=3)
def _log_debug(self, *args, **kwargs):
def _log_debug(self, *args, **kwargs) -> None:
"""Output lock debug messages."""
kwargs["level"] = kwargs.get("level", 2)
tty.debug(*args, **kwargs)
def _log_downgraded(self, wait_time, nattempts):
def _log_downgraded(self, wait_time, nattempts) -> None:
attempts_part = _attempts_str(wait_time, nattempts)
now = datetime.now()
desc = "Downgraded at %s" % now.strftime("%H:%M:%S.%f")
self._log_debug(self._status_msg("READ LOCK", "{0}{1}".format(desc, attempts_part)))
def _log_downgrading(self):
def _log_downgrading(self) -> None:
self._log_debug(self._status_msg("WRITE LOCK", "Downgrading"), level=3)
def _log_released(self, locktype):
def _log_released(self, locktype) -> None:
now = datetime.now()
desc = "Released at %s" % now.strftime("%H:%M:%S.%f")
self._log_debug(self._status_msg(locktype, desc))
def _log_releasing(self, locktype):
def _log_releasing(self, locktype) -> None:
self._log_debug(self._status_msg(locktype, "Releasing"), level=3)
def _log_upgraded(self, wait_time, nattempts):
def _log_upgraded(self, wait_time, nattempts) -> None:
attempts_part = _attempts_str(wait_time, nattempts)
now = datetime.now()
desc = "Upgraded at %s" % now.strftime("%H:%M:%S.%f")
self._log_debug(self._status_msg("WRITE LOCK", "{0}{1}".format(desc, attempts_part)))
def _log_upgrading(self):
def _log_upgrading(self) -> None:
self._log_debug(self._status_msg("READ LOCK", "Upgrading"), level=3)
def _status_msg(self, locktype, status):
def _status_msg(self, locktype: str, status: str) -> str:
status_desc = "[{0}] {1}".format(status, self._get_counts_desc())
return "{0}{1.desc}: {1.path}[{1._start}:{1._length}] {2}".format(
locktype, self, status_desc
)
class LockTransaction(object):
class LockTransaction:
"""Simple nested transaction context manager that uses a file lock.
Arguments:
@@ -709,7 +734,13 @@ class LockTransaction(object):
"""
def __init__(self, lock, acquire=None, release=None, timeout=None):
def __init__(
self,
lock: Lock,
acquire: Union[ReleaseFnType, ContextManager] = None,
release: Union[ReleaseFnType, ContextManager] = None,
timeout: Optional[float] = None,
) -> None:
self._lock = lock
self._timeout = timeout
self._acquire_fn = acquire
@@ -724,15 +755,20 @@ def __enter__(self):
else:
return self._as
def __exit__(self, type, value, traceback):
def __exit__(
self,
exc_type: Optional[Type[BaseException]],
exc_value: Optional[BaseException],
traceback: Optional[TracebackType],
) -> bool:
suppress = False
def release_fn():
if self._release_fn is not None:
return self._release_fn(type, value, traceback)
return self._release_fn(exc_type, exc_value, traceback)
if self._as and hasattr(self._as, "__exit__"):
if self._as.__exit__(type, value, traceback):
if self._as.__exit__(exc_type, exc_value, traceback):
suppress = True
if self._exit(release_fn):
@@ -740,6 +776,12 @@ def release_fn():
return suppress
def _enter(self) -> bool:
return NotImplemented
def _exit(self, release_fn: ReleaseFnType) -> bool:
return NotImplemented
class ReadTransaction(LockTransaction):
"""LockTransaction context manager that does a read and releases it."""
@@ -770,7 +812,7 @@ class LockDowngradeError(LockError):
def __init__(self, path):
msg = "Cannot downgrade lock from write to read on file: %s" % path
super(LockDowngradeError, self).__init__(msg)
super().__init__(msg)
class LockLimitError(LockError):
@@ -782,10 +824,10 @@ class LockTimeoutError(LockError):
def __init__(self, lock_type, path, time, attempts):
fmt = "Timed out waiting for a {} lock after {}.\n Made {} {} on file: {}"
super(LockTimeoutError, self).__init__(
super().__init__(
fmt.format(
lock_type,
pretty_seconds(time),
lang.pretty_seconds(time),
attempts,
"attempt" if attempts == 1 else "attempts",
path,
@@ -798,7 +840,7 @@ class LockUpgradeError(LockError):
def __init__(self, path):
msg = "Cannot upgrade lock from read to write on file: %s" % path
super(LockUpgradeError, self).__init__(msg)
super().__init__(msg)
class LockPermissionError(LockError):
@@ -810,7 +852,7 @@ class LockROFileError(LockPermissionError):
def __init__(self, path):
msg = "Can't take write lock on read-only file: %s" % path
super(LockROFileError, self).__init__(msg)
super().__init__(msg)
class CantCreateLockError(LockPermissionError):
@@ -819,4 +861,4 @@ class CantCreateLockError(LockPermissionError):
def __init__(self, path):
msg = "cannot create lock '%s': " % path
msg += "file does not exist and location is not writable"
super(LockError, self).__init__(msg)
super().__init__(msg)

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import unicode_literals
import contextlib
import io
import os
@@ -14,6 +12,7 @@
import traceback
from datetime import datetime
from sys import platform as _platform
from typing import NoReturn
if _platform != "win32":
import fcntl
@@ -246,7 +245,7 @@ def warn(message, *args, **kwargs):
info("Warning: " + str(message), *args, **kwargs)
def die(message, *args, **kwargs):
def die(message, *args, **kwargs) -> NoReturn:
kwargs.setdefault("countback", 4)
error(message, *args, **kwargs)
sys.exit(1)

View File

@@ -6,8 +6,6 @@
"""
Routines for printing columnar output. See ``colify()`` for more information.
"""
from __future__ import division, unicode_literals
import io
import os
import sys

View File

@@ -59,8 +59,6 @@
To output an @, use '@@'. To output a } inside braces, use '}}'.
"""
from __future__ import unicode_literals
import re
import sys
from contextlib import contextmanager
@@ -70,7 +68,7 @@ class ColorParseError(Exception):
"""Raised when a color format fails to parse."""
def __init__(self, message):
super(ColorParseError, self).__init__(message)
super().__init__(message)
# Text styles for ansi codes
@@ -205,7 +203,7 @@ def color_when(value):
set_color_when(old_value)
class match_to_ansi(object):
class match_to_ansi:
def __init__(self, color=True, enclose=False):
self.color = _color_when_value(color)
self.enclose = enclose
@@ -321,7 +319,7 @@ def cescape(string):
return string
class ColorStream(object):
class ColorStream:
def __init__(self, stream, color=None):
self._stream = stream
self._color = color

View File

@@ -5,8 +5,6 @@
"""Utility classes for logging the output of blocks of code.
"""
from __future__ import unicode_literals
import atexit
import ctypes
import errno
@@ -67,7 +65,7 @@ def _strip(line):
return _escape.sub("", line)
class keyboard_input(object):
class keyboard_input:
"""Context manager to disable line editing and echoing.
Use this with ``sys.stdin`` for keyboard input, e.g.::
@@ -244,7 +242,7 @@ def __exit__(self, exc_type, exception, traceback):
signal.signal(signum, old_handler)
class Unbuffered(object):
class Unbuffered:
"""Wrapper for Python streams that forces them to be unbuffered.
This is implemented by forcing a flush after each write.
@@ -289,7 +287,7 @@ def _file_descriptors_work(*streams):
return False
class FileWrapper(object):
class FileWrapper:
"""Represents a file. Can be an open stream, a path to a file (not opened
yet), or neither. When unwrapped, it returns an open file (or file-like)
object.
@@ -331,7 +329,7 @@ def close(self):
self.file.close()
class MultiProcessFd(object):
class MultiProcessFd:
"""Return an object which stores a file descriptor and can be passed as an
argument to a function run with ``multiprocessing.Process``, such that
the file descriptor is available in the subprocess."""
@@ -431,7 +429,7 @@ def log_output(*args, **kwargs):
return nixlog(*args, **kwargs)
class nixlog(object):
class nixlog:
"""
Under the hood, we spawn a daemon and set up a pipe between this
process and the daemon. The daemon writes our output to both the
@@ -752,7 +750,7 @@ def close(self):
os.close(self.saved_stream)
class winlog(object):
class winlog:
"""
Similar to nixlog, with underlying
functionality ported to support Windows.

View File

@@ -13,8 +13,6 @@
Note: The functionality in this module is unsupported on Windows
"""
from __future__ import print_function
import multiprocessing
import os
import re
@@ -36,7 +34,7 @@
pass
class ProcessController(object):
class ProcessController:
"""Wrapper around some fundamental process control operations.
This allows one process (the controller) to drive another (the
@@ -157,7 +155,7 @@ def wait_running(self):
self.wait(lambda: "T" not in self.proc_status())
class PseudoShell(object):
class PseudoShell:
"""Sets up controller and minion processes with a PTY.
You can create a ``PseudoShell`` if you want to test how some

View File

@@ -13,7 +13,7 @@
from spack.util.executable import Executable, ProcessError
class ABI(object):
class ABI:
"""This class provides methods to test ABI compatibility between specs.
The current implementation is rather rough and could be improved."""

View File

@@ -60,7 +60,7 @@ def _search_duplicate_compilers(error_cls):
GROUPS = collections.defaultdict(list)
class Error(object):
class Error:
"""Information on an error reported in a test."""
def __init__(self, summary, details):
@@ -725,11 +725,22 @@ def _version_constraints_are_satisfiable_by_some_version_in_repo(pkgs, error_cls
dependencies_to_check.extend([edge.spec for edge in dependency_data.values()])
host_architecture = spack.spec.ArchSpec.default_arch()
for s in dependencies_to_check:
dependency_pkg_cls = None
try:
dependency_pkg_cls = spack.repo.path.get_pkg_class(s.name)
assert any(v.intersects(s.versions) for v in list(dependency_pkg_cls.versions))
# Some packages have hacks that might cause failures on some platform
# Allow to explicitly set conditions to skip version checks in that case
skip_conditions = getattr(dependency_pkg_cls, "skip_version_audit", [])
skip_version_check = False
for condition in skip_conditions:
if host_architecture.satisfies(spack.spec.Spec(condition).architecture):
skip_version_check = True
break
assert skip_version_check or any(
v.intersects(s.versions) for v in list(dependency_pkg_cls.versions)
)
except Exception:
summary = (
"{0}: dependency on {1} cannot be satisfied " "by known versions of {1.name}"

View File

@@ -52,6 +52,7 @@
import spack.util.url as url_util
import spack.util.web as web_util
from spack.caches import misc_cache_location
from spack.package_prefs import get_package_dir_permissions, get_package_group
from spack.relocate_text import utf8_paths_to_single_binary_regex
from spack.spec import Spec
from spack.stage import Stage
@@ -61,6 +62,22 @@
_build_cache_keys_relative_path = "_pgp"
class BuildCacheDatabase(spack_db.Database):
"""A database for binary buildcaches.
A database supports writing buildcache index files, in which case certain fields are not
needed in each install record, and no locking is required. To use this feature, it provides
``lock_cfg=NO_LOCK``, and override the list of ``record_fields``.
"""
record_fields = ("spec", "ref_count", "in_buildcache")
def __init__(self, root):
super().__init__(root, lock_cfg=spack_db.NO_LOCK)
self._write_transaction_impl = llnl.util.lang.nullcontext
self._read_transaction_impl = llnl.util.lang.nullcontext
class FetchCacheError(Exception):
"""Error thrown when fetching the cache failed, usually a composite error list."""
@@ -80,14 +97,14 @@ def __init__(self, errors):
else:
err = errors[0]
self.message = "{0}: {1}".format(err.__class__.__name__, str(err))
super(FetchCacheError, self).__init__(self.message)
super().__init__(self.message)
class ListMirrorSpecsError(spack.error.SpackError):
"""Raised when unable to retrieve list of specs from the mirror"""
class BinaryCacheIndex(object):
class BinaryCacheIndex:
"""
The BinaryCacheIndex tracks what specs are available on (usually remote)
binary caches.
@@ -190,8 +207,7 @@ def _associate_built_specs_with_mirror(self, cache_key, mirror_url):
tmpdir = tempfile.mkdtemp()
try:
db_root_dir = os.path.join(tmpdir, "db_root")
db = spack_db.Database(None, db_dir=db_root_dir, enable_transaction_locking=False)
db = BuildCacheDatabase(tmpdir)
try:
self._index_file_cache.init_entry(cache_key)
@@ -317,9 +333,9 @@ def update(self, with_cooldown=False):
from each configured mirror and stored locally (both in memory and
on disk under ``_index_cache_root``)."""
self._init_local_index_cache()
mirrors = spack.mirror.MirrorCollection()
configured_mirror_urls = [m.fetch_url for m in mirrors.values()]
configured_mirror_urls = [
m.fetch_url for m in spack.mirror.MirrorCollection(binary=True).values()
]
items_to_remove = []
spec_cache_clear_needed = False
spec_cache_regenerate_needed = not self._mirrors_for_spec
@@ -517,9 +533,7 @@ class NoOverwriteException(spack.error.SpackError):
"""Raised when a file would be overwritten"""
def __init__(self, file_path):
super(NoOverwriteException, self).__init__(
f"Refusing to overwrite the following file: {file_path}"
)
super().__init__(f"Refusing to overwrite the following file: {file_path}")
class NoGpgException(spack.error.SpackError):
@@ -528,7 +542,7 @@ class NoGpgException(spack.error.SpackError):
"""
def __init__(self, msg):
super(NoGpgException, self).__init__(msg)
super().__init__(msg)
class NoKeyException(spack.error.SpackError):
@@ -537,7 +551,7 @@ class NoKeyException(spack.error.SpackError):
"""
def __init__(self, msg):
super(NoKeyException, self).__init__(msg)
super().__init__(msg)
class PickKeyException(spack.error.SpackError):
@@ -548,7 +562,7 @@ class PickKeyException(spack.error.SpackError):
def __init__(self, keys):
err_msg = "Multiple keys available for signing\n%s\n" % keys
err_msg += "Use spack buildcache create -k <key hash> to pick a key."
super(PickKeyException, self).__init__(err_msg)
super().__init__(err_msg)
class NoVerifyException(spack.error.SpackError):
@@ -565,7 +579,7 @@ class NoChecksumException(spack.error.SpackError):
"""
def __init__(self, path, size, contents, algorithm, expected, computed):
super(NoChecksumException, self).__init__(
super().__init__(
f"{algorithm} checksum failed for {path}",
f"Expected {expected} but got {computed}. "
f"File size = {size} bytes. Contents = {contents!r}",
@@ -578,7 +592,7 @@ class NewLayoutException(spack.error.SpackError):
"""
def __init__(self, msg):
super(NewLayoutException, self).__init__(msg)
super().__init__(msg)
class UnsignedPackageException(spack.error.SpackError):
@@ -705,7 +719,7 @@ def get_buildfile_manifest(spec):
# look for them to decide if text file needs to be relocated or not
prefixes = [d.prefix for d in spec.traverse(root=True, deptype="all") if not d.external]
prefixes.append(spack.hooks.sbang.sbang_install_path())
prefixes.append(str(spack.store.layout.root))
prefixes.append(str(spack.store.STORE.layout.root))
# Create a giant regex that matches all prefixes
regex = utf8_paths_to_single_binary_regex(prefixes)
@@ -718,7 +732,7 @@ def get_buildfile_manifest(spec):
for rel_path in visitor.symlinks:
abs_path = os.path.join(root, rel_path)
link = os.readlink(abs_path)
if os.path.isabs(link) and link.startswith(spack.store.layout.root):
if os.path.isabs(link) and link.startswith(spack.store.STORE.layout.root):
data["link_to_relocate"].append(rel_path)
# Non-symlinks.
@@ -760,16 +774,15 @@ def hashes_to_prefixes(spec):
}
def get_buildinfo_dict(spec, rel=False):
def get_buildinfo_dict(spec):
"""Create metadata for a tarball"""
manifest = get_buildfile_manifest(spec)
return {
"sbang_install_path": spack.hooks.sbang.sbang_install_path(),
"relative_rpaths": rel,
"buildpath": spack.store.layout.root,
"buildpath": spack.store.STORE.layout.root,
"spackprefix": spack.paths.prefix,
"relative_prefix": os.path.relpath(spec.prefix, spack.store.layout.root),
"relative_prefix": os.path.relpath(spec.prefix, spack.store.STORE.layout.root),
"relocate_textfiles": manifest["text_to_relocate"],
"relocate_binaries": manifest["binary_to_relocate"],
"relocate_links": manifest["link_to_relocate"],
@@ -1062,13 +1075,10 @@ def generate_package_index(cache_prefix, concurrency=32):
tty.debug("Retrieving spec descriptor files from {0} to build index".format(cache_prefix))
tmpdir = tempfile.mkdtemp()
db_root_dir = os.path.join(tmpdir, "db_root")
db = spack_db.Database(
None,
db_dir=db_root_dir,
enable_transaction_locking=False,
record_fields=["spec", "ref_count", "in_buildcache"],
)
db = BuildCacheDatabase(tmpdir)
db.root = None
db_root_dir = db.database_directory
try:
_read_specs_and_push_index(file_list, read_fn, cache_prefix, db, db_root_dir, concurrency)
@@ -1199,9 +1209,17 @@ def tar_add_metadata(tar: tarfile.TarFile, path: str, data: dict):
tar.addfile(deterministic_tarinfo(tarinfo), io.BytesIO(bstring))
def _do_create_tarball(tarfile_path, binaries_dir, pkg_dir, buildinfo):
def deterministic_tarinfo_without_buildinfo(tarinfo: tarfile.TarInfo):
"""Skip buildinfo file when creating a tarball, and normalize other tarinfo fields."""
if tarinfo.name.endswith("/.spack/binary_distribution"):
return None
return deterministic_tarinfo(tarinfo)
def _do_create_tarball(tarfile_path: str, binaries_dir: str, pkg_dir: str, buildinfo: dict):
with gzip_compressed_tarfile(tarfile_path) as tar:
tar.add(name=binaries_dir, arcname=pkg_dir, filter=deterministic_tarinfo)
tar.add(name=binaries_dir, arcname=pkg_dir, filter=deterministic_tarinfo_without_buildinfo)
tar_add_metadata(tar, buildinfo_file_name(pkg_dir), buildinfo)
@@ -1209,12 +1227,6 @@ class PushOptions(NamedTuple):
#: Overwrite existing tarball/metadata files in buildcache
force: bool = False
#: Whether to use relative RPATHs
relative: bool = False
#: Allow absolute paths to package prefixes when creating a tarball
allow_root: bool = False
#: Regenerated indices after pushing
regenerate_index: bool = False
@@ -1259,7 +1271,7 @@ def _build_tarball_in_stage_dir(spec: Spec, out_url: str, stage_dir: str, option
# without concretizing with the current spack packages
# and preferences
spec_file = spack.store.layout.spec_file_path(spec)
spec_file = spack.store.STORE.layout.spec_file_path(spec)
specfile_name = tarball_name(spec, ".spec.json")
specfile_path = os.path.realpath(os.path.join(cache_prefix, specfile_name))
signed_specfile_path = "{0}.sig".format(specfile_path)
@@ -1281,41 +1293,14 @@ def _build_tarball_in_stage_dir(spec: Spec, out_url: str, stage_dir: str, option
raise NoOverwriteException(url_util.format(remote_specfile_path))
pkg_dir = os.path.basename(spec.prefix.rstrip(os.path.sep))
workdir = os.path.join(stage_dir, pkg_dir)
# TODO: We generally don't want to mutate any files, but when using relative
# mode, Spack unfortunately *does* mutate rpaths and links ahead of time.
# For now, we only make a full copy of the spec prefix when in relative mode.
if options.relative:
# tarfile is used because it preserves hardlink etc best.
binaries_dir = workdir
temp_tarfile_name = tarball_name(spec, ".tar")
temp_tarfile_path = os.path.join(tarfile_dir, temp_tarfile_name)
with closing(tarfile.open(temp_tarfile_path, "w")) as tar:
tar.add(name="%s" % spec.prefix, arcname=".")
with closing(tarfile.open(temp_tarfile_path, "r")) as tar:
tar.extractall(workdir)
os.remove(temp_tarfile_path)
else:
binaries_dir = spec.prefix
binaries_dir = spec.prefix
# create info for later relocation and create tar
buildinfo = get_buildinfo_dict(spec, options.relative)
# optionally make the paths in the binaries relative to each other
# in the spack install tree before creating tarball
if options.relative:
make_package_relative(workdir, spec, buildinfo, options.allow_root)
elif not options.allow_root:
ensure_package_relocatable(buildinfo, binaries_dir)
buildinfo = get_buildinfo_dict(spec)
_do_create_tarball(tarfile_path, binaries_dir, pkg_dir, buildinfo)
# remove copy of install directory
if options.relative:
shutil.rmtree(workdir)
# get the sha256 checksum of the tarball
checksum = checksum_tarball(tarfile_path)
@@ -1328,16 +1313,7 @@ def _build_tarball_in_stage_dir(spec: Spec, out_url: str, stage_dir: str, option
else:
raise ValueError("{0} not a valid spec file type".format(spec_file))
spec_dict["buildcache_layout_version"] = 1
bchecksum = {}
bchecksum["hash_algorithm"] = "sha256"
bchecksum["hash"] = checksum
spec_dict["binary_cache_checksum"] = bchecksum
# Add original install prefix relative to layout root to spec.json.
# This will be used to determine is the directory layout has changed.
buildinfo = {}
buildinfo["relative_prefix"] = os.path.relpath(spec.prefix, spack.store.layout.root)
buildinfo["relative_rpaths"] = options.relative
spec_dict["buildinfo"] = buildinfo
spec_dict["binary_cache_checksum"] = {"hash_algorithm": "sha256", "hash": checksum}
with open(specfile_path, "w") as outfile:
# Note: when using gpg clear sign, we need to avoid long lines (19995 chars).
@@ -1394,7 +1370,7 @@ def specs_to_be_packaged(
packageable = lambda n: not n.external and n.installed
# Mass install check
with spack.store.db.read_transaction():
with spack.store.STORE.db.read_transaction():
return list(filter(packageable, nodes))
@@ -1496,8 +1472,9 @@ def download_tarball(spec, unsigned=False, mirrors_for_spec=None):
"signature_verified": "true-if-binary-pkg-was-already-verified"
}
"""
if not spack.mirror.MirrorCollection():
tty.die("Please add a spack mirror to allow " + "download of pre-compiled packages.")
configured_mirrors = spack.mirror.MirrorCollection(binary=True).values()
if not configured_mirrors:
tty.die("Please add a spack mirror to allow download of pre-compiled packages.")
tarball = tarball_path_name(spec, ".spack")
specfile_prefix = tarball_name(spec, ".spec")
@@ -1514,11 +1491,7 @@ def download_tarball(spec, unsigned=False, mirrors_for_spec=None):
# we need was in an un-indexed mirror. No need to check any
# mirror for the spec twice though.
try_first = [i["mirror_url"] for i in mirrors_for_spec] if mirrors_for_spec else []
try_next = [
i.fetch_url
for i in spack.mirror.MirrorCollection().values()
if i.fetch_url not in try_first
]
try_next = [i.fetch_url for i in configured_mirrors if i.fetch_url not in try_first]
for url in try_first + try_next:
mirrors_to_try.append(
@@ -1596,41 +1569,6 @@ def download_tarball(spec, unsigned=False, mirrors_for_spec=None):
return None
def make_package_relative(workdir, spec, buildinfo, allow_root):
"""
Change paths in binaries to relative paths. Change absolute symlinks
to relative symlinks.
"""
prefix = spec.prefix
old_layout_root = buildinfo["buildpath"]
orig_path_names = list()
cur_path_names = list()
for filename in buildinfo["relocate_binaries"]:
orig_path_names.append(os.path.join(prefix, filename))
cur_path_names.append(os.path.join(workdir, filename))
platform = spack.platforms.by_name(spec.platform)
if "macho" in platform.binary_formats:
relocate.make_macho_binaries_relative(cur_path_names, orig_path_names, old_layout_root)
if "elf" in platform.binary_formats:
relocate.make_elf_binaries_relative(cur_path_names, orig_path_names, old_layout_root)
allow_root or relocate.ensure_binaries_are_relocatable(cur_path_names)
orig_path_names = list()
cur_path_names = list()
for linkname in buildinfo.get("relocate_links", []):
orig_path_names.append(os.path.join(prefix, linkname))
cur_path_names.append(os.path.join(workdir, linkname))
relocate.make_link_relative(cur_path_names, orig_path_names)
def ensure_package_relocatable(buildinfo, binaries_dir):
"""Check if package binaries are relocatable."""
binaries = [os.path.join(binaries_dir, f) for f in buildinfo["relocate_binaries"]]
relocate.ensure_binaries_are_relocatable(binaries)
def dedupe_hardlinks_if_necessary(root, buildinfo):
"""Updates a buildinfo dict for old archives that did
not dedupe hardlinks. De-duping hardlinks is necessary
@@ -1669,7 +1607,7 @@ def relocate_package(spec):
"""
workdir = str(spec.prefix)
buildinfo = read_buildinfo_file(workdir)
new_layout_root = str(spack.store.layout.root)
new_layout_root = str(spack.store.STORE.layout.root)
new_prefix = str(spec.prefix)
new_rel_prefix = str(os.path.relpath(new_prefix, new_layout_root))
new_spack_prefix = str(spack.paths.prefix)
@@ -1854,6 +1792,27 @@ def _extract_inner_tarball(spec, filename, extract_to, unsigned, remote_checksum
return tarfile_path
def _tar_strip_component(tar: tarfile.TarFile, prefix: str):
"""Strip the top-level directory `prefix` from the member names in a tarfile."""
# Including trailing /, otherwise we end up with absolute paths.
regex = re.compile(re.escape(prefix) + "/*")
# Remove the top-level directory from the member (link)names.
# Note: when a tarfile is created, relative in-prefix symlinks are
# expanded to matching member names of tarfile entries. So, we have
# to ensure that those are updated too.
# Absolute symlinks are copied verbatim -- relocation should take care of
# them.
for m in tar.getmembers():
result = regex.match(m.name)
assert result is not None
m.name = m.name[result.end() :]
if m.linkname:
result = regex.match(m.linkname)
if result:
m.linkname = m.linkname[result.end() :]
def extract_tarball(spec, download_result, unsigned=False, force=False):
"""
extract binary tarball for given package into install area
@@ -1864,6 +1823,14 @@ def extract_tarball(spec, download_result, unsigned=False, force=False):
else:
raise NoOverwriteException(str(spec.prefix))
# Create the install prefix
fsys.mkdirp(
spec.prefix,
mode=get_package_dir_permissions(spec),
group=get_package_group(spec),
default_perms="parents",
)
specfile_path = download_result["specfile_stage"].save_filename
with open(specfile_path, "r") as inputfile:
@@ -1917,58 +1884,58 @@ def extract_tarball(spec, download_result, unsigned=False, force=False):
tarfile_path, size, contents, "sha256", expected, local_checksum
)
new_relative_prefix = str(os.path.relpath(spec.prefix, spack.store.layout.root))
# if the original relative prefix is in the spec file use it
buildinfo = spec_dict.get("buildinfo", {})
old_relative_prefix = buildinfo.get("relative_prefix", new_relative_prefix)
rel = buildinfo.get("relative_rpaths")
info = "old relative prefix %s\nnew relative prefix %s\nrelative rpaths %s"
tty.debug(info % (old_relative_prefix, new_relative_prefix, rel), level=2)
# Extract the tarball into the store root, presumably on the same filesystem.
# The directory created is the base directory name of the old prefix.
# Moving the old prefix name to the new prefix location should preserve
# hard links and symbolic links.
extract_tmp = os.path.join(spack.store.layout.root, ".tmp")
mkdirp(extract_tmp)
extracted_dir = os.path.join(extract_tmp, old_relative_prefix.split(os.path.sep)[-1])
with closing(tarfile.open(tarfile_path, "r")) as tar:
try:
tar.extractall(path=extract_tmp)
except Exception as e:
_delete_staged_downloads(download_result)
shutil.rmtree(extracted_dir)
raise e
try:
shutil.move(extracted_dir, spec.prefix)
except Exception as e:
with closing(tarfile.open(tarfile_path, "r")) as tar:
# Remove install prefix from tarfil to extract directly into spec.prefix
_tar_strip_component(tar, prefix=_ensure_common_prefix(tar))
tar.extractall(path=spec.prefix)
except Exception:
shutil.rmtree(spec.prefix, ignore_errors=True)
_delete_staged_downloads(download_result)
shutil.rmtree(extracted_dir)
raise e
raise
os.remove(tarfile_path)
os.remove(specfile_path)
try:
relocate_package(spec)
except Exception as e:
shutil.rmtree(spec.prefix)
shutil.rmtree(spec.prefix, ignore_errors=True)
raise e
else:
manifest_file = os.path.join(
spec.prefix, spack.store.layout.metadata_dir, spack.store.layout.manifest_file_name
spec.prefix,
spack.store.STORE.layout.metadata_dir,
spack.store.STORE.layout.manifest_file_name,
)
if not os.path.exists(manifest_file):
spec_id = spec.format("{name}/{hash:7}")
tty.warn("No manifest file in tarball for spec %s" % spec_id)
finally:
if tmpdir:
shutil.rmtree(tmpdir)
shutil.rmtree(tmpdir, ignore_errors=True)
if os.path.exists(filename):
os.remove(filename)
_delete_staged_downloads(download_result)
def _ensure_common_prefix(tar: tarfile.TarFile) -> str:
# Get the shortest length directory.
common_prefix = min((e.name for e in tar.getmembers() if e.isdir()), key=len, default=None)
if common_prefix is None:
raise ValueError("Tarball does not contain a common prefix")
# Validate that each file starts with the prefix
for member in tar.getmembers():
if not member.name.startswith(common_prefix):
raise ValueError(
f"Tarball contains file {member.name} outside of prefix {common_prefix}"
)
return common_prefix
def install_root_node(spec, unsigned=False, force=False, sha256=None):
"""Install the root node of a concrete spec from a buildcache.
@@ -2015,7 +1982,7 @@ def install_root_node(spec, unsigned=False, force=False, sha256=None):
tty.msg('Installing "{0}" from a buildcache'.format(spec.format()))
extract_tarball(spec, download_result, unsigned, force)
spack.hooks.post_install(spec, False)
spack.store.db.add(spec, spack.store.layout)
spack.store.STORE.db.add(spec, spack.store.STORE.layout)
def install_single_spec(spec, unsigned=False, force=False):
@@ -2040,7 +2007,9 @@ def try_direct_fetch(spec, mirrors=None):
specfile_is_signed = False
found_specs = []
for mirror in spack.mirror.MirrorCollection(mirrors=mirrors).values():
binary_mirrors = spack.mirror.MirrorCollection(mirrors=mirrors, binary=True).values()
for mirror in binary_mirrors:
buildcache_fetch_url_json = url_util.join(
mirror.fetch_url, _build_cache_relative_path, specfile_name
)
@@ -2103,7 +2072,7 @@ def get_mirrors_for_spec(spec=None, mirrors_to_check=None, index_only=False):
if spec is None:
return []
if not spack.mirror.MirrorCollection(mirrors=mirrors_to_check):
if not spack.mirror.MirrorCollection(mirrors=mirrors_to_check, binary=True):
tty.debug("No Spack mirrors are currently configured")
return {}
@@ -2142,7 +2111,7 @@ def clear_spec_cache():
def get_keys(install=False, trust=False, force=False, mirrors=None):
"""Get pgp public keys available on mirror with suffix .pub"""
mirror_collection = mirrors or spack.mirror.MirrorCollection()
mirror_collection = mirrors or spack.mirror.MirrorCollection(binary=True)
if not mirror_collection:
tty.die("Please add a spack mirror to allow " + "download of build caches.")
@@ -2303,7 +2272,7 @@ def check_specs_against_mirrors(mirrors, specs, output_file=None):
"""
rebuilds = {}
for mirror in spack.mirror.MirrorCollection(mirrors).values():
for mirror in spack.mirror.MirrorCollection(mirrors, binary=True).values():
tty.debug("Checking for built specs at {0}".format(mirror.fetch_url))
rebuild_list = []
@@ -2347,7 +2316,7 @@ def _download_buildcache_entry(mirror_root, descriptions):
def download_buildcache_entry(file_descriptions, mirror_url=None):
if not mirror_url and not spack.mirror.MirrorCollection():
if not mirror_url and not spack.mirror.MirrorCollection(binary=True):
tty.die(
"Please provide or add a spack mirror to allow " + "download of buildcache entries."
)
@@ -2356,7 +2325,7 @@ def download_buildcache_entry(file_descriptions, mirror_url=None):
mirror_root = os.path.join(mirror_url, _build_cache_relative_path)
return _download_buildcache_entry(mirror_root, file_descriptions)
for mirror in spack.mirror.MirrorCollection().values():
for mirror in spack.mirror.MirrorCollection(binary=True).values():
mirror_root = os.path.join(mirror.fetch_url, _build_cache_relative_path)
if _download_buildcache_entry(mirror_root, file_descriptions):
@@ -2395,7 +2364,7 @@ def download_single_spec(concrete_spec, destination, mirror_url=None):
return download_buildcache_entry(files_to_fetch, mirror_url)
class BinaryCacheQuery(object):
class BinaryCacheQuery:
"""Callable object to query if a spec is in a binary cache"""
def __init__(self, all_architectures):

View File

@@ -4,7 +4,7 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
"""Function and classes needed to bootstrap Spack itself."""
from .config import ensure_bootstrap_configuration, is_bootstrapping
from .config import ensure_bootstrap_configuration, is_bootstrapping, store_path
from .core import all_core_root_specs, ensure_core_dependencies, ensure_patchelf_in_path_or_raise
from .environment import BootstrapEnvironment, ensure_environment_dependencies
from .status import status_message
@@ -18,4 +18,5 @@
"ensure_environment_dependencies",
"BootstrapEnvironment",
"status_message",
"store_path",
]

View File

@@ -50,7 +50,7 @@ def _try_import_from_store(
# We have to run as part of this python interpreter
query_spec += " ^" + spec_for_current_python()
installed_specs = spack.store.db.query(query_spec, installed=True)
installed_specs = spack.store.STORE.db.query(query_spec, installed=True)
for candidate_spec in installed_specs:
pkg = candidate_spec["python"].package
@@ -183,7 +183,7 @@ def _executables_in_store(
executables_str = ", ".join(executables)
msg = "[BOOTSTRAP EXECUTABLES {0}] Try installed specs with query '{1}'"
tty.debug(msg.format(executables_str, query_spec))
installed_specs = spack.store.db.query(query_spec, installed=True)
installed_specs = spack.store.STORE.db.query(query_spec, installed=True)
if installed_specs:
for concrete_spec in installed_specs:
bin_dir = concrete_spec.prefix.bin

View File

@@ -150,18 +150,19 @@ def _add_compilers_if_missing() -> None:
@contextlib.contextmanager
def _ensure_bootstrap_configuration() -> Generator:
spack.store.ensure_singleton_created()
bootstrap_store_path = store_path()
user_configuration = _read_and_sanitize_configuration()
with spack.environment.no_active_environment():
with spack.platforms.prevent_cray_detection(), spack.platforms.use_platform(
spack.platforms.real_host()
), spack.repo.use_repositories(spack.paths.packages_path), spack.store.use_store(
bootstrap_store_path
):
), spack.repo.use_repositories(spack.paths.packages_path):
# Default configuration scopes excluding command line
# and builtin but accounting for platform specific scopes
config_scopes = _bootstrap_config_scopes()
with spack.config.use_configuration(*config_scopes):
with spack.config.use_configuration(*config_scopes), spack.store.use_store(
bootstrap_store_path, extra_data={"padded_length": 0}
):
# We may need to compile code from sources, so ensure we
# have compilers for the current platform
_add_compilers_if_missing()

View File

@@ -175,12 +175,12 @@ def black_root_spec() -> str:
def flake8_root_spec() -> str:
"""Return the root spec used to bootstrap flake8"""
return _root_spec("py-flake8")
return _root_spec("py-flake8@3.8.2:")
def pytest_root_spec() -> str:
"""Return the root spec used to bootstrap flake8"""
return _root_spec("py-pytest")
return _root_spec("py-pytest@6.2.4:")
def ensure_environment_dependencies() -> None:

View File

@@ -148,7 +148,7 @@ class MakeExecutable(Executable):
def __init__(self, name, jobs, **kwargs):
supports_jobserver = kwargs.pop("supports_jobserver", True)
super(MakeExecutable, self).__init__(name, **kwargs)
super().__init__(name, **kwargs)
self.supports_jobserver = supports_jobserver
self.jobs = jobs
@@ -175,7 +175,7 @@ def __call__(self, *args, **kwargs):
if jobs_env_jobs is not None:
kwargs["extra_env"] = {jobs_env: str(jobs_env_jobs)}
return super(MakeExecutable, self).__call__(*args, **kwargs)
return super().__call__(*args, **kwargs)
def _on_cray():
@@ -1332,7 +1332,7 @@ class ChildError(InstallError):
build_errors = [("spack.util.executable", "ProcessError")]
def __init__(self, msg, module, classname, traceback_string, log_name, log_type, context):
super(ChildError, self).__init__(msg)
super().__init__(msg)
self.module = module
self.name = classname
self.traceback = traceback_string
@@ -1373,7 +1373,7 @@ def long_message(self):
test_log = join_path(os.path.dirname(self.log_name), spack_install_test_log)
if os.path.isfile(test_log):
out.write("\nSee test log for details:\n")
out.write(" {0}n".format(test_log))
out.write(" {0}\n".format(test_log))
return out.getvalue()

View File

@@ -39,7 +39,7 @@ def check_paths(path_list, filetype, predicate):
check_paths(pkg.sanity_check_is_file, "file", os.path.isfile)
check_paths(pkg.sanity_check_is_dir, "directory", os.path.isdir)
ignore_file = llnl.util.lang.match_predicate(spack.store.layout.hidden_file_regexes)
ignore_file = llnl.util.lang.match_predicate(spack.store.STORE.layout.hidden_file_regexes)
if all(map(ignore_file, os.listdir(pkg.prefix))):
msg = "Install failed for {0}. Nothing was installed!"
raise spack.installer.InstallError(msg.format(pkg.name))

View File

@@ -2,6 +2,7 @@
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import collections.abc
import os
from typing import Tuple
@@ -13,21 +14,24 @@
from .cmake import CMakeBuilder, CMakePackage
def cmake_cache_path(name, value, comment=""):
def cmake_cache_path(name, value, comment="", force=False):
"""Generate a string for a cmake cache variable"""
return 'set({0} "{1}" CACHE PATH "{2}")\n'.format(name, value, comment)
force_str = " FORCE" if force else ""
return 'set({0} "{1}" CACHE PATH "{2}"{3})\n'.format(name, value, comment, force_str)
def cmake_cache_string(name, value, comment=""):
def cmake_cache_string(name, value, comment="", force=False):
"""Generate a string for a cmake cache variable"""
return 'set({0} "{1}" CACHE STRING "{2}")\n'.format(name, value, comment)
force_str = " FORCE" if force else ""
return 'set({0} "{1}" CACHE STRING "{2}"{3})\n'.format(name, value, comment, force_str)
def cmake_cache_option(name, boolean_value, comment=""):
def cmake_cache_option(name, boolean_value, comment="", force=False):
"""Generate a string for a cmake configuration option"""
value = "ON" if boolean_value else "OFF"
return 'set({0} {1} CACHE BOOL "{2}")\n'.format(name, value, comment)
force_str = " FORCE" if force else ""
return 'set({0} {1} CACHE BOOL "{2}"{3})\n'.format(name, value, comment, force_str)
class CachedCMakeBuilder(CMakeBuilder):
@@ -63,6 +67,34 @@ def cache_name(self):
def cache_path(self):
return os.path.join(self.pkg.stage.source_path, self.cache_name)
# Implement a version of the define_from_variant for Cached packages
def define_cmake_cache_from_variant(self, cmake_var, variant=None, comment=""):
"""Return a Cached CMake field from the given variant's value.
See define_from_variant in lib/spack/spack/build_systems/cmake.py package
"""
if variant is None:
variant = cmake_var.lower()
if variant not in self.pkg.variants:
raise KeyError('"{0}" is not a variant of "{1}"'.format(variant, self.pkg.name))
if variant not in self.pkg.spec.variants:
return ""
value = self.pkg.spec.variants[variant].value
field = None
if isinstance(value, bool):
field = cmake_cache_option(cmake_var, value, comment)
else:
if isinstance(value, collections.abc.Sequence) and not isinstance(value, str):
value = ";".join(str(v) for v in value)
else:
value = str(value)
field = cmake_cache_string(cmake_var, value, comment)
return field
def initconfig_compiler_entries(self):
# This will tell cmake to use the Spack compiler wrappers when run
# through Spack, but use the underlying compiler when run outside of
@@ -195,26 +227,58 @@ def initconfig_hardware_entries(self):
"#------------------{0}\n".format("-" * 60),
]
# Provide standard CMake arguments for dependent CachedCMakePackages
if spec.satisfies("^cuda"):
entries.append("#------------------{0}".format("-" * 30))
entries.append("# Cuda")
entries.append("#------------------{0}\n".format("-" * 30))
cudatoolkitdir = spec["cuda"].prefix
entries.append(cmake_cache_path("CUDA_TOOLKIT_ROOT_DIR", cudatoolkitdir))
cudacompiler = "${CUDA_TOOLKIT_ROOT_DIR}/bin/nvcc"
entries.append(cmake_cache_path("CMAKE_CUDA_COMPILER", cudacompiler))
entries.append(cmake_cache_path("CUDAToolkit_ROOT", cudatoolkitdir))
entries.append(cmake_cache_path("CMAKE_CUDA_COMPILER", "${CUDAToolkit_ROOT}/bin/nvcc"))
entries.append(cmake_cache_path("CMAKE_CUDA_HOST_COMPILER", "${CMAKE_CXX_COMPILER}"))
# Include the deprecated CUDA_TOOLKIT_ROOT_DIR for supporting BLT packages
entries.append(cmake_cache_path("CUDA_TOOLKIT_ROOT_DIR", cudatoolkitdir))
archs = spec.variants["cuda_arch"].value
if archs[0] != "none":
arch_str = ";".join(archs)
entries.append(
cmake_cache_string("CMAKE_CUDA_ARCHITECTURES", "{0}".format(arch_str))
)
if "+rocm" in spec:
entries.append("#------------------{0}".format("-" * 30))
entries.append("# ROCm")
entries.append("#------------------{0}\n".format("-" * 30))
# Explicitly setting HIP_ROOT_DIR may be a patch that is no longer necessary
entries.append(cmake_cache_path("HIP_ROOT_DIR", "{0}".format(spec["hip"].prefix)))
entries.append(
cmake_cache_path("HIP_CXX_COMPILER", "{0}".format(self.spec["hip"].hipcc))
)
archs = self.spec.variants["amdgpu_target"].value
if archs[0] != "none":
arch_str = ";".join(archs)
entries.append(
cmake_cache_string("CMAKE_HIP_ARCHITECTURES", "{0}".format(arch_str))
)
entries.append(cmake_cache_string("AMDGPU_TARGETS", "{0}".format(arch_str)))
entries.append(cmake_cache_string("GPU_TARGETS", "{0}".format(arch_str)))
return entries
def std_initconfig_entries(self):
cmake_prefix_path_env = os.environ["CMAKE_PREFIX_PATH"]
cmake_prefix_path = cmake_prefix_path_env.replace(os.pathsep, ";")
return [
"#------------------{0}".format("-" * 60),
"# !!!! This is a generated file, edit at own risk !!!!",
"#------------------{0}".format("-" * 60),
"# CMake executable path: {0}".format(self.pkg.spec["cmake"].command.path),
"#------------------{0}\n".format("-" * 60),
cmake_cache_path("CMAKE_PREFIX_PATH", cmake_prefix_path),
self.define_cmake_cache_from_variant("CMAKE_BUILD_TYPE", "build_type"),
]
def initconfig_package_entries(self):
@@ -237,7 +301,7 @@ def initconfig(self, pkg, spec, prefix):
@property
def std_cmake_args(self):
args = super(CachedCMakeBuilder, self).std_cmake_args
args = super().std_cmake_args
args.extend(["-C", self.cache_path])
return args

View File

@@ -5,6 +5,7 @@
import collections.abc
import inspect
import os
import pathlib
import platform
import re
import sys
@@ -15,7 +16,6 @@
import spack.build_environment
import spack.builder
import spack.package_base
import spack.util.path
from spack.directives import build_system, conflicts, depends_on, variant
from spack.multimethod import when
@@ -271,7 +271,7 @@ def std_args(pkg, generator=None):
args = [
"-G",
generator,
define("CMAKE_INSTALL_PREFIX", pkg.prefix),
define("CMAKE_INSTALL_PREFIX", pathlib.Path(pkg.prefix).as_posix()),
define("CMAKE_BUILD_TYPE", build_type),
define("BUILD_TESTING", pkg.run_tests),
]
@@ -296,8 +296,46 @@ def std_args(pkg, generator=None):
define("CMAKE_PREFIX_PATH", spack.build_environment.get_cmake_prefix_path(pkg)),
]
)
return args
@staticmethod
def define_cuda_architectures(pkg):
"""Returns the str ``-DCMAKE_CUDA_ARCHITECTURES:STRING=(expanded cuda_arch)``.
``cuda_arch`` is variant composed of a list of target CUDA architectures and
it is declared in the cuda package.
This method is no-op for cmake<3.18 and when ``cuda_arch`` variant is not set.
"""
cmake_flag = str()
if "cuda_arch" in pkg.spec.variants and pkg.spec.satisfies("^cmake@3.18:"):
cmake_flag = CMakeBuilder.define(
"CMAKE_CUDA_ARCHITECTURES", pkg.spec.variants["cuda_arch"].value
)
return cmake_flag
@staticmethod
def define_hip_architectures(pkg):
"""Returns the str ``-DCMAKE_HIP_ARCHITECTURES:STRING=(expanded amdgpu_target)``.
``amdgpu_target`` is variant composed of a list of the target HIP
architectures and it is declared in the rocm package.
This method is no-op for cmake<3.18 and when ``amdgpu_target`` variant is
not set.
"""
cmake_flag = str()
if "amdgpu_target" in pkg.spec.variants and pkg.spec.satisfies("^cmake@3.21:"):
cmake_flag = CMakeBuilder.define(
"CMAKE_HIP_ARCHITECTURES", pkg.spec.variants["amdgpu_target"].value
)
return cmake_flag
@staticmethod
def define(cmake_var, value):
"""Return a CMake command line argument that defines a variable.

View File

@@ -102,11 +102,10 @@ def cuda_flags(arch_list):
depends_on("cuda@11.0:", when="cuda_arch=80")
depends_on("cuda@11.1:", when="cuda_arch=86")
depends_on("cuda@11.4:", when="cuda_arch=87")
depends_on("cuda@11.8:", when="cuda_arch=89")
depends_on("cuda@11.8:", when="cuda_arch=90")
depends_on("cuda@12.0:", when="cuda_arch=90")
# From the NVIDIA install guide we know of conflicts for particular
# platforms (linux, darwin), architectures (x86, powerpc) and compilers

View File

@@ -121,7 +121,7 @@ def setup_run_environment(self, env):
$ source {prefix}/{component}/{version}/env/vars.sh
"""
# Only if environment modifications are desired (default is +envmods)
if "+envmods" in self.spec:
if "~envmods" not in self.spec:
env.extend(
EnvironmentModifications.from_sourcing_file(
join_path(self.component_prefix, "env", "vars.sh")
@@ -175,7 +175,7 @@ def libs(self):
return find_libraries("*", root=lib_path, shared=True, recursive=True)
class IntelOneApiStaticLibraryList(object):
class IntelOneApiStaticLibraryList:
"""Provides ld_flags when static linking is needed
Oneapi puts static and dynamic libraries in the same directory, so

View File

@@ -23,6 +23,7 @@
import spack.store
from spack.directives import build_system, depends_on, extends, maintainers
from spack.error import NoHeadersError, NoLibrariesError, SpecError
from spack.install_test import test_part
from spack.version import Version
from ._checks import BaseBuilder, execute_install_time_tests
@@ -167,18 +168,65 @@ def remove_files_from_view(self, view, merge_map):
view.remove_files(to_remove)
def test(self):
def test_imports(self):
"""Attempts to import modules of the installed package."""
# Make sure we are importing the installed modules,
# not the ones in the source directory
python = inspect.getmodule(self).python
for module in self.import_modules:
self.run_test(
inspect.getmodule(self).python.path,
["-c", "import {0}".format(module)],
purpose="checking import of {0}".format(module),
with test_part(
self,
f"test_imports_{module}",
purpose=f"checking import of {module}",
work_dir="spack-test",
)
):
python("-c", f"import {module}")
def update_external_dependencies(self, extendee_spec=None):
"""
Ensure all external python packages have a python dependency
If another package in the DAG depends on python, we use that
python for the dependency of the external. If not, we assume
that the external PythonPackage is installed into the same
directory as the python it depends on.
"""
# TODO: Include this in the solve, rather than instantiating post-concretization
if "python" not in self.spec:
if extendee_spec:
python = extendee_spec
elif "python" in self.spec.root:
python = self.spec.root["python"]
else:
python = self.get_external_python_for_prefix()
if not python.concrete:
repo = spack.repo.path.repo_for_pkg(python)
python.namespace = repo.namespace
# Ensure architecture information is present
if not python.architecture:
host_platform = spack.platforms.host()
host_os = host_platform.operating_system("default_os")
host_target = host_platform.target("default_target")
python.architecture = spack.spec.ArchSpec(
(str(host_platform), str(host_os), str(host_target))
)
else:
if not python.architecture.platform:
python.architecture.platform = spack.platforms.host()
if not python.architecture.os:
python.architecture.os = "default_os"
if not python.architecture.target:
python.architecture.target = archspec.cpu.host().family.name
# Ensure compiler information is present
if not python.compiler:
python.compiler = self.spec.compiler
python.external_path = self.spec.external_path
python._mark_concrete()
self.spec.add_dependency_edge(python, deptypes=("build", "link", "run"), virtuals=())
class PythonPackage(PythonExtension):
@@ -225,51 +273,6 @@ def list_url(cls):
name = cls.pypi.split("/")[0]
return "https://pypi.org/simple/" + name + "/"
def update_external_dependencies(self, extendee_spec=None):
"""
Ensure all external python packages have a python dependency
If another package in the DAG depends on python, we use that
python for the dependency of the external. If not, we assume
that the external PythonPackage is installed into the same
directory as the python it depends on.
"""
# TODO: Include this in the solve, rather than instantiating post-concretization
if "python" not in self.spec:
if extendee_spec:
python = extendee_spec
elif "python" in self.spec.root:
python = self.spec.root["python"]
else:
python = self.get_external_python_for_prefix()
if not python.concrete:
repo = spack.repo.path.repo_for_pkg(python)
python.namespace = repo.namespace
# Ensure architecture information is present
if not python.architecture:
host_platform = spack.platforms.host()
host_os = host_platform.operating_system("default_os")
host_target = host_platform.target("default_target")
python.architecture = spack.spec.ArchSpec(
(str(host_platform), str(host_os), str(host_target))
)
else:
if not python.architecture.platform:
python.architecture.platform = spack.platforms.host()
if not python.architecture.os:
python.architecture.os = "default_os"
if not python.architecture.target:
python.architecture.target = archspec.cpu.host().family.name
# Ensure compiler information is present
if not python.compiler:
python.compiler = self.spec.compiler
python.external_path = self.spec.external_path
python._mark_concrete()
self.spec.add_dependency_edge(python, deptypes=("build", "link", "run"))
def get_external_python_for_prefix(self):
"""
For an external package that extends python, find the most likely spec for the python
@@ -283,7 +286,7 @@ def get_external_python_for_prefix(self):
spack.spec.Spec: The external Spec for python most likely to be compatible with self.spec
"""
python_externals_installed = [
s for s in spack.store.db.query("python") if s.prefix == self.spec.external_path
s for s in spack.store.STORE.db.query("python") if s.prefix == self.spec.external_path
]
if python_externals_installed:
return python_externals_installed[0]
@@ -398,7 +401,8 @@ def build_directory(self):
def config_settings(self, spec, prefix):
"""Configuration settings to be passed to the PEP 517 build backend.
Requires pip 22.1+, which requires Python 3.7+.
Requires pip 22.1 or newer.
Args:
spec (spack.spec.Spec): build spec
@@ -412,6 +416,8 @@ def config_settings(self, spec, prefix):
def install_options(self, spec, prefix):
"""Extra arguments to be supplied to the setup.py install command.
Requires pip 23.0 or older.
Args:
spec (spack.spec.Spec): build spec
prefix (spack.util.prefix.Prefix): installation prefix
@@ -425,6 +431,8 @@ def global_options(self, spec, prefix):
"""Extra global options to be supplied to the setup.py call before the install
or bdist_wheel command.
Deprecated in pip 23.1.
Args:
spec (spack.spec.Spec): build spec
prefix (spack.util.prefix.Prefix): installation prefix

View File

@@ -28,7 +28,7 @@ class QMakePackage(spack.package_base.PackageBase):
build_system("qmake")
depends_on("qt", type="build", when="build_system=qmake")
depends_on("qmake", type="build", when="build_system=qmake")
@spack.builder.builder("qmake")

View File

@@ -7,7 +7,7 @@
import llnl.util.lang as lang
from spack.directives import extends, maintainers
from spack.directives import extends
from .generic import GenericBuilder, Package
@@ -71,8 +71,6 @@ class RPackage(Package):
GenericBuilder = RBuilder
maintainers("glennpj")
#: This attribute is used in UI queries that need to know the build
#: system base class
build_system_class = "RPackage"

View File

@@ -7,12 +7,14 @@
import re
import llnl.util.tty as tty
from llnl.util.filesystem import find, join_path, working_dir
from llnl.util.filesystem import find, working_dir
import spack.builder
import spack.install_test
import spack.package_base
from spack.directives import build_system, depends_on, extends
from spack.multimethod import when
from spack.util.executable import Executable
from ._checks import BaseBuilder, execute_install_time_tests
@@ -30,17 +32,16 @@ class SIPPackage(spack.package_base.PackageBase):
#: Name of private sip module to install alongside package
sip_module = "sip"
#: Callback names for install-time test
install_time_test_callbacks = ["test"]
#: Callback names for install-time testing
install_time_test_callbacks = ["test_imports"]
#: Legacy buildsystem attribute used to deserialize and install old specs
legacy_buildsystem = "sip"
build_system("sip")
with when("build_system=sip"):
extends("python")
depends_on("qt")
depends_on("py-sip")
extends("python", type=("build", "link", "run"))
depends_on("py-sip", type="build")
@property
def import_modules(self):
@@ -87,18 +88,20 @@ def python(self, *args, **kwargs):
"""The python ``Executable``."""
inspect.getmodule(self).python(*args, **kwargs)
def test(self):
def test_imports(self):
"""Attempts to import modules of the installed package."""
# Make sure we are importing the installed modules,
# not the ones in the source directory
python = inspect.getmodule(self).python
for module in self.import_modules:
self.run_test(
inspect.getmodule(self).python.path,
["-c", "import {0}".format(module)],
with spack.install_test.test_part(
self,
"test_imports_{0}".format(module),
purpose="checking import of {0}".format(module),
work_dir="spack-test",
)
):
python("-c", "import {0}".format(module))
@spack.builder.builder("sip")
@@ -110,13 +113,13 @@ class SIPBuilder(BaseBuilder):
* install
The configure phase already adds a set of default flags. To see more
options, run ``python configure.py --help``.
options, run ``sip-build --help``.
"""
phases = ("configure", "build", "install")
#: Names associated with package methods in the old build-system format
legacy_methods = ("configure_file", "configure_args", "build_args", "install_args")
legacy_methods = ("configure_args", "build_args", "install_args")
#: Names associated with package attributes in the old build-system format
legacy_attributes = (
@@ -127,34 +130,17 @@ class SIPBuilder(BaseBuilder):
"build_directory",
)
def configure_file(self):
"""Returns the name of the configure file to use."""
return "configure.py"
build_directory = "build"
def configure(self, pkg, spec, prefix):
"""Configure the package."""
configure = self.configure_file()
args = self.configure_args()
# https://www.riverbankcomputing.com/static/Docs/sip/command_line_tools.html
args = ["--verbose", "--target-dir", inspect.getmodule(self.pkg).python_platlib]
args.extend(self.configure_args())
args.extend(
[
"--verbose",
"--confirm-license",
"--qmake",
spec["qt"].prefix.bin.qmake,
"--sip",
spec["py-sip"].prefix.bin.sip,
"--sip-incdir",
join_path(spec["py-sip"].prefix, spec["python"].package.include),
"--bindir",
prefix.bin,
"--destdir",
inspect.getmodule(self.pkg).python_platlib,
]
)
self.pkg.python(configure, *args)
sip_build = Executable(spec["py-sip"].prefix.bin.join("sip-build"))
sip_build(*args)
def configure_args(self):
"""Arguments to pass to configure."""
@@ -164,7 +150,8 @@ def build(self, pkg, spec, prefix):
"""Build the package."""
args = self.build_args()
inspect.getmodule(self.pkg).make(*args)
with working_dir(self.build_directory):
inspect.getmodule(self.pkg).make(*args)
def build_args(self):
"""Arguments to pass to build."""
@@ -174,21 +161,11 @@ def install(self, pkg, spec, prefix):
"""Install the package."""
args = self.install_args()
inspect.getmodule(self.pkg).make("install", parallel=False, *args)
with working_dir(self.build_directory):
inspect.getmodule(self.pkg).make("install", *args)
def install_args(self):
"""Arguments to pass to install."""
return []
spack.builder.run_after("install")(execute_install_time_tests)
@spack.builder.run_after("install")
def extend_path_setup(self):
# See github issue #14121 and PR #15297
module = self.pkg.spec["py-sip"].variants["module"].value
if module != "sip":
module = module.split(".")[0]
with working_dir(inspect.getmodule(self.pkg).python_platlib):
with open(os.path.join(module, "__init__.py"), "a") as f:
f.write("from pkgutil import extend_path\n")
f.write("__path__ = extend_path(__path__, __name__)\n")

View File

@@ -63,7 +63,7 @@ def create(pkg):
return _BUILDERS[id(pkg)]
class _PhaseAdapter(object):
class _PhaseAdapter:
def __init__(self, builder, phase_fn):
self.builder = builder
self.phase_fn = phase_fn
@@ -115,7 +115,7 @@ class hierarchy (look at AspellDictPackage for an example of that)
# package. The semantic should be the same as the method in the base builder were still
# present in the base class of the package.
class _ForwardToBaseBuilder(object):
class _ForwardToBaseBuilder:
def __init__(self, wrapped_pkg_object, root_builder):
self.wrapped_package_object = wrapped_pkg_object
self.root_builder = root_builder
@@ -188,7 +188,7 @@ def __init__(self, pkg):
# Attribute containing the package wrapped in dispatcher with a `__getattr__`
# method that will forward certain calls to the default builder.
self.pkg_with_dispatcher = _ForwardToBaseBuilder(pkg, root_builder=self)
super(Adapter, self).__init__(pkg)
super().__init__(pkg)
# These two methods don't follow the (self, spec, prefix) signature of phases nor
# the (self) signature of methods, so they are added explicitly to avoid using a
@@ -388,7 +388,7 @@ def __new__(mcs, name, bases, attr_dict):
return super(_PackageAdapterMeta, mcs).__new__(mcs, name, bases, attr_dict)
class InstallationPhase(object):
class InstallationPhase:
"""Manages a single phase of the installation.
This descriptor stores at creation time the name of the method it should
@@ -530,9 +530,9 @@ def setup_build_environment(self, env):
modifications to be applied when the package is built. Package authors
can call methods on it to alter the build environment.
"""
if not hasattr(super(Builder, self), "setup_build_environment"):
if not hasattr(super(), "setup_build_environment"):
return
super(Builder, self).setup_build_environment(env)
super().setup_build_environment(env)
def setup_dependent_build_environment(self, env, dependent_spec):
"""Sets up the build environment of packages that depend on this one.
@@ -563,9 +563,9 @@ def setup_dependent_build_environment(self, env, dependent_spec):
the dependent's state. Note that *this* package's spec is
available as ``self.spec``
"""
if not hasattr(super(Builder, self), "setup_dependent_build_environment"):
if not hasattr(super(), "setup_dependent_build_environment"):
return
super(Builder, self).setup_dependent_build_environment(env, dependent_spec)
super().setup_dependent_build_environment(env, dependent_spec)
def __getitem__(self, idx):
key = self.phases[idx]

View File

@@ -58,7 +58,7 @@ def _fetch_cache():
return spack.fetch_strategy.FsCache(path)
class MirrorCache(object):
class MirrorCache:
def __init__(self, root, skip_unstable_versions):
self.root = os.path.abspath(root)
self.skip_unstable_versions = skip_unstable_versions

File diff suppressed because it is too large Load Diff

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import argparse
import os
import re
@@ -149,7 +147,7 @@ def get_command(cmd_name):
return getattr(get_module(cmd_name), pname)
class _UnquotedFlags(object):
class _UnquotedFlags:
"""Use a heuristic in `.extract()` to detect whether the user is trying to set
multiple flags like the docker ENV attribute allows (e.g. 'cflags=-Os -pipe').
@@ -275,9 +273,9 @@ def disambiguate_spec_from_hashes(spec, hashes, local=False, installed=True, fir
See ``spack.database.Database._query`` for details.
"""
if local:
matching_specs = spack.store.db.query_local(spec, hashes=hashes, installed=installed)
matching_specs = spack.store.STORE.db.query_local(spec, hashes=hashes, installed=installed)
else:
matching_specs = spack.store.db.query(spec, hashes=hashes, installed=installed)
matching_specs = spack.store.STORE.db.query(spec, hashes=hashes, installed=installed)
if not matching_specs:
tty.die("Spec '%s' matches no installed packages." % spec)
@@ -385,7 +383,7 @@ def display_specs(specs, args=None, **kwargs):
deps (bool): Display dependencies with specs
long (bool): Display short hashes with specs
very_long (bool): Display full hashes with specs (supersedes ``long``)
namespace (bool): Print namespaces along with names
namespaces (bool): Print namespaces along with names
show_flags (bool): Show compiler flags with specs
variants (bool): Show variants with specs
indent (int): indent each line this much
@@ -409,7 +407,7 @@ def get_arg(name, default=None):
paths = get_arg("paths", False)
deps = get_arg("deps", False)
hashes = get_arg("long", False)
namespace = get_arg("namespace", False)
namespaces = get_arg("namespaces", False)
flags = get_arg("show_flags", False)
full_compiler = get_arg("show_full_compiler", False)
variants = get_arg("variants", False)
@@ -430,7 +428,7 @@ def get_arg(name, default=None):
format_string = get_arg("format", None)
if format_string is None:
nfmt = "{fullname}" if namespace else "{name}"
nfmt = "{fullname}" if namespaces else "{name}"
ffmt = ""
if full_compiler or flags:
ffmt += "{%compiler.name}"
@@ -475,7 +473,7 @@ def format_list(specs):
out = ""
# getting lots of prefixes requires DB lookups. Ensure
# all spec.prefix calls are in one transaction.
with spack.store.db.read_transaction():
with spack.store.STORE.db.read_transaction():
for string, spec in formatted:
if not string:
# print newline from above
@@ -547,7 +545,7 @@ class PythonNameError(spack.error.SpackError):
def __init__(self, name):
self.name = name
super(PythonNameError, self).__init__("{0} is not a permissible Python name.".format(name))
super().__init__("{0} is not a permissible Python name.".format(name))
class CommandNameError(spack.error.SpackError):
@@ -555,9 +553,7 @@ class CommandNameError(spack.error.SpackError):
def __init__(self, name):
self.name = name
super(CommandNameError, self).__init__(
"{0} is not a permissible Spack command name.".format(name)
)
super().__init__("{0} is not a permissible Spack command name.".format(name))
########################################
@@ -588,14 +584,14 @@ def require_active_env(cmd_name):
if env:
return env
else:
tty.die(
"`spack %s` requires an environment" % cmd_name,
"activate an environment first:",
" spack env activate ENV",
"or use:",
" spack -e ENV %s ..." % cmd_name,
)
tty.die(
"`spack %s` requires an environment" % cmd_name,
"activate an environment first:",
" spack env activate ENV",
"or use:",
" spack -e ENV %s ..." % cmd_name,
)
def find_environment(args):

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import collections
import archspec.cpu

View File

@@ -59,7 +59,7 @@ def setup_parser(subparser):
subparser.add_argument(
"package_or_file",
help="name of package to show contributions for, " "or path to a file in the spack repo",
help="name of package to show contributions for, or path to a file in the spack repo",
)

View File

@@ -2,8 +2,6 @@
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import os.path
import shutil
import tempfile

View File

@@ -2,12 +2,14 @@
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import argparse
import glob
import json
import os
import shutil
import sys
import tempfile
from typing import List
import llnl.util.tty as tty
import llnl.util.tty.color as clr
@@ -18,7 +20,6 @@
import spack.cmd.common.arguments as arguments
import spack.config
import spack.environment as ev
import spack.hash_types as ht
import spack.mirror
import spack.relocate
import spack.repo
@@ -28,7 +29,6 @@
import spack.util.url as url_util
import spack.util.web as web_util
from spack.cmd import display_specs
from spack.error import SpecError
from spack.spec import Spec, save_dependency_specfiles
from spack.stage import Stage
from spack.util.string import plural
@@ -38,101 +38,55 @@
level = "long"
def setup_parser(subparser):
setup_parser.parser = subparser
def setup_parser(subparser: argparse.ArgumentParser):
setattr(setup_parser, "parser", subparser)
subparsers = subparser.add_subparsers(help="buildcache sub-commands")
push = subparsers.add_parser("push", aliases=["create"], help=push_fn.__doc__)
# TODO: remove from Spack 0.21
push.add_argument("-f", "--force", action="store_true", help="overwrite tarball if it exists")
push.add_argument(
"-r",
"--rel",
action="store_true",
help="make all rpaths relative before creating tarballs. (deprecated)",
)
push.add_argument("-f", "--force", action="store_true", help="overwrite tarball if it exists.")
push.add_argument(
"-u", "--unsigned", action="store_true", help="push unsigned buildcache tarballs"
)
push.add_argument(
"-a",
"--allow-root",
"-a",
action="store_true",
help="allow install root string in binary files after RPATH substitution",
)
push.add_argument(
"-k", "--key", metavar="key", type=str, default=None, help="Key for signing."
push_sign = push.add_mutually_exclusive_group(required=False)
push_sign.add_argument(
"--unsigned", "-u", action="store_true", help="push unsigned buildcache tarballs"
)
output = push.add_mutually_exclusive_group(required=False)
# TODO: remove from Spack 0.21
output.add_argument(
"-d",
"--directory",
metavar="directory",
dest="mirror_flag",
type=arguments.mirror_directory,
help="local directory where buildcaches will be written. (deprecated)",
push_sign.add_argument(
"--key", "-k", metavar="key", type=str, default=None, help="key for signing"
)
# TODO: remove from Spack 0.21
output.add_argument(
"-m",
"--mirror-name",
metavar="mirror-name",
dest="mirror_flag",
type=arguments.mirror_name,
help="name of the mirror where buildcaches will be written. (deprecated)",
)
# TODO: remove from Spack 0.21
output.add_argument(
"--mirror-url",
metavar="mirror-url",
dest="mirror_flag",
type=arguments.mirror_url,
help="URL of the mirror where buildcaches will be written. (deprecated)",
)
# Unfortunately we cannot add this to the mutually exclusive group above,
# because we have further positional arguments.
# TODO: require from Spack 0.21
push.add_argument("mirror", type=str, help="Mirror name, path, or URL.", nargs="?")
push.add_argument("mirror", type=str, help="mirror name, path, or URL")
push.add_argument(
"--update-index",
"--rebuild-index",
action="store_true",
default=False,
help="Regenerate buildcache index after building package(s)",
help="regenerate buildcache index after building package(s)",
)
push.add_argument(
"--spec-file", default=None, help="Create buildcache entry for spec from json or yaml file"
"--spec-file", default=None, help="create buildcache entry for spec from json or yaml file"
)
push.add_argument(
"--only",
default="package,dependencies",
dest="things_to_install",
choices=["package", "dependencies"],
help=(
"Select the buildcache mode. the default is to"
" build a cache for the package along with all"
" its dependencies. Alternatively, one can"
" decide to build a cache for only the package"
" or only the dependencies"
),
help="select the buildcache mode. "
"The default is to build a cache for the package along with all its dependencies. "
"Alternatively, one can decide to build a cache for only the package or only the "
"dependencies",
)
arguments.add_common_arguments(push, ["specs"])
push.set_defaults(func=push_fn)
install = subparsers.add_parser("install", help=install_fn.__doc__)
install.add_argument(
"-f", "--force", action="store_true", help="overwrite install directory if it exists."
"-f", "--force", action="store_true", help="overwrite install directory if it exists"
)
install.add_argument(
"-m", "--multiple", action="store_true", help="allow all matching packages "
)
# TODO: remove from Spack 0.21
install.add_argument(
"-a",
"--allow-root",
action="store_true",
help="allow install root string in binary files after RPATH substitution. (deprecated)",
"-m", "--multiple", action="store_true", help="allow all matching packages"
)
install.add_argument(
"-u",
@@ -151,7 +105,7 @@ def setup_parser(subparser):
install.set_defaults(func=install_fn)
listcache = subparsers.add_parser("list", help=list_fn.__doc__)
arguments.add_common_arguments(listcache, ["long", "very_long"])
arguments.add_common_arguments(listcache, ["long", "very_long", "namespaces"])
listcache.add_argument(
"-v",
"--variants",
@@ -186,11 +140,11 @@ def setup_parser(subparser):
"-m",
"--mirror-url",
default=None,
help="Override any configured mirrors with this mirror URL",
help="override any configured mirrors with this mirror URL",
)
check.add_argument(
"-o", "--output-file", default=None, help="File where rebuild info should be written"
"-o", "--output-file", default=None, help="file where rebuild info should be written"
)
# used to construct scope arguments below
@@ -204,31 +158,32 @@ def setup_parser(subparser):
default=spack.config.default_modify_scope(),
help="configuration scope containing mirrors to check",
)
check.add_argument(
"-s", "--spec", default=None, help="Check single spec instead of release specs file"
check_spec_or_specfile = check.add_mutually_exclusive_group(required=True)
check_spec_or_specfile.add_argument(
"-s", "--spec", help="check single spec instead of release specs file"
)
check.add_argument(
check_spec_or_specfile.add_argument(
"--spec-file",
default=None,
help=("Check single spec from json or yaml file instead of release specs file"),
help="check single spec from json or yaml file instead of release specs file",
)
check.set_defaults(func=check_fn)
# Download tarball and specfile
download = subparsers.add_parser("download", help=download_fn.__doc__)
download.add_argument(
"-s", "--spec", default=None, help="Download built tarball for spec from mirror"
download_spec_or_specfile = download.add_mutually_exclusive_group(required=True)
download_spec_or_specfile.add_argument(
"-s", "--spec", help="download built tarball for spec from mirror"
)
download_spec_or_specfile.add_argument(
"--spec-file", help="download built tarball for spec (from json or yaml file) from mirror"
)
download.add_argument(
"--spec-file",
"-p",
"--path",
required=True,
default=None,
help=("Download built tarball for spec (from json or yaml file) from mirror"),
)
download.add_argument(
"-p", "--path", default=None, help="Path to directory where tarball should be downloaded"
help="path to directory where tarball should be downloaded",
)
download.set_defaults(func=download_fn)
@@ -236,107 +191,53 @@ def setup_parser(subparser):
getbuildcachename = subparsers.add_parser(
"get-buildcache-name", help=get_buildcache_name_fn.__doc__
)
getbuildcachename.add_argument(
"-s", "--spec", default=None, help="Spec string for which buildcache name is desired"
getbuildcachename_spec_or_specfile = getbuildcachename.add_mutually_exclusive_group(
required=True
)
getbuildcachename.add_argument(
"--spec-file",
default=None,
help=("Path to spec json or yaml file for which buildcache name is desired"),
getbuildcachename_spec_or_specfile.add_argument(
"-s", "--spec", help="spec string for which buildcache name is desired"
)
getbuildcachename_spec_or_specfile.add_argument(
"--spec-file", help="path to spec json or yaml file for which buildcache name is desired"
)
getbuildcachename.set_defaults(func=get_buildcache_name_fn)
# Given the root spec, save the yaml of the dependent spec to a file
savespecfile = subparsers.add_parser("save-specfile", help=save_specfile_fn.__doc__)
savespecfile.add_argument("--root-spec", default=None, help="Root spec of dependent spec")
savespecfile.add_argument(
"--root-specfile",
default=None,
help="Path to json or yaml file containing root spec of dependent spec",
savespecfile_spec_or_specfile = savespecfile.add_mutually_exclusive_group(required=True)
savespecfile_spec_or_specfile.add_argument("--root-spec", help="root spec of dependent spec")
savespecfile_spec_or_specfile.add_argument(
"--root-specfile", help="path to json or yaml file containing root spec of dependent spec"
)
savespecfile.add_argument(
"-s",
"--specs",
default=None,
help="List of dependent specs for which saved yaml is desired",
required=True,
help="list of dependent specs for which saved yaml is desired",
)
savespecfile.add_argument(
"--specfile-dir", default=None, help="Path to directory where spec yamls should be saved"
"--specfile-dir", required=True, help="path to directory where spec yamls should be saved"
)
savespecfile.set_defaults(func=save_specfile_fn)
# Sync buildcache entries from one mirror to another
sync = subparsers.add_parser("sync", help=sync_fn.__doc__)
sync.add_argument(
"--manifest-glob",
default=None,
help="A quoted glob pattern identifying copy manifest files",
"--manifest-glob", help="a quoted glob pattern identifying copy manifest files"
)
source = sync.add_mutually_exclusive_group(required=False)
# TODO: remove in Spack 0.21
source.add_argument(
"--src-directory",
metavar="DIRECTORY",
dest="src_mirror_flag",
type=arguments.mirror_directory,
help="Source mirror as a local file path (deprecated)",
)
# TODO: remove in Spack 0.21
source.add_argument(
"--src-mirror-name",
metavar="MIRROR_NAME",
dest="src_mirror_flag",
type=arguments.mirror_name,
help="Name of the source mirror (deprecated)",
)
# TODO: remove in Spack 0.21
source.add_argument(
"--src-mirror-url",
metavar="MIRROR_URL",
dest="src_mirror_flag",
type=arguments.mirror_url,
help="URL of the source mirror (deprecated)",
)
# TODO: only support this in 0.21
source.add_argument(
sync.add_argument(
"src_mirror",
metavar="source mirror",
type=arguments.mirror_name_or_url,
help="Source mirror name, path, or URL",
nargs="?",
help="source mirror name, path, or URL",
)
dest = sync.add_mutually_exclusive_group(required=False)
# TODO: remove in Spack 0.21
dest.add_argument(
"--dest-directory",
metavar="DIRECTORY",
dest="dest_mirror_flag",
type=arguments.mirror_directory,
help="Destination mirror as a local file path (deprecated)",
)
# TODO: remove in Spack 0.21
dest.add_argument(
"--dest-mirror-name",
metavar="MIRROR_NAME",
type=arguments.mirror_name,
dest="dest_mirror_flag",
help="Name of the destination mirror (deprecated)",
)
# TODO: remove in Spack 0.21
dest.add_argument(
"--dest-mirror-url",
metavar="MIRROR_URL",
dest="dest_mirror_flag",
type=arguments.mirror_url,
help="URL of the destination mirror (deprecated)",
)
# TODO: only support this in 0.21
dest.add_argument(
sync.add_argument(
"dest_mirror",
metavar="destination mirror",
type=arguments.mirror_name_or_url,
help="Destination mirror name, path, or URL",
nargs="?",
help="destination mirror name, path, or URL",
)
sync.set_defaults(func=sync_fn)
@@ -344,124 +245,48 @@ def setup_parser(subparser):
update_index = subparsers.add_parser(
"update-index", aliases=["rebuild-index"], help=update_index_fn.__doc__
)
update_index_out = update_index.add_mutually_exclusive_group(required=True)
# TODO: remove in Spack 0.21
update_index_out.add_argument(
"-d",
"--directory",
metavar="directory",
dest="mirror_flag",
type=arguments.mirror_directory,
help="local directory where buildcaches will be written (deprecated)",
)
# TODO: remove in Spack 0.21
update_index_out.add_argument(
"-m",
"--mirror-name",
metavar="mirror-name",
dest="mirror_flag",
type=arguments.mirror_name,
help="name of the mirror where buildcaches will be written (deprecated)",
)
# TODO: remove in Spack 0.21
update_index_out.add_argument(
"--mirror-url",
metavar="mirror-url",
dest="mirror_flag",
type=arguments.mirror_url,
help="URL of the mirror where buildcaches will be written (deprecated)",
)
# TODO: require from Spack 0.21
update_index_out.add_argument(
"mirror",
type=arguments.mirror_name_or_url,
help="Destination mirror name, path, or URL",
nargs="?",
update_index.add_argument(
"mirror", type=arguments.mirror_name_or_url, help="destination mirror name, path, or URL"
)
update_index.add_argument(
"-k",
"--keys",
default=False,
action="store_true",
help="If provided, key index will be updated as well as package index",
help="if provided, key index will be updated as well as package index",
)
update_index.set_defaults(func=update_index_fn)
def _matching_specs(specs, spec_file):
"""Return a list of matching specs read from either a spec file (JSON or YAML),
a query over the store or a query over the active environment.
"""
env = ev.active_environment()
hashes = env.all_hashes() if env else None
if spec_file:
return spack.store.specfile_matches(spec_file, hashes=hashes)
if specs:
constraints = spack.cmd.parse_specs(specs)
return spack.store.find(constraints, hashes=hashes)
if env:
return [concrete for _, concrete in env.concretized_specs()]
tty.die(
"build cache file creation requires at least one"
" installed package spec, an active environment,"
" or else a path to a json or yaml file containing a spec"
" to install"
)
def _concrete_spec_from_args(args):
spec_str, specfile_path = args.spec, args.spec_file
if not spec_str and not specfile_path:
tty.error("must provide either spec string or path to YAML or JSON specfile")
sys.exit(1)
if spec_str:
try:
constraints = spack.cmd.parse_specs(spec_str)
spec = spack.store.find(constraints)[0]
spec.concretize()
except SpecError as spec_error:
tty.error("Unable to concretize spec {0}".format(spec_str))
tty.debug(spec_error)
sys.exit(1)
return spec
return Spec.from_specfile(specfile_path)
def _matching_specs(specs: List[Spec]) -> List[Spec]:
"""Disambiguate specs and return a list of matching specs"""
return [spack.cmd.disambiguate_spec(s, ev.active_environment(), installed=any) for s in specs]
def push_fn(args):
"""create a binary package and push it to a mirror"""
if args.mirror_flag:
mirror = args.mirror_flag
elif not args.mirror:
raise ValueError("No mirror provided")
else:
mirror = arguments.mirror_name_or_url(args.mirror)
if args.mirror_flag:
if args.spec_file:
tty.warn(
"Using flags to specify mirrors is deprecated and will be removed in "
"Spack 0.21, use positional arguments instead."
"The flag `--spec-file` is deprecated and will be removed in Spack 0.22. "
"Use positional arguments instead."
)
if args.rel:
tty.warn("The --rel flag is deprecated and will be removed in Spack 0.21")
if args.specs or args.spec_file:
specs = _matching_specs(spack.cmd.parse_specs(args.specs or args.spec_file))
else:
specs = spack.cmd.require_active_env("buildcache push").all_specs()
# TODO: remove this in 0.21. If we have mirror_flag, the first
# spec is in the positional mirror arg due to argparse limitations.
input_specs = args.specs
if args.mirror_flag and args.mirror:
input_specs.insert(0, args.mirror)
mirror = arguments.mirror_name_or_url(args.mirror)
if args.allow_root:
tty.warn(
"The flag `--allow-root` is the default in Spack 0.21, will be removed in Spack 0.22"
)
url = mirror.push_url
specs = bindist.specs_to_be_packaged(
_matching_specs(input_specs, args.spec_file),
specs,
root="package" in args.things_to_install,
dependencies="dependencies" in args.things_to_install,
)
@@ -486,9 +311,7 @@ def push_fn(args):
url,
bindist.PushOptions(
force=args.force,
relative=args.rel,
unsigned=args.unsigned,
allow_root=args.allow_root,
key=args.key,
regenerate_index=args.update_index,
),
@@ -524,9 +347,6 @@ def install_fn(args):
if not args.specs:
tty.die("a spec argument is required to install from a buildcache")
if args.allow_root:
tty.warn("The --allow-root flag is deprecated and will be removed in Spack 0.21")
query = bindist.BinaryCacheQuery(all_architectures=args.otherarch)
matches = spack.store.find(args.specs, multiple=args.multiple, query_fn=query)
for match in matches:
@@ -564,32 +384,31 @@ def keys_fn(args):
def preview_fn(args):
"""analyze an installed spec and reports whether executables
and libraries are relocatable
"""
constraints = spack.cmd.parse_specs(args.specs)
specs = spack.store.find(constraints, multiple=True)
# Cycle over the specs that match
for spec in specs:
print("Relocatable nodes")
print("--------------------------------")
print(spec.tree(status_fn=spack.relocate.is_relocatable))
"""analyze an installed spec and reports whether executables and libraries are relocatable"""
tty.warn(
"`spack buildcache preview` is deprecated since `spack buildcache push --allow-root` is "
"now the default. This command will be removed in Spack 0.22"
)
def check_fn(args):
"""Check specs (either a single spec from --spec, or else the full set
of release specs) against remote binary mirror(s) to see if any need
to be rebuilt. This command uses the process exit code to indicate
its result, specifically, if the exit code is non-zero, then at least
one of the indicated specs needs to be rebuilt.
"""check specs against remote binary mirror(s) to see if any need to be rebuilt
this command uses the process exit code to indicate its result, specifically, if the
exit code is non-zero, then at least one of the indicated specs needs to be rebuilt
"""
if args.spec or args.spec_file:
specs = [_concrete_spec_from_args(args)]
if args.spec_file:
tty.warn(
"The flag `--spec-file` is deprecated and will be removed in Spack 0.22. "
"Use --spec instead."
)
specs = spack.cmd.parse_specs(args.spec or args.spec_file)
if specs:
specs = _matching_specs(specs, specs)
else:
env = spack.cmd.require_active_env(cmd_name="buildcache")
env.concretize()
specs = env.all_specs()
specs = spack.cmd.require_active_env("buildcache check").all_specs()
if not specs:
tty.msg("No specs provided, exiting.")
@@ -613,63 +432,61 @@ def check_fn(args):
def download_fn(args):
"""Download buildcache entry from a remote mirror to local folder. This
command uses the process exit code to indicate its result, specifically,
a non-zero exit code indicates that the command failed to download at
least one of the required buildcache components."""
if not args.spec and not args.spec_file:
tty.msg("No specs provided, exiting.")
return
"""download buildcache entry from a remote mirror to local folder
if not args.path:
tty.msg("No download path provided, exiting")
return
this command uses the process exit code to indicate its result, specifically, a non-zero exit
code indicates that the command failed to download at least one of the required buildcache
components
"""
if args.spec_file:
tty.warn(
"The flag `--spec-file` is deprecated and will be removed in Spack 0.22. "
"Use --spec instead."
)
spec = _concrete_spec_from_args(args)
result = bindist.download_single_spec(spec, args.path)
specs = _matching_specs(spack.cmd.parse_specs(args.spec or args.spec_file))
if not result:
if len(specs) != 1:
tty.die("a single spec argument is required to download from a buildcache")
if not bindist.download_single_spec(specs[0], args.path):
sys.exit(1)
def get_buildcache_name_fn(args):
"""Get name (prefix) of buildcache entries for this spec"""
spec = _concrete_spec_from_args(args)
buildcache_name = bindist.tarball_name(spec, "")
print("{0}".format(buildcache_name))
"""get name (prefix) of buildcache entries for this spec"""
tty.warn("This command is deprecated and will be removed in Spack 0.22.")
specs = _matching_specs(spack.cmd.parse_specs(args.spec or args.spec_file))
if len(specs) != 1:
tty.die("a single spec argument is required to get buildcache name")
print(bindist.tarball_name(specs[0], ""))
def save_specfile_fn(args):
"""Get full spec for dependencies, relative to root spec, and write them
to files in the specified output directory. Uses exit code to signal
success or failure. An exit code of zero means the command was likely
successful. If any errors or exceptions are encountered, or if expected
command-line arguments are not provided, then the exit code will be
non-zero.
"""get full spec for dependencies and write them to files in the specified output directory
uses exit code to signal success or failure. an exit code of zero means the command was likely
successful. if any errors or exceptions are encountered, or if expected command-line arguments
are not provided, then the exit code will be non-zero
"""
if not args.root_spec and not args.root_specfile:
tty.msg("No root spec provided, exiting.")
sys.exit(1)
if not args.specs:
tty.msg("No dependent specs provided, exiting.")
sys.exit(1)
if not args.specfile_dir:
tty.msg("No yaml directory provided, exiting.")
sys.exit(1)
if args.root_specfile:
with open(args.root_specfile) as fd:
root_spec_as_json = fd.read()
spec_format = "yaml" if args.root_specfile.endswith("yaml") else "json"
else:
root_spec = Spec(args.root_spec)
root_spec.concretize()
root_spec_as_json = root_spec.to_json(hash=ht.dag_hash)
spec_format = "json"
tty.warn(
"The flag `--root-specfile` is deprecated and will be removed in Spack 0.22. "
"Use --root-spec instead."
)
specs = spack.cmd.parse_specs(args.root_spec or args.root_specfile)
if len(specs) != 1:
tty.die("a single spec argument is required to save specfile")
root = specs[0]
if not root.concrete:
root.concretize()
save_dependency_specfiles(
root_spec_as_json, args.specfile_dir, args.specs.split(), spec_format
root, args.specfile_dir, dependencies=spack.cmd.parse_specs(args.specs)
)
@@ -699,32 +516,19 @@ def copy_buildcache_file(src_url, dest_url, local_path=None):
def sync_fn(args):
"""Syncs binaries (and associated metadata) from one mirror to another.
Requires an active environment in order to know which specs to sync.
"""sync binaries (and associated metadata) from one mirror to another
Args:
src (str): Source mirror URL
dest (str): Destination mirror URL
requires an active environment in order to know which specs to sync
"""
if args.manifest_glob:
manifest_copy(glob.glob(args.manifest_glob))
return 0
# If no manifest_glob, require a source and dest mirror.
# TODO: Simplify in Spack 0.21
if not (args.src_mirror_flag or args.src_mirror) or not (
args.dest_mirror_flag or args.dest_mirror
):
raise ValueError("Source and destination mirror are required.")
if args.src_mirror is None or args.dest_mirror is None:
tty.die("Provide mirrors to sync from and to.")
if args.src_mirror_flag or args.dest_mirror_flag:
tty.warn(
"Using flags to specify mirrors is deprecated and will be removed in "
"Spack 0.21, use positional arguments instead."
)
src_mirror = args.src_mirror_flag if args.src_mirror_flag else args.src_mirror
dest_mirror = args.dest_mirror_flag if args.dest_mirror_flag else args.dest_mirror
src_mirror = args.src_mirror
dest_mirror = args.dest_mirror
src_mirror_url = src_mirror.fetch_url
dest_mirror_url = dest_mirror.push_url
@@ -802,14 +606,8 @@ def update_index(mirror: spack.mirror.Mirror, update_keys=False):
def update_index_fn(args):
"""Update a buildcache index."""
if args.mirror_flag:
tty.warn(
"Using flags to specify mirrors is deprecated and will be removed in "
"Spack 0.21, use positional arguments instead."
)
mirror = args.mirror_flag if args.mirror_flag else args.mirror
update_index(mirror, update_keys=args.keys)
"""update a buildcache index"""
update_index(args.mirror, update_keys=args.keys)
def buildcache(parser, args):

View File

@@ -3,21 +3,22 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import argparse
import re
import sys
import llnl.util.tty as tty
import llnl.util.lang
from llnl.util import tty
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.repo
import spack.spec
import spack.stage
import spack.util.crypto
from spack.package_base import deprecated_version, preferred_version
from spack.cmd.common import arguments
from spack.package_base import PackageBase, deprecated_version, preferred_version
from spack.util.editor import editor
from spack.util.format import get_version_lines
from spack.util.naming import valid_fully_qualified_module_name
from spack.version import Version
@@ -33,35 +34,38 @@ def setup_parser(subparser):
default=False,
help="don't clean up staging area when command completes",
)
sp = subparser.add_mutually_exclusive_group()
sp.add_argument(
subparser.add_argument(
"-b",
"--batch",
action="store_true",
default=False,
help="don't ask which versions to checksum",
)
sp.add_argument(
subparser.add_argument(
"-l",
"--latest",
action="store_true",
default=False,
help="checksum the latest available version only",
help="checksum the latest available version",
)
sp.add_argument(
subparser.add_argument(
"-p",
"--preferred",
action="store_true",
default=False,
help="checksum the preferred version only",
help="checksum the known Spack preferred version",
)
subparser.add_argument(
modes_parser = subparser.add_mutually_exclusive_group()
modes_parser.add_argument(
"-a",
"--add-to-package",
action="store_true",
default=False,
help="add new versions to package",
)
modes_parser.add_argument(
"--verify", action="store_true", default=False, help="verify known package checksums"
)
arguments.add_common_arguments(subparser, ["package"])
subparser.add_argument(
"versions", nargs=argparse.REMAINDER, help="versions to generate checksums for"
@@ -82,86 +86,171 @@ def checksum(parser, args):
pkg_cls = spack.repo.path.get_pkg_class(args.package)
pkg = pkg_cls(spack.spec.Spec(args.package))
# Build a list of versions to checksum
versions = [Version(v) for v in args.versions]
# Define placeholder for remote versions.
# This'll help reduce redundant work if we need to check for the existance
# of remote versions more than once.
remote_versions = None
# Add latest version if requested
if args.latest:
remote_versions = pkg.fetch_remote_versions()
if len(remote_versions) > 0:
latest_version = sorted(remote_versions.keys(), reverse=True)[0]
versions.append(latest_version)
# Add preferred version if requested
if args.preferred:
versions.append(preferred_version(pkg))
# Store a dict of the form version -> URL
url_dict = {}
if not args.versions and args.preferred:
versions = [preferred_version(pkg)]
else:
versions = [Version(v) for v in args.versions]
if versions:
remote_versions = None
for version in versions:
if deprecated_version(pkg, version):
tty.warn("Version {0} is deprecated".format(version))
for version in versions:
if deprecated_version(pkg, version):
tty.warn(f"Version {version} is deprecated")
url = pkg.find_valid_url_for_version(version)
if url is not None:
url_dict[version] = url
continue
# if we get here, it's because no valid url was provided by the package
# do expensive fallback to try to recover
if remote_versions is None:
remote_versions = pkg.fetch_remote_versions()
if version in remote_versions:
url_dict[version] = remote_versions[version]
else:
url_dict = pkg.fetch_remote_versions()
url = pkg.find_valid_url_for_version(version)
if url is not None:
url_dict[version] = url
continue
# if we get here, it's because no valid url was provided by the package
# do expensive fallback to try to recover
if remote_versions is None:
remote_versions = pkg.fetch_remote_versions()
if version in remote_versions:
url_dict[version] = remote_versions[version]
if len(versions) <= 0:
if remote_versions is None:
remote_versions = pkg.fetch_remote_versions()
url_dict = remote_versions
if not url_dict:
tty.die("Could not find any remote versions for {0}".format(pkg.name))
tty.die(f"Could not find any remote versions for {pkg.name}")
version_lines = spack.stage.get_checksums_for_versions(
# print an empty line to create a new output section block
print()
version_hashes = spack.stage.get_checksums_for_versions(
url_dict,
pkg.name,
keep_stage=args.keep_stage,
batch=(args.batch or len(args.versions) > 0 or len(url_dict) == 1),
latest=args.latest,
batch=(args.batch or len(versions) > 0 or len(url_dict) == 1),
fetch_options=pkg.fetch_options,
)
if args.verify:
print_checksum_status(pkg, version_hashes)
sys.exit(0)
# convert dict into package.py version statements
version_lines = get_version_lines(version_hashes, url_dict)
print()
print(version_lines)
print()
if args.add_to_package:
filename = spack.repo.path.filename_for_package_name(pkg.name)
# Make sure we also have a newline after the last version
versions = [v + "\n" for v in version_lines.splitlines()]
versions.append("\n")
# We need to insert the versions in reversed order
versions.reverse()
versions.append(" # FIXME: Added by `spack checksum`\n")
version_line = None
add_versions_to_package(pkg, version_lines)
with open(filename, "r") as f:
lines = f.readlines()
for i in range(len(lines)):
# Black is drunk, so this is what it looks like for now
# See https://github.com/psf/black/issues/2156 for more information
if lines[i].startswith(" # FIXME: Added by `spack checksum`") or lines[
i
].startswith(" version("):
version_line = i
break
if version_line is not None:
for v in versions:
lines.insert(version_line, v)
def print_checksum_status(pkg: PackageBase, version_hashes: dict):
"""
Verify checksums present in version_hashes against those present
in the package's instructions.
with open(filename, "w") as f:
f.writelines(lines)
Args:
pkg (spack.package_base.PackageBase): A package class for a given package in Spack.
version_hashes (dict): A dictionary of the form: version -> checksum.
msg = "opening editor to verify"
"""
results = []
num_verified = 0
failed = False
if not sys.stdout.isatty():
msg = "please verify"
max_len = max(len(str(v)) for v in version_hashes)
num_total = len(version_hashes)
tty.info(
"Added {0} new versions to {1}, "
"{2}.".format(len(versions) - 2, args.package, msg)
)
for version, sha in version_hashes.items():
if version not in pkg.versions:
msg = "No previous checksum"
status = "-"
elif sha == pkg.versions[version]["sha256"]:
msg = "Correct"
status = "="
num_verified += 1
if sys.stdout.isatty():
editor(filename)
else:
tty.warn("Could not add new versions to {0}.".format(args.package))
msg = sha
status = "x"
failed = True
results.append("{0:{1}} {2} {3}".format(str(version), max_len, f"[{status}]", msg))
# Display table of checksum results.
tty.msg(f"Verified {num_verified} of {num_total}", "", *llnl.util.lang.elide_list(results), "")
# Terminate at the end of function to prevent additional output.
if failed:
print()
tty.die("Invalid checksums found.")
def add_versions_to_package(pkg: PackageBase, version_lines: str):
"""
Add checksumed versions to a package's instructions and open a user's
editor so they may double check the work of the function.
Args:
pkg (spack.package_base.PackageBase): A package class for a given package in Spack.
version_lines (str): A string of rendered version lines.
"""
# Get filename and path for package
filename = spack.repo.path.filename_for_package_name(pkg.name)
num_versions_added = 0
version_statement_re = re.compile(r"([\t ]+version\([^\)]*\))")
version_re = re.compile(r'[\t ]+version\(\s*"([^"]+)"[^\)]*\)')
# Split rendered version lines into tuple of (version, version_line)
# We reverse sort here to make sure the versions match the version_lines
new_versions = []
for ver_line in version_lines.split("\n"):
match = version_re.match(ver_line)
if match:
new_versions.append((Version(match.group(1)), ver_line))
with open(filename, "r+") as f:
contents = f.read()
split_contents = version_statement_re.split(contents)
for i, subsection in enumerate(split_contents):
# If there are no more versions to add we should exit
if len(new_versions) <= 0:
break
# Check if the section contains a version
contents_version = version_re.match(subsection)
if contents_version is not None:
parsed_version = Version(contents_version.group(1))
if parsed_version < new_versions[0][0]:
split_contents[i:i] = [new_versions.pop(0)[1], " # FIX ME", "\n"]
num_versions_added += 1
elif parsed_version == new_versions[0][0]:
new_versions.pop(0)
# Seek back to the start of the file so we can rewrite the file contents.
f.seek(0)
f.writelines("".join(split_contents))
tty.msg(f"Added {num_versions_added} new versions to {pkg.name}")
tty.msg(f"Open {filename} to review the additions.")
if sys.stdout.isatty():
editor(filename)

View File

@@ -18,6 +18,7 @@
import spack.environment as ev
import spack.hash_types as ht
import spack.mirror
import spack.util.gpg as gpg_util
import spack.util.url as url_util
import spack.util.web as web_util
@@ -47,40 +48,36 @@ def setup_parser(subparser):
generate.add_argument(
"--output-file",
default=None,
help="""pathname for the generated gitlab ci yaml file
Path to the file where generated jobs file should
be written. Default is .gitlab-ci.yml in the root of
the repository.""",
help="pathname for the generated gitlab ci yaml file\n\n"
"path to the file where generated jobs file should be written. "
"default is .gitlab-ci.yml in the root of the repository",
)
generate.add_argument(
"--copy-to",
default=None,
help="""path to additional directory for job files
This option provides an absolute path to a directory
where the generated jobs yaml file should be copied.
Default is not to copy.""",
help="path to additional directory for job files\n\n"
"this option provides an absolute path to a directory where the generated "
"jobs yaml file should be copied. default is not to copy",
)
generate.add_argument(
"--optimize",
action="store_true",
default=False,
help="""(Experimental) optimize the gitlab yaml file for size
Run the generated document through a series of
optimization passes designed to reduce the size
of the generated file.""",
help="(experimental) optimize the gitlab yaml file for size\n\n"
"run the generated document through a series of optimization passes "
"designed to reduce the size of the generated file",
)
generate.add_argument(
"--dependencies",
action="store_true",
default=False,
help="(Experimental) disable DAG scheduling; use " ' "plain" dependencies.',
help="(experimental) disable DAG scheduling (use 'plain' dependencies)",
)
generate.add_argument(
"--buildcache-destination",
default=None,
help="Override the mirror configured in the environment (spack.yaml) "
+ "in order to push binaries from the generated pipeline to a "
+ "different location.",
help="override the mirror configured in the environment\n\n"
"allows for pushing binaries from the generated pipeline to a different location",
)
prune_group = generate.add_mutually_exclusive_group()
prune_group.add_argument(
@@ -88,45 +85,37 @@ def setup_parser(subparser):
action="store_true",
dest="prune_dag",
default=True,
help="""skip up-to-date specs
Do not generate jobs for specs that are up-to-date
on the mirror.""",
help="skip up-to-date specs\n\n"
"do not generate jobs for specs that are up-to-date on the mirror",
)
prune_group.add_argument(
"--no-prune-dag",
action="store_false",
dest="prune_dag",
default=True,
help="""process up-to-date specs
Generate jobs for specs even when they are up-to-date
on the mirror.""",
help="process up-to-date specs\n\n"
"generate jobs for specs even when they are up-to-date on the mirror",
)
generate.add_argument(
"--check-index-only",
action="store_true",
dest="index_only",
default=False,
help="""only check spec state from buildcache indices
Spack always checks specs against configured binary
mirrors, regardless of the DAG pruning option.
If enabled, Spack will assume all remote buildcache
indices are up-to-date when assessing whether the spec
on the mirror, if present, is up-to-date. This has the
benefit of reducing pipeline generation time but at the
potential cost of needlessly rebuilding specs when the
indices are outdated.
If not enabled, Spack will fetch remote spec files
directly to assess whether the spec on the mirror is
up-to-date.""",
help="only check spec state from buildcache indices\n\n"
"Spack always checks specs against configured binary mirrors, regardless of the DAG "
"pruning option. if enabled, Spack will assume all remote buildcache indices are "
"up-to-date when assessing whether the spec on the mirror, if present, is up-to-date. "
"this has the benefit of reducing pipeline generation time but at the potential cost of "
"needlessly rebuilding specs when the indices are outdated. if not enabled, Spack will "
"fetch remote spec files directly to assess whether the spec on the mirror is up-to-date",
)
generate.add_argument(
"--artifacts-root",
default=None,
help="""path to the root of the artifacts directory
If provided, concrete environment files (spack.yaml,
spack.lock) will be generated under this directory.
Their location will be passed to generated child jobs
through the SPACK_CONCRETE_ENVIRONMENT_PATH variable.""",
help="path to the root of the artifacts directory\n\n"
"if provided, concrete environment files (spack.yaml, spack.lock) will be generated under "
"this directory. their location will be passed to generated child jobs through the "
"SPACK_CONCRETE_ENVIRONMENT_PATH variable",
)
generate.set_defaults(func=ci_generate)
@@ -150,13 +139,13 @@ def setup_parser(subparser):
"--tests",
action="store_true",
default=False,
help="""run stand-alone tests after the build""",
help="run stand-alone tests after the build",
)
rebuild.add_argument(
"--fail-fast",
action="store_true",
default=False,
help="""stop stand-alone tests after the first failure""",
help="stop stand-alone tests after the first failure",
)
rebuild.set_defaults(func=ci_rebuild)
@@ -166,23 +155,39 @@ def setup_parser(subparser):
description=deindent(ci_reproduce.__doc__),
help=spack.cmd.first_line(ci_reproduce.__doc__),
)
reproduce.add_argument("job_url", help="Url of job artifacts bundle")
reproduce.add_argument("job_url", help="URL of job artifacts bundle")
reproduce.add_argument(
"--runtime",
help="Container runtime to use.",
default="docker",
choices=["docker", "podman"],
)
reproduce.add_argument(
"--working-dir",
help="Where to unpack artifacts",
help="where to unpack artifacts",
default=os.path.join(os.getcwd(), "ci_reproduction"),
)
reproduce.add_argument(
"-s", "--autostart", help="Run docker reproducer automatically", action="store_true"
)
gpg_group = reproduce.add_mutually_exclusive_group(required=False)
gpg_group.add_argument(
"--gpg-file", help="Path to public GPG key for validating binary cache installs"
)
gpg_group.add_argument(
"--gpg-url", help="URL to public GPG key for validating binary cache installs"
)
reproduce.set_defaults(func=ci_reproduce)
def ci_generate(args):
"""Generate jobs file from a CI-aware spack file.
"""generate jobs file from a CI-aware spack file
If you want to report the results on CDash, you will need to set
the SPACK_CDASH_AUTH_TOKEN before invoking this command. The
value must be the CDash authorization token needed to create a
build group and register all generated jobs under it."""
if you want to report the results on CDash, you will need to set the SPACK_CDASH_AUTH_TOKEN
before invoking this command. the value must be the CDash authorization token needed to create
a build group and register all generated jobs under it
"""
env = spack.cmd.require_active_env(cmd_name="ci generate")
output_file = args.output_file
@@ -223,12 +228,13 @@ def ci_generate(args):
def ci_reindex(args):
"""Rebuild the buildcache index for the remote mirror.
"""rebuild the buildcache index for the remote mirror
Use the active, gitlab-enabled environment to rebuild the buildcache
index for the associated mirror."""
use the active, gitlab-enabled environment to rebuild the buildcache index for the associated
mirror
"""
env = spack.cmd.require_active_env(cmd_name="ci rebuild-index")
yaml_root = ev.config_dict(env.manifest)
yaml_root = env.manifest[ev.TOP_LEVEL_KEY]
if "mirrors" not in yaml_root or len(yaml_root["mirrors"].values()) < 1:
tty.die("spack ci rebuild-index requires an env containing a mirror")
@@ -242,10 +248,11 @@ def ci_reindex(args):
def ci_rebuild(args):
"""Rebuild a spec if it is not on the remote mirror.
"""rebuild a spec if it is not on the remote mirror
Check a single spec against the remote mirror, and rebuild it from
source if the mirror does not contain the hash."""
check a single spec against the remote mirror, and rebuild it from source if the mirror does
not contain the hash
"""
env = spack.cmd.require_active_env(cmd_name="ci rebuild")
# Make sure the environment is "gitlab-enabled", or else there's nothing
@@ -274,13 +281,19 @@ def ci_rebuild(args):
signing_key = os.environ.get("SPACK_SIGNING_KEY")
job_spec_pkg_name = os.environ.get("SPACK_JOB_SPEC_PKG_NAME")
job_spec_dag_hash = os.environ.get("SPACK_JOB_SPEC_DAG_HASH")
compiler_action = os.environ.get("SPACK_COMPILER_ACTION")
spack_pipeline_type = os.environ.get("SPACK_PIPELINE_TYPE")
remote_mirror_override = os.environ.get("SPACK_REMOTE_MIRROR_OVERRIDE")
remote_mirror_url = os.environ.get("SPACK_REMOTE_MIRROR_URL")
spack_ci_stack_name = os.environ.get("SPACK_CI_STACK_NAME")
shared_pr_mirror_url = os.environ.get("SPACK_CI_SHARED_PR_MIRROR_URL")
rebuild_everything = os.environ.get("SPACK_REBUILD_EVERYTHING")
require_signing = os.environ.get("SPACK_REQUIRE_SIGNING")
# Fail early if signing is required but we don't have a signing key
sign_binaries = require_signing is not None and require_signing.lower() == "true"
if sign_binaries and not spack_ci.can_sign_binaries():
gpg_util.list(False, True)
tty.die("SPACK_REQUIRE_SIGNING=True => spack must have exactly one signing key")
# Construct absolute paths relative to current $CI_PROJECT_DIR
ci_project_dir = os.environ.get("CI_PROJECT_DIR")
@@ -295,7 +308,6 @@ def ci_rebuild(args):
tty.debug("pipeline_artifacts_dir = {0}".format(pipeline_artifacts_dir))
tty.debug("remote_mirror_url = {0}".format(remote_mirror_url))
tty.debug("job_spec_pkg_name = {0}".format(job_spec_pkg_name))
tty.debug("compiler_action = {0}".format(compiler_action))
# Query the environment manifest to find out whether we're reporting to a
# CDash instance, and if so, gather some information from the manifest to
@@ -411,14 +423,6 @@ def ci_rebuild(args):
if signing_key:
spack_ci.import_signing_key(signing_key)
# Depending on the specifics of this job, we might need to turn on the
# "config:install_missing compilers" option (to build this job spec
# with a bootstrapped compiler), or possibly run "spack compiler find"
# (to build a bootstrap compiler or one of its deps in a
# compiler-agnostic way), or maybe do nothing at all (to build a spec
# using a compiler already installed on the target system).
spack_ci.configure_compilers(compiler_action)
# Write this job's spec json into the reproduction directory, and it will
# also be used in the generated "spack install" command to install the spec
tty.debug("job concrete spec path: {0}".format(job_spec_json_path))
@@ -616,7 +620,7 @@ def ci_rebuild(args):
)
reports_dir = fs.join_path(os.getcwd(), "cdash_report")
if args.tests and broken_tests:
tty.warn("Unable to run stand-alone tests since listed in " "ci's 'broken-tests-packages'")
tty.warn("Unable to run stand-alone tests since listed in ci's 'broken-tests-packages'")
if cdash_handler:
msg = "Package is listed in ci's broken-tests-packages"
cdash_handler.report_skipped(job_spec, reports_dir, reason=msg)
@@ -659,7 +663,7 @@ def ci_rebuild(args):
tty.warn("No recognized test results reporting option")
else:
tty.warn("Unable to run stand-alone tests due to unsuccessful " "installation")
tty.warn("Unable to run stand-alone tests due to unsuccessful installation")
if cdash_handler:
msg = "Failed to install the package"
cdash_handler.report_skipped(job_spec, reports_dir, reason=msg)
@@ -675,7 +679,7 @@ def ci_rebuild(args):
input_spec=job_spec,
buildcache_mirror_url=buildcache_mirror_url,
pipeline_mirror_url=pipeline_mirror_url,
pr_pipeline=spack_is_pr_pipeline,
sign_binaries=sign_binaries,
):
msg = tty.msg if result.success else tty.warn
msg(
@@ -719,7 +723,7 @@ def ci_rebuild(args):
\033[34mTo reproduce this build locally, run:
spack ci reproduce-build {0} [--working-dir <dir>]
spack ci reproduce-build {0} [--working-dir <dir>] [--autostart]
If this project does not have public pipelines, you will need to first:
@@ -738,14 +742,25 @@ def ci_rebuild(args):
def ci_reproduce(args):
"""Generate instructions for reproducing the spec rebuild job.
"""generate instructions for reproducing the spec rebuild job
Artifacts of the provided gitlab pipeline rebuild job's URL will be
used to derive instructions for reproducing the build locally."""
artifacts of the provided gitlab pipeline rebuild job's URL will be used to derive
instructions for reproducing the build locally
"""
job_url = args.job_url
work_dir = args.working_dir
autostart = args.autostart
runtime = args.runtime
return spack_ci.reproduce_ci_job(job_url, work_dir)
# Allow passing GPG key for reprocuding protected CI jobs
if args.gpg_file:
gpg_key_url = url_util.path_to_file_url(args.gpg_file)
elif args.gpg_url:
gpg_key_url = args.gpg_url
else:
gpg_key_url = None
return spack_ci.reproduce_ci_job(job_url, work_dir, autostart, gpg_key_url, runtime)
def ci(parser, args):

View File

@@ -114,11 +114,7 @@ def clean(parser, args):
if args.stage:
tty.msg("Removing all temporary build stages")
spack.stage.purge()
# Temp directory where buildcaches are extracted
extract_tmp = os.path.join(spack.store.layout.root, ".tmp")
if os.path.exists(extract_tmp):
tty.debug("Removing {0}".format(extract_tmp))
shutil.rmtree(extract_tmp)
if args.downloads:
tty.msg("Removing cached downloads")
spack.caches.fetch_cache.destroy()

View File

@@ -48,7 +48,7 @@ def get_origin_info(remote):
)
except ProcessError:
origin_url = _SPACK_UPSTREAM
tty.warn("No git repository found; " "using default upstream URL: %s" % origin_url)
tty.warn("No git repository found; using default upstream URL: %s" % origin_url)
return (origin_url.strip(), branch.strip())
@@ -69,7 +69,7 @@ def clone(parser, args):
files_in_the_way = os.listdir(prefix)
if files_in_the_way:
tty.die(
"There are already files there! " "Delete these files before boostrapping spack.",
"There are already files there! Delete these files before boostrapping spack.",
*files_in_the_way,
)

View File

@@ -3,17 +3,17 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import argparse
import copy
import os
import re
import sys
from argparse import ArgumentParser, Namespace
from typing import IO, Any, Callable, Dict, Iterable, List, Optional, Sequence, Set, Tuple, Union
import llnl.util.filesystem as fs
import llnl.util.tty as tty
from llnl.util.argparsewriter import ArgparseCompletionWriter, ArgparseRstWriter, ArgparseWriter
from llnl.util.argparsewriter import ArgparseRstWriter, ArgparseWriter, Command
from llnl.util.tty.colify import colify
import spack.cmd
@@ -27,28 +27,46 @@
#: list of command formatters
formatters = {}
formatters: Dict[str, Callable[[Namespace, IO], None]] = {}
#: standard arguments for updating completion scripts
#: we iterate through these when called with --update-completion
update_completion_args = {
update_completion_args: Dict[str, Dict[str, Any]] = {
"bash": {
"aliases": True,
"format": "bash",
"header": os.path.join(spack.paths.share_path, "bash", "spack-completion.in"),
"update": os.path.join(spack.paths.share_path, "spack-completion.bash"),
}
},
"fish": {
"aliases": True,
"format": "fish",
"header": os.path.join(spack.paths.share_path, "fish", "spack-completion.in"),
"update": os.path.join(spack.paths.share_path, "spack-completion.fish"),
},
}
def formatter(func):
"""Decorator used to register formatters"""
def formatter(func: Callable[[Namespace, IO], None]) -> Callable[[Namespace, IO], None]:
"""Decorator used to register formatters.
Args:
func: Formatting function.
Returns:
The same function.
"""
formatters[func.__name__] = func
return func
def setup_parser(subparser):
def setup_parser(subparser: ArgumentParser) -> None:
"""Set up the argument parser.
Args:
subparser: Preliminary argument parser.
"""
subparser.add_argument(
"--update-completion",
action="store_true",
@@ -91,18 +109,34 @@ class SpackArgparseRstWriter(ArgparseRstWriter):
def __init__(
self,
prog,
out=None,
aliases=False,
documented_commands=[],
rst_levels=["-", "-", "^", "~", ":", "`"],
prog: str,
out: IO = sys.stdout,
aliases: bool = False,
documented_commands: Set[str] = set(),
rst_levels: Sequence[str] = ["-", "-", "^", "~", ":", "`"],
):
out = sys.stdout if out is None else out
super(SpackArgparseRstWriter, self).__init__(prog, out, aliases, rst_levels)
"""Initialize a new SpackArgparseRstWriter instance.
Args:
prog: Program name.
out: File object to write to.
aliases: Whether or not to include subparsers for aliases.
documented_commands: Set of commands with additional documentation.
rst_levels: List of characters for rst section headings.
"""
super().__init__(prog, out, aliases, rst_levels)
self.documented = documented_commands
def usage(self, *args):
string = super(SpackArgparseRstWriter, self).usage(*args)
def usage(self, usage: str) -> str:
"""Example usage of a command.
Args:
usage: Command usage.
Returns:
Usage of a command.
"""
string = super().usage(usage)
cmd = self.parser.prog.replace(" ", "-")
if cmd in self.documented:
@@ -112,11 +146,21 @@ def usage(self, *args):
class SubcommandWriter(ArgparseWriter):
def format(self, cmd):
"""Write argparse output as a list of subcommands."""
def format(self, cmd: Command) -> str:
"""Return the string representation of a single node in the parser tree.
Args:
cmd: Parsed information about a command or subcommand.
Returns:
String representation of this subcommand.
"""
return " " * self.level + cmd.prog + "\n"
_positional_to_subroutine = {
_positional_to_subroutine: Dict[str, str] = {
"package": "_all_packages",
"spec": "_all_packages",
"filter": "_all_packages",
@@ -135,10 +179,76 @@ def format(self, cmd):
}
class BashCompletionWriter(ArgparseCompletionWriter):
class BashCompletionWriter(ArgparseWriter):
"""Write argparse output as bash programmable tab completion."""
def body(self, positionals, optionals, subcommands):
def format(self, cmd: Command) -> str:
"""Return the string representation of a single node in the parser tree.
Args:
cmd: Parsed information about a command or subcommand.
Returns:
String representation of this subcommand.
"""
assert cmd.optionals # we should always at least have -h, --help
assert not (cmd.positionals and cmd.subcommands) # one or the other
# We only care about the arguments/flags, not the help messages
positionals: Tuple[str, ...] = ()
if cmd.positionals:
positionals, _, _, _ = zip(*cmd.positionals)
optionals, _, _, _, _ = zip(*cmd.optionals)
subcommands: Tuple[str, ...] = ()
if cmd.subcommands:
_, subcommands, _ = zip(*cmd.subcommands)
# Flatten lists of lists
optionals = [x for xx in optionals for x in xx]
return (
self.start_function(cmd.prog)
+ self.body(positionals, optionals, subcommands)
+ self.end_function(cmd.prog)
)
def start_function(self, prog: str) -> str:
"""Return the syntax needed to begin a function definition.
Args:
prog: Program name.
Returns:
Function definition beginning.
"""
name = prog.replace("-", "_").replace(" ", "_")
return "\n_{0}() {{".format(name)
def end_function(self, prog: str) -> str:
"""Return the syntax needed to end a function definition.
Args:
prog: Program name
Returns:
Function definition ending.
"""
return "}\n"
def body(
self, positionals: Sequence[str], optionals: Sequence[str], subcommands: Sequence[str]
) -> str:
"""Return the body of the function.
Args:
positionals: List of positional arguments.
optionals: List of optional arguments.
subcommands: List of subcommand parsers.
Returns:
Function body.
"""
if positionals:
return """
if $list_options
@@ -168,7 +278,15 @@ def body(self, positionals, optionals, subcommands):
self.optionals(optionals)
)
def positionals(self, positionals):
def positionals(self, positionals: Sequence[str]) -> str:
"""Return the syntax for reporting positional arguments.
Args:
positionals: List of positional arguments.
Returns:
Syntax for positional arguments.
"""
# If match found, return function name
for positional in positionals:
for key, value in _positional_to_subroutine.items():
@@ -178,22 +296,439 @@ def positionals(self, positionals):
# If no matches found, return empty list
return 'SPACK_COMPREPLY=""'
def optionals(self, optionals):
def optionals(self, optionals: Sequence[str]) -> str:
"""Return the syntax for reporting optional flags.
Args:
optionals: List of optional arguments.
Returns:
Syntax for optional flags.
"""
return 'SPACK_COMPREPLY="{0}"'.format(" ".join(optionals))
def subcommands(self, subcommands):
def subcommands(self, subcommands: Sequence[str]) -> str:
"""Return the syntax for reporting subcommands.
Args:
subcommands: List of subcommand parsers.
Returns:
Syntax for subcommand parsers
"""
return 'SPACK_COMPREPLY="{0}"'.format(" ".join(subcommands))
# Map argument destination names to their complete commands
# Earlier items in the list have higher precedence
_dest_to_fish_complete = {
("activate", "view"): "-f -a '(__fish_complete_directories)'",
("bootstrap root", "path"): "-f -a '(__fish_complete_directories)'",
("mirror add", "mirror"): "-f",
("repo add", "path"): "-f -a '(__fish_complete_directories)'",
("test find", "filter"): "-f -a '(__fish_spack_tests)'",
("bootstrap", "name"): "-f -a '(__fish_spack_bootstrap_names)'",
("buildcache create", "key"): "-f -a '(__fish_spack_gpg_keys)'",
("build-env", r"spec \[--\].*"): "-f -a '(__fish_spack_build_env_spec)'",
("checksum", "package"): "-f -a '(__fish_spack_packages)'",
(
"checksum",
"versions",
): "-f -a '(__fish_spack_package_versions $__fish_spack_argparse_argv[1])'",
("config", "path"): "-f -a '(__fish_spack_colon_path)'",
("config", "section"): "-f -a '(__fish_spack_config_sections)'",
("develop", "specs?"): "-f -k -a '(__fish_spack_specs_or_id)'",
("diff", "specs?"): "-f -a '(__fish_spack_installed_specs)'",
("gpg sign", "output"): "-f -a '(__fish_complete_directories)'",
("gpg", "keys?"): "-f -a '(__fish_spack_gpg_keys)'",
("graph", "specs?"): "-f -k -a '(__fish_spack_specs_or_id)'",
("help", "help_command"): "-f -a '(__fish_spack_commands)'",
("list", "filter"): "-f -a '(__fish_spack_packages)'",
("mirror", "mirror"): "-f -a '(__fish_spack_mirrors)'",
("pkg", "package"): "-f -a '(__fish_spack_pkg_packages)'",
("remove", "specs?"): "-f -a '(__fish_spack_installed_specs)'",
("repo", "namespace_or_path"): "$__fish_spack_force_files -a '(__fish_spack_repos)'",
("restage", "specs?"): "-f -k -a '(__fish_spack_specs_or_id)'",
("rm", "specs?"): "-f -a '(__fish_spack_installed_specs)'",
("solve", "specs?"): "-f -k -a '(__fish_spack_specs_or_id)'",
("spec", "specs?"): "-f -k -a '(__fish_spack_specs_or_id)'",
("stage", "specs?"): "-f -k -a '(__fish_spack_specs_or_id)'",
("test-env", r"spec \[--\].*"): "-f -a '(__fish_spack_build_env_spec)'",
("test", r"\[?name.*"): "-f -a '(__fish_spack_tests)'",
("undevelop", "specs?"): "-f -k -a '(__fish_spack_specs_or_id)'",
("verify", "specs_or_files"): "$__fish_spack_force_files -a '(__fish_spack_installed_specs)'",
("view", "path"): "-f -a '(__fish_complete_directories)'",
("", "comment"): "-f",
("", "compiler_spec"): "-f -a '(__fish_spack_installed_compilers)'",
("", "config_scopes"): "-f -a '(__fish_complete_directories)'",
("", "extendable"): "-f -a '(__fish_spack_extensions)'",
("", "installed_specs?"): "-f -a '(__fish_spack_installed_specs)'",
("", "job_url"): "-f",
("", "location_env"): "-f -a '(__fish_complete_directories)'",
("", "pytest_args"): "-f -a '(__fish_spack_unit_tests)'",
("", "package_or_file"): "$__fish_spack_force_files -a '(__fish_spack_packages)'",
("", "package_or_user"): "-f -a '(__fish_spack_packages)'",
("", "package"): "-f -a '(__fish_spack_packages)'",
("", "PKG"): "-f -a '(__fish_spack_packages)'",
("", "prefix"): "-f -a '(__fish_complete_directories)'",
("", r"rev\d?"): "-f -a '(__fish_spack_git_rev)'",
("", "specs?"): "-f -k -a '(__fish_spack_specs)'",
("", "tags?"): "-f -a '(__fish_spack_tags)'",
("", "virtual_package"): "-f -a '(__fish_spack_providers)'",
("", "working_dir"): "-f -a '(__fish_complete_directories)'",
("", r"(\w*_)?env"): "-f -a '(__fish_spack_environments)'",
("", r"(\w*_)?dir(ectory)?"): "-f -a '(__fish_spack_environments)'",
("", r"(\w*_)?mirror_name"): "-f -a '(__fish_spack_mirrors)'",
}
def _fish_dest_get_complete(prog: str, dest: str) -> Optional[str]:
"""Map from subcommand to autocompletion argument.
Args:
prog: Program name.
dest: Destination.
Returns:
Autocompletion argument.
"""
s = prog.split(None, 1)
subcmd = s[1] if len(s) == 2 else ""
for (prog_key, pos_key), value in _dest_to_fish_complete.items():
if subcmd.startswith(prog_key) and re.match("^" + pos_key + "$", dest):
return value
return None
class FishCompletionWriter(ArgparseWriter):
"""Write argparse output as bash programmable tab completion."""
def format(self, cmd: Command) -> str:
"""Return the string representation of a single node in the parser tree.
Args:
cmd: Parsed information about a command or subcommand.
Returns:
String representation of a node.
"""
assert cmd.optionals # we should always at least have -h, --help
assert not (cmd.positionals and cmd.subcommands) # one or the other
# We also need help messages and how arguments are used
# So we pass everything to completion writer
positionals = cmd.positionals
optionals = cmd.optionals
subcommands = cmd.subcommands
return (
self.prog_comment(cmd.prog)
+ self.optspecs(cmd.prog, optionals)
+ self.complete(cmd.prog, positionals, optionals, subcommands)
)
def _quote(self, string: str) -> str:
"""Quote string and escape special characters if necessary.
Args:
string: Input string.
Returns:
Quoted string.
"""
# Goal here is to match fish_indent behavior
# Strings without spaces (or other special characters) do not need to be escaped
if not any([sub in string for sub in [" ", "'", '"']]):
return string
string = string.replace("'", r"\'")
return f"'{string}'"
def optspecs(
self,
prog: str,
optionals: List[Tuple[Sequence[str], List[str], str, Union[int, str, None], str]],
) -> str:
"""Read the optionals and return the command to set optspec.
Args:
prog: Program name.
optionals: List of optional arguments.
Returns:
Command to set optspec variable.
"""
# Variables of optspecs
optspec_var = "__fish_spack_optspecs_" + prog.replace(" ", "_").replace("-", "_")
if optionals is None:
return "set -g %s\n" % optspec_var
# Build optspec by iterating over options
args = []
for flags, dest, _, nargs, _ in optionals:
if len(flags) == 0:
continue
required = ""
# Because nargs '?' is treated differently in fish, we treat it as required.
# Because multi-argument options are not supported, we treat it like one argument.
required = "="
if nargs == 0:
required = ""
# Pair short options with long options
# We need to do this because fish doesn't support multiple short
# or long options.
# However, since we are paring options only, this is fine
short = [f[1:] for f in flags if f.startswith("-") and len(f) == 2]
long = [f[2:] for f in flags if f.startswith("--")]
while len(short) > 0 and len(long) > 0:
arg = "%s/%s%s" % (short.pop(), long.pop(), required)
while len(short) > 0:
arg = "%s/%s" % (short.pop(), required)
while len(long) > 0:
arg = "%s%s" % (long.pop(), required)
args.append(arg)
# Even if there is no option, we still set variable.
# In fish such variable is an empty array, we use it to
# indicate that such subcommand exists.
args = " ".join(args)
return "set -g %s %s\n" % (optspec_var, args)
@staticmethod
def complete_head(
prog: str, index: Optional[int] = None, nargs: Optional[Union[int, str]] = None
) -> str:
"""Return the head of the completion command.
Args:
prog: Program name.
index: Index of positional argument.
nargs: Number of arguments.
Returns:
Head of the completion command.
"""
# Split command and subcommand
s = prog.split(None, 1)
subcmd = s[1] if len(s) == 2 else ""
if index is None:
return "complete -c %s -n '__fish_spack_using_command %s'" % (s[0], subcmd)
elif nargs in [argparse.ZERO_OR_MORE, argparse.ONE_OR_MORE, argparse.REMAINDER]:
head = "complete -c %s -n '__fish_spack_using_command_pos_remainder %d %s'"
else:
head = "complete -c %s -n '__fish_spack_using_command_pos %d %s'"
return head % (s[0], index, subcmd)
def complete(
self,
prog: str,
positionals: List[Tuple[str, Optional[Iterable[Any]], Union[int, str, None], str]],
optionals: List[Tuple[Sequence[str], List[str], str, Union[int, str, None], str]],
subcommands: List[Tuple[ArgumentParser, str, str]],
) -> str:
"""Return all the completion commands.
Args:
prog: Program name.
positionals: List of positional arguments.
optionals: List of optional arguments.
subcommands: List of subcommand parsers.
Returns:
Completion command.
"""
commands = []
if positionals:
commands.append(self.positionals(prog, positionals))
if subcommands:
commands.append(self.subcommands(prog, subcommands))
if optionals:
commands.append(self.optionals(prog, optionals))
return "".join(commands)
def positionals(
self,
prog: str,
positionals: List[Tuple[str, Optional[Iterable[Any]], Union[int, str, None], str]],
) -> str:
"""Return the completion for positional arguments.
Args:
prog: Program name.
positionals: List of positional arguments.
Returns:
Completion command.
"""
commands = []
for idx, (args, choices, nargs, help) in enumerate(positionals):
# Make sure we always get same order of output
if isinstance(choices, dict):
choices = sorted(choices.keys())
elif isinstance(choices, (set, frozenset)):
choices = sorted(choices)
# Remove platform-specific choices to avoid hard-coding the platform.
if choices is not None:
valid_choices = []
for choice in choices:
if spack.platforms.host().name not in choice:
valid_choices.append(choice)
choices = valid_choices
head = self.complete_head(prog, idx, nargs)
if choices is not None:
# If there are choices, we provide a completion for all possible values.
commands.append(head + " -f -a %s" % self._quote(" ".join(choices)))
else:
# Otherwise, we try to find a predefined completion for it
value = _fish_dest_get_complete(prog, args)
if value is not None:
commands.append(head + " " + value)
return "\n".join(commands) + "\n"
def prog_comment(self, prog: str) -> str:
"""Return a comment line for the command.
Args:
prog: Program name.
Returns:
Comment line.
"""
return "\n# %s\n" % prog
def optionals(
self,
prog: str,
optionals: List[Tuple[Sequence[str], List[str], str, Union[int, str, None], str]],
) -> str:
"""Return the completion for optional arguments.
Args:
prog: Program name.
optionals: List of optional arguments.
Returns:
Completion command.
"""
commands = []
head = self.complete_head(prog)
for flags, dest, _, nargs, help in optionals:
# Make sure we always get same order of output
if isinstance(dest, dict):
dest = sorted(dest.keys())
elif isinstance(dest, (set, frozenset)):
dest = sorted(dest)
# Remove platform-specific choices to avoid hard-coding the platform.
if dest is not None:
valid_choices = []
for choice in dest:
if spack.platforms.host().name not in choice:
valid_choices.append(choice)
dest = valid_choices
# To provide description for optionals, and also possible values,
# we need to use two split completion command.
# Otherwise, each option will have same description.
prefix = head
# Add all flags to the completion
for f in flags:
if f.startswith("--"):
long = f[2:]
prefix += " -l %s" % long
elif f.startswith("-"):
short = f[1:]
assert len(short) == 1
prefix += " -s %s" % short
# Check if option require argument.
# Currently multi-argument options are not supported, so we treat it like one argument.
if nargs != 0:
prefix += " -r"
if dest is not None:
# If there are choices, we provide a completion for all possible values.
commands.append(prefix + " -f -a %s" % self._quote(" ".join(dest)))
else:
# Otherwise, we try to find a predefined completion for it
value = _fish_dest_get_complete(prog, dest)
if value is not None:
commands.append(prefix + " " + value)
if help:
commands.append(prefix + " -d %s" % self._quote(help))
return "\n".join(commands) + "\n"
def subcommands(self, prog: str, subcommands: List[Tuple[ArgumentParser, str, str]]) -> str:
"""Return the completion for subcommands.
Args:
prog: Program name.
subcommands: List of subcommand parsers.
Returns:
Completion command.
"""
commands = []
head = self.complete_head(prog, 0)
for _, subcommand, help in subcommands:
command = head + " -f -a %s" % self._quote(subcommand)
if help is not None and len(help) > 0:
help = help.split("\n")[0]
command += " -d %s" % self._quote(help)
commands.append(command)
return "\n".join(commands) + "\n"
@formatter
def subcommands(args, out):
def subcommands(args: Namespace, out: IO) -> None:
"""Hierarchical tree of subcommands.
args:
args: Command-line arguments.
out: File object to write to.
"""
parser = spack.main.make_argument_parser()
spack.main.add_all_commands(parser)
writer = SubcommandWriter(parser.prog, out, args.aliases)
writer.write(parser)
def rst_index(out):
def rst_index(out: IO) -> None:
"""Generate an index of all commands.
Args:
out: File object to write to.
"""
out.write("\n")
index = spack.main.index_commands()
@@ -221,13 +756,19 @@ def rst_index(out):
@formatter
def rst(args, out):
def rst(args: Namespace, out: IO) -> None:
"""ReStructuredText documentation of subcommands.
args:
args: Command-line arguments.
out: File object to write to.
"""
# create a parser with all commands
parser = spack.main.make_argument_parser()
spack.main.add_all_commands(parser)
# extract cross-refs of the form `_cmd-spack-<cmd>:` from rst files
documented_commands = set()
documented_commands: Set[str] = set()
for filename in args.rst_files:
with open(filename) as f:
for line in f:
@@ -245,7 +786,13 @@ def rst(args, out):
@formatter
def names(args, out):
def names(args: Namespace, out: IO) -> None:
"""Simple list of top-level commands.
args:
args: Command-line arguments.
out: File object to write to.
"""
commands = copy.copy(spack.cmd.all_commands())
if args.aliases:
@@ -255,7 +802,13 @@ def names(args, out):
@formatter
def bash(args, out):
def bash(args: Namespace, out: IO) -> None:
"""Bash tab-completion script.
args:
args: Command-line arguments.
out: File object to write to.
"""
parser = spack.main.make_argument_parser()
spack.main.add_all_commands(parser)
@@ -263,7 +816,22 @@ def bash(args, out):
writer.write(parser)
def prepend_header(args, out):
@formatter
def fish(args, out):
parser = spack.main.make_argument_parser()
spack.main.add_all_commands(parser)
writer = FishCompletionWriter(parser.prog, out, args.aliases)
writer.write(parser)
def prepend_header(args: Namespace, out: IO) -> None:
"""Prepend header text at the beginning of a file.
Args:
args: Command-line arguments.
out: File object to write to.
"""
if not args.header:
return
@@ -271,10 +839,14 @@ def prepend_header(args, out):
out.write(header.read())
def _commands(parser, args):
def _commands(parser: ArgumentParser, args: Namespace) -> None:
"""This is the 'regular' command, which can be called multiple times.
See ``commands()`` below for ``--update-completion`` handling.
Args:
parser: Argument parser.
args: Command-line arguments.
"""
formatter = formatters[args.format]
@@ -296,12 +868,15 @@ def _commands(parser, args):
formatter(args, sys.stdout)
def update_completion(parser, args):
def update_completion(parser: ArgumentParser, args: Namespace) -> None:
"""Iterate through the shells and update the standard completion files.
This is a convenience method to avoid calling this command many
times, and to simplify completion update for developers.
Args:
parser: Argument parser.
args: Command-line arguments.
"""
for shell, shell_args in update_completion_args.items():
for attr, value in shell_args.items():
@@ -309,14 +884,20 @@ def update_completion(parser, args):
_commands(parser, args)
def commands(parser, args):
def commands(parser: ArgumentParser, args: Namespace) -> None:
"""Main function that calls formatter functions.
Args:
parser: Argument parser.
args: Command-line arguments.
"""
if args.update_completion:
if args.format != "names" or any([args.aliases, args.update, args.header]):
tty.die("--update-completion can only be specified alone.")
# this runs the command multiple times with different arguments
return update_completion(parser, args)
update_completion(parser, args)
else:
# run commands normally
return _commands(parser, args)
_commands(parser, args)

View File

@@ -36,7 +36,10 @@ def shell_init_instructions(cmd, equivalent):
" source %s/setup-env.fish" % spack.paths.share_path,
"",
color.colorize("@*c{For Windows batch:}"),
" source %s/spack_cmd.bat" % spack.paths.share_path,
" %s\\spack_cmd.bat" % spack.paths.bin_path,
"",
color.colorize("@*c{For PowerShell:}"),
" %s\\setup-env.ps1" % spack.paths.share_path,
"",
"Or, if you do not want to use shell support, run "
+ ("one of these" if shell_specific else "this")
@@ -50,6 +53,7 @@ def shell_init_instructions(cmd, equivalent):
equivalent.format(sh_arg="--csh ") + " # csh/tcsh",
equivalent.format(sh_arg="--fish") + " # fish",
equivalent.format(sh_arg="--bat ") + " # batch",
equivalent.format(sh_arg="--pwsh") + " # powershell",
]
else:
msg += [" " + equivalent]

View File

@@ -82,12 +82,12 @@ def _specs(self, **kwargs):
# return everything for an empty query.
if not qspecs:
return spack.store.db.query(**kwargs)
return spack.store.STORE.db.query(**kwargs)
# Return only matching stuff otherwise.
specs = {}
for spec in qspecs:
for s in spack.store.db.query(spec, **kwargs):
for s in spack.store.STORE.db.query(spec, **kwargs):
# This is fast for already-concrete specs
specs[s.dag_hash()] = s
@@ -265,7 +265,7 @@ def recurse_dependents():
"--dependents",
action="store_true",
dest="dependents",
help="also uninstall any packages that depend on the ones given " "via command line",
help="also uninstall any packages that depend on the ones given via command line",
)
@@ -286,7 +286,7 @@ def deptype():
"--deptype",
action=DeptypeAction,
default=dep.all_deptypes,
help="comma-separated list of deptypes to traverse\ndefault=%s"
help="comma-separated list of deptypes to traverse\n\ndefault=%s"
% ",".join(dep.all_deptypes),
)
@@ -331,6 +331,17 @@ def tags():
)
@arg
def namespaces():
return Args(
"-N",
"--namespaces",
action="store_true",
default=False,
help="show fully qualified package names",
)
@arg
def jobs():
return Args(
@@ -349,14 +360,25 @@ def install_status():
"-I",
"--install-status",
action="store_true",
default=False,
help="show install status of packages. packages can be: "
default=True,
help="show install status of packages\n\npackages can be: "
"installed [+], missing and needed by an installed package [-], "
"installed in and upstream instance [^], "
"installed in an upstream instance [^], "
"or not installed (no annotation)",
)
@arg
def no_install_status():
return Args(
"--no-install-status",
dest="install_status",
action="store_false",
default=True,
help="do not show install status annotations",
)
@arg
def no_checksum():
return Args(
@@ -382,24 +404,23 @@ def add_cdash_args(subparser, add_help):
cdash_help = {}
if add_help:
cdash_help["upload-url"] = "CDash URL where reports will be uploaded"
cdash_help[
"build"
] = """The name of the build that will be reported to CDash.
Defaults to spec of the package to operate on."""
cdash_help[
"site"
] = """The site name that will be reported to CDash.
Defaults to current system hostname."""
cdash_help[
"track"
] = """Results will be reported to this group on CDash.
Defaults to Experimental."""
cdash_help[
"buildstamp"
] = """Instead of letting the CDash reporter prepare the
buildstamp which, when combined with build name, site and project,
uniquely identifies the build, provide this argument to identify
the build yourself. Format: %%Y%%m%%d-%%H%%M-[cdash-track]"""
cdash_help["build"] = (
"name of the build that will be reported to CDash\n\n"
"defaults to spec of the package to operate on"
)
cdash_help["site"] = (
"site name that will be reported to CDash\n\n" "defaults to current system hostname"
)
cdash_help["track"] = (
"results will be reported to this group on CDash\n\n" "defaults to Experimental"
)
cdash_help["buildstamp"] = (
"use custom buildstamp\n\n"
"instead of letting the CDash reporter prepare the "
"buildstamp which, when combined with build name, site and project, "
"uniquely identifies the build, provide this argument to identify "
"the build yourself. format: %%Y%%m%%d-%%H%%M-[cdash-track]"
)
else:
cdash_help["upload-url"] = argparse.SUPPRESS
cdash_help["build"] = argparse.SUPPRESS
@@ -468,7 +489,7 @@ def __init__(
# substituting '_' for ':'.
dest = dest.replace(":", "_")
super(ConfigSetAction, self).__init__(
super().__init__(
option_strings=option_strings,
dest=dest,
nargs=0,
@@ -531,16 +552,16 @@ def add_s3_connection_args(subparser, add_help):
"--s3-access-key-id", help="ID string to use to connect to this S3 mirror"
)
subparser.add_argument(
"--s3-access-key-secret", help="Secret string to use to connect to this S3 mirror"
"--s3-access-key-secret", help="secret string to use to connect to this S3 mirror"
)
subparser.add_argument(
"--s3-access-token", help="Access Token to use to connect to this S3 mirror"
"--s3-access-token", help="access token to use to connect to this S3 mirror"
)
subparser.add_argument(
"--s3-profile", help="S3 profile name to use to connect to this S3 mirror", default=None
)
subparser.add_argument(
"--s3-endpoint-url", help="Endpoint URL to use to connect to this S3 mirror"
"--s3-endpoint-url", help="endpoint URL to use to connect to this S3 mirror"
)

View File

@@ -2,8 +2,6 @@
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import argparse
import os
@@ -108,7 +106,7 @@ def emulate_env_utility(cmd_name, context, args):
visitor = AreDepsInstalledVisitor(context=context)
# Mass install check needs read transaction.
with spack.store.db.read_transaction():
with spack.store.STORE.db.read_transaction():
traverse.traverse_breadth_first_with_visitor([spec], traverse.CoverNodesVisitor(visitor))
if visitor.has_uninstalled_deps:

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import argparse
import sys
@@ -53,7 +51,7 @@ def setup_parser(subparser):
"--scope",
choices=scopes,
metavar=scopes_metavar,
default=spack.config.default_modify_scope("compilers"),
default=None,
help="configuration scope to modify",
)
@@ -106,19 +104,21 @@ def compiler_find(args):
def compiler_remove(args):
cspec = spack.spec.CompilerSpec(args.compiler_spec)
compilers = spack.compilers.compilers_for_spec(cspec, scope=args.scope)
if not compilers:
tty.die("No compilers match spec %s" % cspec)
elif not args.all and len(compilers) > 1:
tty.error("Multiple compilers match spec %s. Choose one:" % cspec)
colify(reversed(sorted([c.spec.display_str for c in compilers])), indent=4)
compiler_spec = spack.spec.CompilerSpec(args.compiler_spec)
candidate_compilers = spack.compilers.compilers_for_spec(compiler_spec, scope=args.scope)
if not candidate_compilers:
tty.die("No compilers match spec %s" % compiler_spec)
if not args.all and len(candidate_compilers) > 1:
tty.error(f"Multiple compilers match spec {compiler_spec}. Choose one:")
colify(reversed(sorted([c.spec.display_str for c in candidate_compilers])), indent=4)
tty.msg("Or, use `spack compiler remove -a` to remove all of them.")
sys.exit(1)
for compiler in compilers:
spack.compilers.remove_compiler_from_config(compiler.spec, scope=args.scope)
tty.msg("Removed compiler %s" % compiler.spec.display_str)
for current_compiler in candidate_compilers:
spack.compilers.remove_compiler_from_config(current_compiler.spec, scope=args.scope)
tty.msg(f"{current_compiler.spec.display_str} has been removed")
def compiler_info(args):

View File

@@ -14,18 +14,16 @@
def setup_parser(subparser):
subparser.add_argument(
"-f", "--force", action="store_true", help="Re-concretize even if already concretized."
"-f", "--force", action="store_true", help="re-concretize even if already concretized"
)
subparser.add_argument(
"--test",
default=None,
choices=["root", "all"],
help="""Concretize with test dependencies. When 'root' is chosen, test
dependencies are only added for the environment's root specs. When 'all' is
chosen, test dependencies are enabled for all packages in the environment.""",
help="concretize with test dependencies of only root packages or all packages",
)
subparser.add_argument(
"-q", "--quiet", action="store_true", help="Don't print concretized specs"
"-q", "--quiet", action="store_true", help="don't print concretized specs"
)
spack.cmd.common.arguments.add_concretizer_args(subparser)

View File

@@ -2,8 +2,6 @@
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import collections
import os
import shutil
@@ -44,7 +42,7 @@ def setup_parser(subparser):
get_parser = sp.add_parser("get", help="print configuration values")
get_parser.add_argument(
"section",
help="configuration section to print. " "options: %(choices)s",
help="configuration section to print\n\noptions: %(choices)s",
nargs="?",
metavar="section",
choices=spack.config.section_schemas,
@@ -55,7 +53,7 @@ def setup_parser(subparser):
)
blame_parser.add_argument(
"section",
help="configuration section to print. " "options: %(choices)s",
help="configuration section to print\n\noptions: %(choices)s",
metavar="section",
choices=spack.config.section_schemas,
)
@@ -63,7 +61,7 @@ def setup_parser(subparser):
edit_parser = sp.add_parser("edit", help="edit configuration file")
edit_parser.add_argument(
"section",
help="configuration section to edit. " "options: %(choices)s",
help="configuration section to edit\n\noptions: %(choices)s",
metavar="section",
nargs="?",
choices=spack.config.section_schemas,
@@ -78,7 +76,7 @@ def setup_parser(subparser):
add_parser.add_argument(
"path",
nargs="?",
help="colon-separated path to config that should be added," " e.g. 'config:default:true'",
help="colon-separated path to config that should be added, e.g. 'config:default:true'",
)
add_parser.add_argument("-f", "--file", help="file from which to set all config values")
@@ -90,7 +88,7 @@ def setup_parser(subparser):
"--local",
action="store_true",
default=False,
help="Set packages preferences based on local installs, rather " "than upstream.",
help="set packages preferences based on local installs, rather than upstream",
)
remove_parser = sp.add_parser("remove", aliases=["rm"], help="remove configuration parameters")
@@ -159,7 +157,7 @@ def config_get(args):
tty.die("environment has no %s file" % ev.manifest_name)
else:
tty.die("`spack config get` requires a section argument " "or an active environment.")
tty.die("`spack config get` requires a section argument or an active environment.")
def config_blame(args):
@@ -182,7 +180,7 @@ def config_edit(args):
# If we aren't editing a spack.yaml file, get config path from scope.
scope, section = _get_scope_and_section(args)
if not scope and not section:
tty.die("`spack config edit` requires a section argument " "or an active environment.")
tty.die("`spack config edit` requires a section argument or an active environment.")
config_file = spack.config.config.get_config_filename(scope, section)
if args.print_file:
@@ -376,7 +374,7 @@ def config_revert(args):
proceed = True
if not args.yes_to_all:
msg = "The following scopes will be restored from the corresponding" " backup files:\n"
msg = "The following scopes will be restored from the corresponding backup files:\n"
for entry in to_be_restored:
msg += "\t[scope={0.scope}, bkp={0.bkp}]\n".format(entry)
msg += "This operation cannot be undone."
@@ -401,8 +399,8 @@ def config_prefer_upstream(args):
if scope is None:
scope = spack.config.default_modify_scope("packages")
all_specs = set(spack.store.db.query(installed=True))
local_specs = set(spack.store.db.query_local(installed=True))
all_specs = set(spack.store.STORE.db.query(installed=True))
local_specs = set(spack.store.STORE.db.query_local(installed=True))
pref_specs = local_specs if args.local else all_specs - local_specs
conflicting_variants = set()

View File

@@ -10,7 +10,7 @@
import spack.container
import spack.container.images
description = "creates recipes to build images for different" " container runtimes"
description = "creates recipes to build images for different container runtimes"
section = "container"
level = "long"

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import os
import re
import urllib.parse
@@ -19,6 +17,7 @@
from spack.url import UndetectableNameError, UndetectableVersionError, parse_name, parse_version
from spack.util.editor import editor
from spack.util.executable import ProcessError, which
from spack.util.format import get_version_lines
from spack.util.naming import mod_to_class, simplify_name, valid_fully_qualified_module_name
description = "create a new package file"
@@ -71,7 +70,7 @@ class {class_name}({base_class_name}):
'''
class BundlePackageTemplate(object):
class BundlePackageTemplate:
"""
Provides the default values to be used for a bundle package file template.
"""
@@ -122,7 +121,7 @@ def install(self, spec, prefix):
url_line = ' url = "{url}"'
def __init__(self, name, url, versions):
super(PackageTemplate, self).__init__(name, versions)
super().__init__(name, versions)
self.url_def = self.url_line.format(url=url)
@@ -200,7 +199,7 @@ def __init__(self, name, url, *args, **kwargs):
# Make it more obvious that we are renaming the package
tty.msg("Changing package name from {0} to lua-{0}".format(name))
name = "lua-{0}".format(name)
super(LuaPackageTemplate, self).__init__(name, url, *args, **kwargs)
super().__init__(name, url, *args, **kwargs)
class MesonPackageTemplate(PackageTemplate):
@@ -308,7 +307,7 @@ def __init__(self, name, url, *args, **kwargs):
tty.msg("Changing package name from {0} to rkt-{0}".format(name))
name = "rkt-{0}".format(name)
self.body_def = self.body_def.format(name[4:])
super(RacketPackageTemplate, self).__init__(name, url, *args, **kwargs)
super().__init__(name, url, *args, **kwargs)
class PythonPackageTemplate(PackageTemplate):
@@ -327,6 +326,7 @@ class PythonPackageTemplate(PackageTemplate):
# FIXME: Add a build backend, usually defined in pyproject.toml. If no such file
# exists, use setuptools.
# depends_on("py-setuptools", type="build")
# depends_on("py-hatchling", type="build")
# depends_on("py-flit-core", type="build")
# depends_on("py-poetry-core", type="build")
@@ -334,17 +334,11 @@ class PythonPackageTemplate(PackageTemplate):
# depends_on("py-foo", type=("build", "run"))"""
body_def = """\
def global_options(self, spec, prefix):
# FIXME: Add options to pass to setup.py
def config_settings(self, spec, prefix):
# FIXME: Add configuration settings to be passed to the build backend
# FIXME: If not needed, delete this function
options = []
return options
def install_options(self, spec, prefix):
# FIXME: Add options to pass to setup.py install
# FIXME: If not needed, delete this function
options = []
return options"""
settings = {}
return settings"""
def __init__(self, name, url, *args, **kwargs):
# If the user provided `--name py-numpy`, don't rename it py-py-numpy
@@ -400,7 +394,7 @@ def __init__(self, name, url, *args, **kwargs):
+ self.url_line
)
super(PythonPackageTemplate, self).__init__(name, url, *args, **kwargs)
super().__init__(name, url, *args, **kwargs)
class RPackageTemplate(PackageTemplate):
@@ -439,7 +433,7 @@ def __init__(self, name, url, *args, **kwargs):
if bioc:
self.url_line = ' url = "{0}"\n' ' bioc = "{1}"'.format(url, r_name)
super(RPackageTemplate, self).__init__(name, url, *args, **kwargs)
super().__init__(name, url, *args, **kwargs)
class PerlmakePackageTemplate(PackageTemplate):
@@ -466,7 +460,7 @@ def __init__(self, name, *args, **kwargs):
tty.msg("Changing package name from {0} to perl-{0}".format(name))
name = "perl-{0}".format(name)
super(PerlmakePackageTemplate, self).__init__(name, *args, **kwargs)
super().__init__(name, *args, **kwargs)
class PerlbuildPackageTemplate(PerlmakePackageTemplate):
@@ -499,7 +493,7 @@ def __init__(self, name, *args, **kwargs):
tty.msg("Changing package name from {0} to octave-{0}".format(name))
name = "octave-{0}".format(name)
super(OctavePackageTemplate, self).__init__(name, *args, **kwargs)
super().__init__(name, *args, **kwargs)
class RubyPackageTemplate(PackageTemplate):
@@ -527,7 +521,7 @@ def __init__(self, name, *args, **kwargs):
tty.msg("Changing package name from {0} to ruby-{0}".format(name))
name = "ruby-{0}".format(name)
super(RubyPackageTemplate, self).__init__(name, *args, **kwargs)
super().__init__(name, *args, **kwargs)
class MakefilePackageTemplate(PackageTemplate):
@@ -572,7 +566,7 @@ def __init__(self, name, *args, **kwargs):
tty.msg("Changing package name from {0} to py-{0}".format(name))
name = "py-{0}".format(name)
super(SIPPackageTemplate, self).__init__(name, *args, **kwargs)
super().__init__(name, *args, **kwargs)
templates = {
@@ -614,7 +608,7 @@ def setup_parser(subparser):
"--template",
metavar="TEMPLATE",
choices=sorted(templates.keys()),
help="build system template to use. options: %(choices)s",
help="build system template to use\n\noptions: %(choices)s",
)
subparser.add_argument(
"-r", "--repo", help="path to a repository where the package should be created"
@@ -622,7 +616,7 @@ def setup_parser(subparser):
subparser.add_argument(
"-N",
"--namespace",
help="specify a namespace for the package. must be the namespace of "
help="specify a namespace for the package\n\nmust be the namespace of "
"a repository registered with Spack",
)
subparser.add_argument(
@@ -715,7 +709,7 @@ def __call__(self, stage, url):
output = tar("--exclude=*/*/*", "-tf", stage.archive_file, output=str)
except ProcessError:
output = ""
lines = output.split("\n")
lines = output.splitlines()
# Determine the build system based on the files contained
# in the archive.
@@ -839,13 +833,15 @@ def get_versions(args, name):
version = parse_version(args.url)
url_dict = {version: args.url}
versions = spack.stage.get_checksums_for_versions(
version_hashes = spack.stage.get_checksums_for_versions(
url_dict,
name,
first_stage_function=guesser,
keep_stage=args.keep_stage,
batch=(args.batch or len(url_dict) == 1),
)
versions = get_version_lines(version_hashes, url_dict)
else:
versions = unhashed_versions
@@ -880,7 +876,7 @@ def get_build_system(template, url, guesser):
# Use whatever build system the guesser detected
selected_template = guesser.build_system
if selected_template == "generic":
tty.warn("Unable to detect a build system. " "Using a generic package template.")
tty.warn("Unable to detect a build system. Using a generic package template.")
else:
msg = "This package looks like it uses the {0} build system"
tty.msg(msg.format(selected_template))

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import os
import platform
import re
@@ -62,16 +60,16 @@ def create_db_tarball(args):
tarball_name = "spack-db.%s.tar.gz" % _debug_tarball_suffix()
tarball_path = os.path.abspath(tarball_name)
base = os.path.basename(str(spack.store.root))
base = os.path.basename(str(spack.store.STORE.root))
transform_args = []
if "GNU" in tar("--version", output=str):
transform_args = ["--transform", "s/^%s/%s/" % (base, tarball_name)]
else:
transform_args = ["-s", "/^%s/%s/" % (base, tarball_name)]
wd = os.path.dirname(str(spack.store.root))
wd = os.path.dirname(str(spack.store.STORE.root))
with working_dir(wd):
files = [spack.store.db._index_path]
files = [spack.store.STORE.db._index_path]
files += glob("%s/*/*/*/.spack/spec.json" % base)
files += glob("%s/*/*/*/.spack/spec.yaml" % base)
files = [os.path.relpath(f) for f in files]

View File

@@ -26,8 +26,8 @@ def setup_parser(subparser):
"--installed",
action="store_true",
default=False,
help="List installed dependencies of an installed spec, "
"instead of possible dependencies of a package.",
help="list installed dependencies of an installed spec "
"instead of possible dependencies of a package",
)
subparser.add_argument(
"-t",
@@ -60,7 +60,7 @@ def dependencies(parser, args):
format_string = "{name}{@version}{%compiler}{/hash:7}"
if sys.stdout.isatty():
tty.msg("Dependencies of %s" % spec.format(format_string, color=True))
deps = spack.store.db.installed_relatives(
deps = spack.store.STORE.db.installed_relatives(
spec, "children", args.transitive, deptype=args.deptype
)
if deps:

View File

@@ -25,15 +25,15 @@ def setup_parser(subparser):
"--installed",
action="store_true",
default=False,
help="List installed dependents of an installed spec, "
"instead of possible dependents of a package.",
help="list installed dependents of an installed spec "
"instead of possible dependents of a package",
)
subparser.add_argument(
"-t",
"--transitive",
action="store_true",
default=False,
help="Show all transitive dependents.",
help="show all transitive dependents",
)
arguments.add_common_arguments(subparser, ["spec"])
@@ -96,7 +96,7 @@ def dependents(parser, args):
format_string = "{name}{@version}{%compiler}{/hash:7}"
if sys.stdout.isatty():
tty.msg("Dependents of %s" % spec.cformat(format_string))
deps = spack.store.db.installed_relatives(spec, "parents", args.transitive)
deps = spack.store.STORE.db.installed_relatives(spec, "parents", args.transitive)
if deps:
spack.cmd.display_specs(deps, long=True)
else:

View File

@@ -13,8 +13,6 @@
It is up to the user to ensure binary compatibility between the deprecated
installation and its deprecator.
"""
from __future__ import print_function
import argparse
import os
@@ -28,7 +26,7 @@
from spack.database import InstallStatuses
from spack.error import SpackError
description = "Replace one package with another via symlinks"
description = "replace one package with another via symlinks"
section = "admin"
level = "long"
@@ -48,7 +46,7 @@ def setup_parser(sp):
action="store_true",
default=True,
dest="dependencies",
help="Deprecate dependencies (default)",
help="deprecate dependencies (default)",
)
deps.add_argument(
"-D",
@@ -56,7 +54,7 @@ def setup_parser(sp):
action="store_false",
default=True,
dest="dependencies",
help="Do not deprecate dependencies",
help="do not deprecate dependencies",
)
install = sp.add_mutually_exclusive_group()
@@ -66,7 +64,7 @@ def setup_parser(sp):
action="store_true",
default=False,
dest="install",
help="Concretize and install deprecator spec",
help="concretize and install deprecator spec",
)
install.add_argument(
"-I",
@@ -74,7 +72,7 @@ def setup_parser(sp):
action="store_false",
default=False,
dest="install",
help="Deprecator spec must already be installed (default)",
help="deprecator spec must already be installed (default)",
)
sp.add_argument(
@@ -83,7 +81,7 @@ def setup_parser(sp):
type=str,
default="soft",
choices=["soft", "hard"],
help="Type of filesystem link to use for deprecation (default soft)",
help="type of filesystem link to use for deprecation (default soft)",
)
sp.add_argument(
@@ -132,7 +130,7 @@ def deprecate(parser, args):
already_deprecated = []
already_deprecated_for = []
for spec in all_deprecate:
deprecated_for = spack.store.db.deprecator(spec)
deprecated_for = spack.store.STORE.db.deprecator(spec)
if deprecated_for:
already_deprecated.append(spec)
already_deprecated_for.append(deprecated_for)

View File

@@ -25,14 +25,14 @@ def setup_parser(subparser):
"--source-path",
dest="source_path",
default=None,
help="path to source directory. defaults to the current directory",
help="path to source directory (defaults to the current directory)",
)
subparser.add_argument(
"-i",
"--ignore-dependencies",
action="store_true",
dest="ignore_deps",
help="don't try to install dependencies of requested packages",
help="do not try to install dependencies of requested packages",
)
arguments.add_common_arguments(subparser, ["no_checksum", "deprecated"])
subparser.add_argument(
@@ -55,16 +55,13 @@ def setup_parser(subparser):
type=str,
dest="shell",
default=None,
help="drop into a build environment in a new shell, e.g. bash, zsh",
help="drop into a build environment in a new shell, e.g., bash",
)
subparser.add_argument(
"--test",
default=None,
choices=["root", "all"],
help="""If 'root' is chosen, run package tests during
installation for top-level packages (but skip tests for dependencies).
if 'all' is chosen, run package tests during installation for all
packages. If neither are chosen, don't run tests for any packages.""",
help="run tests on only root packages or all packages",
)
arguments.add_common_arguments(subparser, ["spec"])

View File

@@ -20,7 +20,7 @@
def setup_parser(subparser):
subparser.add_argument("-p", "--path", help="Source location of package")
subparser.add_argument("-p", "--path", help="source location of package")
clone_group = subparser.add_mutually_exclusive_group()
clone_group.add_argument(
@@ -28,18 +28,18 @@ def setup_parser(subparser):
action="store_false",
dest="clone",
default=None,
help="Do not clone. The package already exists at the source path",
help="do not clone, the package already exists at the source path",
)
clone_group.add_argument(
"--clone",
action="store_true",
dest="clone",
default=None,
help="Clone the package even if the path already exists",
help="clone the package even if the path already exists",
)
subparser.add_argument(
"-f", "--force", help="Remove any files or directories that block cloning source code"
"-f", "--force", help="remove any files or directories that block cloning source code"
)
arguments.add_common_arguments(subparser, ["spec"])
@@ -66,8 +66,7 @@ def develop(parser, args):
# Both old syntax `spack develop pkg@x` and new syntax `spack develop pkg@=x`
# are currently supported.
spec = spack.spec.parse_with_version_concrete(entry["spec"])
pkg_cls = spack.repo.path.get_pkg_class(spec.name)
pkg_cls(spec).stage.steal_source(abspath)
env.develop(spec=spec, path=path, clone=True)
if not env.dev_specs:
tty.warn("No develop specs to download")

View File

@@ -29,7 +29,7 @@ def setup_parser(subparser):
action="store_true",
default=False,
dest="dump_json",
help="Dump json output instead of pretty printing.",
help="dump json output instead of pretty printing",
)
subparser.add_argument(
"--first",

View File

@@ -62,7 +62,7 @@ def setup_parser(subparser):
dest="path",
action="store_const",
const=spack.paths.build_systems_path,
help="Edit the build system with the supplied name.",
help="edit the build system with the supplied name",
)
excl_args.add_argument(
"-c",

View File

@@ -86,6 +86,13 @@ def env_activate_setup_parser(subparser):
const="bat",
help="print bat commands to activate the environment",
)
shells.add_argument(
"--pwsh",
action="store_const",
dest="shell",
const="pwsh",
help="print powershell commands to activate environment",
)
view_options = subparser.add_mutually_exclusive_group()
view_options.add_argument(
@@ -95,7 +102,7 @@ def env_activate_setup_parser(subparser):
dest="with_view",
const=True,
default=True,
help="update PATH etc. with associated view",
help="update PATH, etc., with associated view",
)
view_options.add_argument(
"-V",
@@ -104,7 +111,7 @@ def env_activate_setup_parser(subparser):
dest="with_view",
const=False,
default=True,
help="do not update PATH etc. with associated view",
help="do not update PATH, etc., with associated view",
)
subparser.add_argument(
@@ -154,7 +161,7 @@ def env_activate(args):
# Error out when -e, -E, -D flags are given, cause they are ambiguous.
if args.env or args.no_env or args.env_dir:
tty.die("Calling spack env activate with --env, --env-dir and --no-env " "is ambiguous")
tty.die("Calling spack env activate with --env, --env-dir and --no-env is ambiguous")
env_name_or_dir = args.activate_env or args.dir
@@ -243,7 +250,7 @@ def env_deactivate(args):
# Error out when -e, -E, -D flags are given, cause they are ambiguous.
if args.env or args.no_env or args.env_dir:
tty.die("Calling spack env deactivate with --env, --env-dir and --no-env " "is ambiguous")
tty.die("Calling spack env deactivate with --env, --env-dir and --no-env is ambiguous")
if ev.active_environment() is None:
tty.die("No environment is currently active.")
@@ -283,7 +290,7 @@ def env_create_setup_parser(subparser):
"envfile",
nargs="?",
default=None,
help="either a lockfile (must end with '.json' or '.lock') or a manifest file.",
help="either a lockfile (must end with '.json' or '.lock') or a manifest file",
)
@@ -411,7 +418,7 @@ def env_list(args):
colify(color_names, indent=4)
class ViewAction(object):
class ViewAction:
regenerate = "regenerate"
enable = "enable"
disable = "disable"
@@ -601,16 +608,16 @@ def env_depfile_setup_parser(subparser):
"--make-target-prefix",
default=None,
metavar="TARGET",
help="prefix Makefile targets (and variables) with <TARGET>/<name>. By default "
help="prefix Makefile targets (and variables) with <TARGET>/<name>\n\nby default "
"the absolute path to the directory makedeps under the environment metadata dir is "
"used. Can be set to an empty string --make-prefix ''.",
"used. can be set to an empty string --make-prefix ''",
)
subparser.add_argument(
"--make-disable-jobserver",
default=True,
action="store_false",
dest="jobserver",
help="disable POSIX jobserver support.",
help="disable POSIX jobserver support",
)
subparser.add_argument(
"--use-buildcache",
@@ -618,8 +625,8 @@ def env_depfile_setup_parser(subparser):
type=arguments.use_buildcache,
default="package:auto,dependencies:auto",
metavar="[{auto,only,never},][package:{auto,only,never},][dependencies:{auto,only,never}]",
help="When using `only`, redundant build dependencies are pruned from the DAG. "
"This flag is passed on to the generated spack install commands.",
help="when using `only`, redundant build dependencies are pruned from the DAG\n\n"
"this flag is passed on to the generated spack install commands",
)
subparser.add_argument(
"-o",
@@ -633,7 +640,7 @@ def env_depfile_setup_parser(subparser):
"--generator",
default="make",
choices=("make",),
help="specify the depfile type. Currently only make is supported.",
help="specify the depfile type\n\ncurrently only make is supported",
)
subparser.add_argument(
metavar="specs",

View File

@@ -22,7 +22,7 @@
def setup_parser(subparser):
subparser.epilog = (
"If called without argument returns " "the list of all valid extendable packages"
"If called without argument returns the list of all valid extendable packages"
)
arguments.add_common_arguments(subparser, ["long", "very_long"])
subparser.add_argument(
@@ -91,7 +91,7 @@ def extensions(parser, args):
if args.show in ("installed", "all"):
# List specs of installed extensions.
installed = [s.spec for s in spack.store.db.installed_extensions_for(spec)]
installed = [s.spec for s in spack.store.STORE.db.installed_extensions_for(spec)]
if args.show == "all":
print

View File

@@ -2,8 +2,6 @@
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import argparse
import errno
import os
@@ -44,7 +42,7 @@ def setup_parser(subparser):
"--path",
default=None,
action="append",
help="Alternative search paths for finding externals. May be repeated",
help="one or more alternative search paths for finding externals",
)
find_parser.add_argument(
"--scope",
@@ -68,10 +66,8 @@ def setup_parser(subparser):
read_cray_manifest = sp.add_parser(
"read-cray-manifest",
help=(
"consume a Spack-compatible description of externally-installed "
"packages, including dependency relationships"
),
help="consume a Spack-compatible description of externally-installed packages, including "
"dependency relationships",
)
read_cray_manifest.add_argument(
"--file", default=None, help="specify a location other than the default"
@@ -79,6 +75,12 @@ def setup_parser(subparser):
read_cray_manifest.add_argument(
"--directory", default=None, help="specify a directory storing a group of manifest files"
)
read_cray_manifest.add_argument(
"--ignore-default-dir",
action="store_true",
default=False,
help="ignore the default directory of manifest files",
)
read_cray_manifest.add_argument(
"--dry-run",
action="store_true",
@@ -88,7 +90,7 @@ def setup_parser(subparser):
read_cray_manifest.add_argument(
"--fail-on-error",
action="store_true",
help=("if a manifest file cannot be parsed, fail and report the " "full stack trace"),
help="if a manifest file cannot be parsed, fail and report the full stack trace",
)
@@ -107,14 +109,14 @@ def external_find(args):
# For most exceptions, just print a warning and continue.
# Note that KeyboardInterrupt does not subclass Exception
# (so CTRL-C will terminate the program as expected).
skip_msg = "Skipping manifest and continuing with other external " "checks"
skip_msg = "Skipping manifest and continuing with other external checks"
if (isinstance(e, IOError) or isinstance(e, OSError)) and e.errno in [
errno.EPERM,
errno.EACCES,
]:
# The manifest file does not have sufficient permissions enabled:
# print a warning and keep going
tty.warn("Unable to read manifest due to insufficient " "permissions.", skip_msg)
tty.warn("Unable to read manifest due to insufficient permissions.", skip_msg)
else:
tty.warn("Unable to read manifest, unexpected error: {0}".format(str(e)), skip_msg)
@@ -164,7 +166,7 @@ def external_find(args):
)
if new_entries:
path = spack.config.config.get_config_filename(args.scope, "packages")
msg = "The following specs have been detected on this system " "and added to {0}"
msg = "The following specs have been detected on this system and added to {0}"
tty.msg(msg.format(path))
spack.cmd.display_specs(new_entries)
else:
@@ -177,11 +179,16 @@ def external_read_cray_manifest(args):
manifest_directory=args.directory,
dry_run=args.dry_run,
fail_on_error=args.fail_on_error,
ignore_default_dir=args.ignore_default_dir,
)
def _collect_and_consume_cray_manifest_files(
manifest_file=None, manifest_directory=None, dry_run=False, fail_on_error=False
manifest_file=None,
manifest_directory=None,
dry_run=False,
fail_on_error=False,
ignore_default_dir=False,
):
manifest_files = []
if manifest_file:
@@ -191,7 +198,7 @@ def _collect_and_consume_cray_manifest_files(
if manifest_directory:
manifest_dirs.append(manifest_directory)
if os.path.isdir(cray_manifest.default_path):
if not ignore_default_dir and os.path.isdir(cray_manifest.default_path):
tty.debug(
"Cray manifest path {0} exists: collecting all files to read.".format(
cray_manifest.default_path
@@ -227,7 +234,7 @@ def _collect_and_consume_cray_manifest_files(
if fail_on_error:
raise
else:
tty.warn("Failure reading manifest file: {0}" "\n\t{1}".format(path, str(e)))
tty.warn("Failure reading manifest file: {0}\n\t{1}".format(path, str(e)))
def external_list(args):

View File

@@ -10,6 +10,7 @@
import spack.config
import spack.environment as ev
import spack.repo
import spack.traverse
description = "fetch archives for packages"
section = "build"
@@ -36,6 +37,12 @@ def setup_parser(subparser):
def fetch(parser, args):
if args.no_checksum:
spack.config.set("config:checksum", False, scope="command_line")
if args.deprecated:
spack.config.set("config:deprecated", True, scope="command_line")
if args.specs:
specs = spack.cmd.parse_specs(args.specs, concretize=True)
else:
@@ -51,24 +58,21 @@ def fetch(parser, args):
else:
specs = env.all_specs()
if specs == []:
tty.die(
"No uninstalled specs in environment. Did you " "run `spack concretize` yet?"
)
tty.die("No uninstalled specs in environment. Did you run `spack concretize` yet?")
else:
tty.die("fetch requires at least one spec argument")
if args.no_checksum:
spack.config.set("config:checksum", False, scope="command_line")
if args.dependencies or args.missing:
to_be_fetched = spack.traverse.traverse_nodes(specs, key=spack.traverse.by_dag_hash)
else:
to_be_fetched = specs
if args.deprecated:
spack.config.set("config:deprecated", True, scope="command_line")
for spec in to_be_fetched:
if args.missing and spec.installed:
continue
for spec in specs:
if args.missing or args.dependencies:
for s in spec.traverse(root=False):
# Skip already-installed packages with --missing
if args.missing and s.installed:
continue
pkg = spec.package
s.package.do_fetch()
spec.package.do_fetch()
pkg.stage.keep = True
with pkg.stage:
pkg.do_fetch()

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import copy
import sys
@@ -32,6 +30,14 @@ def setup_parser(subparser):
default=None,
help="output specs with the specified format string",
)
format_group.add_argument(
"-H",
"--hashes",
action="store_const",
dest="format",
const="{/hash}",
help="same as '--format {/hash}'; use with xargs or $()",
)
format_group.add_argument(
"--json",
action="store_true",
@@ -61,7 +67,7 @@ def setup_parser(subparser):
help="do not group specs by arch/compiler",
)
arguments.add_common_arguments(subparser, ["long", "very_long", "tags"])
arguments.add_common_arguments(subparser, ["long", "very_long", "tags", "namespaces"])
subparser.add_argument(
"-c",
@@ -134,9 +140,6 @@ def setup_parser(subparser):
subparser.add_argument(
"--only-deprecated", action="store_true", help="show only deprecated packages"
)
subparser.add_argument(
"-N", "--namespace", action="store_true", help="show fully qualified package names"
)
subparser.add_argument("--start-date", help="earliest date of installation [YYYY-MM-DD]")
subparser.add_argument("--end-date", help="latest date of installation [YYYY-MM-DD]")
@@ -224,7 +227,7 @@ def display_env(env, args, decorator, results):
env.user_specs,
root_args,
decorator=lambda s, f: color.colorize("@*{%s}" % f),
namespace=True,
namespaces=True,
show_flags=True,
show_full_compiler=True,
variants=True,

View File

@@ -20,7 +20,7 @@ def setup_parser(subparser):
def gc(parser, args):
specs = spack.store.db.unused_specs
specs = spack.store.STORE.db.unused_specs
# Restrict garbage collection to the active environment
# speculating over roots that are yet to be installed

View File

@@ -68,7 +68,7 @@ def setup_parser(subparser):
metavar="DEST",
type=str,
dest="secret",
help="export the private key to a file.",
help="export the private key to a file",
)
create.set_defaults(func=gpg_create)
@@ -86,7 +86,7 @@ def setup_parser(subparser):
export = subparsers.add_parser("export", help=gpg_export.__doc__)
export.add_argument("location", type=str, help="where to export keys")
export.add_argument(
"keys", nargs="*", help="the keys to export; " "all public keys if unspecified"
"keys", nargs="*", help="the keys to export (all public keys if unspecified)"
)
export.add_argument("--secret", action="store_true", help="export secret keys")
export.set_defaults(func=gpg_export)
@@ -99,29 +99,29 @@ def setup_parser(subparser):
"--directory",
metavar="directory",
type=str,
help="local directory where keys will be published.",
help="local directory where keys will be published",
)
output.add_argument(
"-m",
"--mirror-name",
metavar="mirror-name",
type=str,
help="name of the mirror where " + "keys will be published.",
help="name of the mirror where keys will be published",
)
output.add_argument(
"--mirror-url",
metavar="mirror-url",
type=str,
help="URL of the mirror where " + "keys will be published.",
help="URL of the mirror where keys will be published",
)
publish.add_argument(
"--rebuild-index",
action="store_true",
default=False,
help=("Regenerate buildcache key index " "after publishing key(s)"),
help="regenerate buildcache key index after publishing key(s)",
)
publish.add_argument(
"keys", nargs="*", help="the keys to publish; " "all public keys if unspecified"
"keys", nargs="*", help="keys to publish (all public keys if unspecified)"
)
publish.set_defaults(func=gpg_publish)
@@ -146,7 +146,7 @@ def gpg_create(args):
def gpg_export(args):
"""export a gpg key, optionally including secret key."""
"""export a gpg key, optionally including secret key"""
keys = args.keys
if not keys:
keys = spack.util.gpg.signing_keys()
@@ -168,7 +168,7 @@ def gpg_sign(args):
elif not keys:
raise RuntimeError("no signing keys are available")
else:
raise RuntimeError("multiple signing keys are available; " "please choose one")
raise RuntimeError("multiple signing keys are available; please choose one")
output = args.output
if not output:
output = args.spec[0] + ".asc"
@@ -216,7 +216,7 @@ def gpg_publish(args):
url = spack.util.url.path_to_file_url(args.directory)
mirror = spack.mirror.Mirror(url, url)
elif args.mirror_name:
mirror = spack.mirror.MirrorCollection().lookup(args.mirror_name)
mirror = spack.mirror.MirrorCollection(binary=True).lookup(args.mirror_name)
elif args.mirror_url:
mirror = spack.mirror.Mirror(args.mirror_url, args.mirror_url)

View File

@@ -63,7 +63,7 @@ def graph(parser, args):
if env:
specs = env.all_specs()
else:
specs = spack.store.db.query()
specs = spack.store.STORE.db.query()
else:
specs = spack.cmd.parse_specs(args.specs, concretize=not args.static)

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import textwrap
from itertools import zip_longest
@@ -73,7 +71,7 @@ def variant(s):
return spack.spec.enabled_variant_color + s + plain_format
class VariantFormatter(object):
class VariantFormatter:
def __init__(self, variants):
self.variants = variants
self.headers = ("Name [Default]", "When", "Allowed values", "Description")

View File

@@ -75,10 +75,9 @@ def setup_parser(subparser):
default="package,dependencies",
dest="things_to_install",
choices=["package", "dependencies"],
help="""select the mode of installation.
the default is to install the package along with all its dependencies.
alternatively one can decide to install only the package or only
the dependencies""",
help="select the mode of installation\n\n"
"default is to install the package along with all its dependencies. "
"alternatively, one can decide to install only the package or only the dependencies",
)
subparser.add_argument(
"-u",
@@ -143,12 +142,11 @@ def setup_parser(subparser):
type=arguments.use_buildcache,
default="package:auto,dependencies:auto",
metavar="[{auto,only,never},][package:{auto,only,never},][dependencies:{auto,only,never}]",
help="""select the mode of buildcache for the 'package' and 'dependencies'.
Default: package:auto,dependencies:auto
- `auto` behaves like --use-cache
- `only` behaves like --cache-only
- `never` behaves like --no-cache
""",
help="select the mode of buildcache for the 'package' and 'dependencies'\n\n"
"default: package:auto,dependencies:auto\n\n"
"- `auto` behaves like --use-cache\n"
"- `only` behaves like --cache-only\n"
"- `never` behaves like --no-cache",
)
subparser.add_argument(
@@ -156,8 +154,8 @@ def setup_parser(subparser):
action="store_true",
dest="include_build_deps",
default=False,
help="""include build deps when installing from cache,
which is useful for CI pipeline troubleshooting""",
help="include build deps when installing from cache, "
"useful for CI pipeline troubleshooting",
)
subparser.add_argument(
@@ -186,7 +184,7 @@ def setup_parser(subparser):
dest="install_verbose",
help="display verbose build output while installing",
)
subparser.add_argument("--fake", action="store_true", help="fake install for debug purposes.")
subparser.add_argument("--fake", action="store_true", help="fake install for debug purposes")
subparser.add_argument(
"--only-concrete",
action="store_true",
@@ -199,14 +197,13 @@ def setup_parser(subparser):
"--add",
action="store_true",
default=False,
help="""(with environment) add spec to the environment as a root.""",
help="(with environment) add spec to the environment as a root",
)
updateenv_group.add_argument(
"--no-add",
action="store_false",
dest="add",
help="""(with environment) do not add spec to the environment as a
root (the default behavior).""",
help="(with environment) do not add spec to the environment as a root",
)
subparser.add_argument(
@@ -216,7 +213,7 @@ def setup_parser(subparser):
default=[],
dest="specfiles",
metavar="SPEC_YAML_FILE",
help="install from file. Read specs to install from .yaml files",
help="read specs to install from .yaml files",
)
cd_group = subparser.add_mutually_exclusive_group()
@@ -227,19 +224,12 @@ def setup_parser(subparser):
"--test",
default=None,
choices=["root", "all"],
help="""If 'root' is chosen, run package tests during
installation for top-level packages (but skip tests for dependencies).
if 'all' is chosen, run package tests during installation for all
packages. If neither are chosen, don't run tests for any packages.""",
help="run tests on only root packages or all packages",
)
arguments.add_common_arguments(subparser, ["log_format"])
subparser.add_argument("--log-file", default=None, help="filename for the log file")
subparser.add_argument(
"--log-file",
default=None,
help="filename for the log file. if not passed a default will be used",
)
subparser.add_argument(
"--help-cdash", action="store_true", help="Show usage instructions for CDash reporting"
"--help-cdash", action="store_true", help="show usage instructions for CDash reporting"
)
arguments.add_cdash_args(subparser, False)
arguments.add_common_arguments(subparser, ["yes_to_all", "spec"])
@@ -276,11 +266,11 @@ def require_user_confirmation_for_overwrite(concrete_specs, args):
if args.yes_to_all:
return
installed = list(filter(lambda x: x, map(spack.store.db.query_one, concrete_specs)))
installed = list(filter(lambda x: x, map(spack.store.STORE.db.query_one, concrete_specs)))
display_args = {"long": True, "show_flags": True, "variants": True}
if installed:
tty.msg("The following package specs will be " "reinstalled:\n")
tty.msg("The following package specs will be reinstalled:\n")
spack.cmd.display_specs(installed, **display_args)
not_installed = list(filter(lambda x: x not in installed, concrete_specs))

View File

@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import os
import re
from collections import defaultdict
@@ -102,7 +100,7 @@ def list_files(args):
]
class LicenseError(object):
class LicenseError:
def __init__(self):
self.error_counts = defaultdict(int)

Some files were not shown because too many files have changed in this diff Show More