summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)AuthorFilesLines
2021-05-07return concrete spec (as is advertised in the docstring)Peter Josef Scheibel1-1/+1
2021-05-07fix check when retrieving matching spec from environment when there is a ↵Peter Josef Scheibel2-1/+19
match with a root spec as well as with a dependency of a root spec
2021-05-07compilers: aocc is now also available as a Cray PrgEnv (#23289)Tiziano Müller1-0/+3
2021-05-07Show useful error in build-env (#23458)Harmen Stoppels2-11/+21
Instead of an out of bounds error tell the user to provide a spec
2021-05-06ASP-based solver: minimize mismatch of targets (#23462)Massimiliano Culpo1-32/+19
Like compilers targets now try to minimize mismatches, instead of maximizing matches. Deduction of mismatches is reworked to be the opposite of a match, since computing that is faster.
2021-05-06ASP-based solver: no intermediate package for concretizing together (#23307)Massimiliano Culpo2-0/+33
The ASP-based solver can natively manage cases where more than one root spec is given, and is able to concretize all the roots together (ensuring one spec per package at most). Modifications: - [x] When concretising together an environment the ASP-based solver calls directly its `solve` method rather than constructing a temporary fake root package.
2021-05-06Reduce visual noise during distributed build (#23338)Harmen Stoppels2-3/+7
2021-05-06Put a module object in sys.modules before executing module code (#23269)Massimiliano Culpo2-2/+39
The loading protocol mandates that the the module we are going to import needs to be already in sys.modules before its code is executed, so to prevent unbounded recursions and multiple loading. Loading a module from file exits early if the module is already in sys.modules
2021-05-05intel-oneapi packages: support root installs (#23401)Robert Cohn1-0/+21
When installing OneAPI packages as root (e.g. in a container), the installer places cache files in /var/intel/installercache that interfere with future Spack installs. This ensures that when running an installation as a root user that this is removed.
2021-05-03archspec: updated external dependency (#23311)Massimiliano Culpo3-13/+71
Added support for Apple M1, extended support for zen3 with more compiler flags.
2021-05-03Use Python's built-in machinery to import compilers (#23290)Massimiliano Culpo1-8/+7
2021-05-03cmd: improve shell support help message (#23410)Michael Kuhn1-1/+8
Users sometimes set up Spack's shell support but still call `bin/spack`, which results in the help message showing up again.
2021-05-03Use an environment variable to set the default stacktrace behavior (#23357)Harmen Stoppels1-0/+1
2021-04-28Make Spack able to apply gz compressed remote patches (#22823)Massimiliano Culpo2-2/+19
Modified ncbi-rmblastn to retrieve patches from remote
2021-04-28Fix intersection if a version is a prefix of another (#22941)BenWeber422-1/+6
* Added test for version intersections when one is prefix of another * Fix version intersection for prefixes
2021-04-28Read colorization from environment variable, if command line is not set (#23130)Harmen Stoppels2-2/+9
2021-04-27Import hooks using Python's built-in machinery (#23288)Massimiliano Culpo1-52/+66
The function we coded in Spack to load Python modules with arbitrary names from a file seem to have issues with local imports. For loading hooks though it is unnecessary to use such functions, since we don't care to bind a custom name to a module nor we have to load it from an unknown location. This PR thus modifies spack.hook in the following ways: - Use __import__ instead of spack.util.imp.load_source (this addresses #20005) - Sync module docstring with all the hooks we have - Avoid using memoization in a module function - Marked with a leading underscore all the names that are supposed to stay local
2021-04-27Don't report configure errors to CDash for successful packages (#23286)Zack Galbreath2-9/+28
Convert configure errors detected by our log scraper into warnings when the package being installed reports that it was successful.
2021-04-26Dyninst: Add dependencies for v11.0.0 (#23121)Tim Haines1-1/+1
Also update the mpileaks unit test to avoid a conflict on CentOS 6 where Dyninst >=11.0.0 no longer builds due to a compiler version conflict.
2021-04-23docs: be more precise on what `spack add ...` does (#23204)George Hartzell1-3/+3
This is as much a question as it is a minor fine-tuning of the docs. I've been known to add things to an environment by editing the `spack.yaml` file directly. When I read the previous version of this sentence, I was afraid that `spack add` was actually doing *two* things, modifying the `spack.yaml` and updating something else that defined the roots of the Environment. A bit of experimentation suggests that editing the `spack.yaml` file is sufficient to change the roots. Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
2021-04-22Docs: Updated copyrights in files still using 2020 as ending year (#23215)Tamara Dahlgren4-4/+4
2021-04-21ASP-based solve: minimize compiler mismatches (#23016)Massimiliano Culpo2-32/+26
fixes #22718 Instead of trying to maximize the number of matches (preferred behavior), try to minimize the number of mismatches (unwanted behavior).
2021-04-21ASP-based solver: suppress warnings when constructing facts (#23090)Massimiliano Culpo1-1/+4
fixes #22786 Trying to get optimization flags for a specific target from a compiler may trigger warnings. In the context of constructing facts for the ASP-based solver we don't want to show these warnings to the user, so here we simply ignore them.
2021-04-20check for package in spec not variant (#23157)Chris White1-3/+3
2021-04-20Catch rstudio based URL for `cran` attribute in create.py (#23072)Glenn Johnson1-1/+1
2021-04-20Fixing typo tty.fail -> tty.die and monitor docstrings (#23152)Vanessasaurus1-37/+90
This isn't a significant issue, but I noticed that the docstring incorrectly references "tty.fail" and I wanted to quickly fix it to reflect the correct command, tty.die. I also wanted to fix the docstrings to not be large clumps, to what @tgamblin suggested after I wrote this - having one line at the top that is a quick summary, and more verbose after that.
2021-04-16docs: spack does not have a variant debug for libelf (#23021)Vanessasaurus1-3/+3
Signed-off-by: vsoch <vsoch@users.noreply.github.com> Co-authored-by: vsoch <vsoch@users.noreply.github.com>
2021-04-15Return non-zero from CDash reporter when errors are detected (#22962)Zack Galbreath1-4/+12
2021-04-15Merge pull request #21930 from vsoch/add/spack-monitorVanessasaurus29-102/+2253
This provides initial support for [spack monitor](https://github.com/spack/spack-monitor), a web application that stores information and analysis about Spack installations. Spack can now contact a monitor server and upload analysis -- even after a build is already done. Specifically, this adds: - [x] monitor options for `spack install` - [x] `spack analyze` command - [x] hook architecture for analyzers - [x] separate build logs (in addition to the existing combined log) - [x] docs for spack analyze - [x] reworked developer docs, with hook docs - [x] analyzers for: - [x] config args - [x] environment variables - [x] installed files - [x] libabigail There is a lot more information in the docs contained in this PR, so consult those for full details on this feature. Additional tests will be added in a future PR.
2021-04-15Use `gethostname()` instead of `getfqdn()` for lock debug modevsoch2-2/+2
In debug mode, processes taking an exclusive lock write out their node name to the lock file. We were using `getfqdn()` for this, but it seems to produce inconsistent results when used from within some github actions containers. We get this error because getfqdn() seems to return a short name in one place and a fully qualified name in another: ``` File "/home/runner/work/spack/spack/lib/spack/spack/test/llnl/util/lock.py", line 1211, in p1 assert lock.host == self.host AssertionError: assert 'fv-az290-764....cloudapp.net' == 'fv-az290-764' - fv-az290-764.internal.cloudapp.net + fv-az290-764 !!!!!!!!!!!!!!!!!!!! Interrupted: stopping after 1 failures !!!!!!!!!!!!!!!!!!!! == 1 failed, 2547 passed, 7 skipped, 22 xfailed, 2 xpassed in 1238.67 seconds == ``` This seems to stem from https://bugs.python.org/issue5004. We don't really need to get a fully qualified hostname for debugging, so use `gethostname()` because its results are more consistent. This seems to fix the issue. Signed-off-by: vsoch <vsoch@users.noreply.github.com>
2021-04-14updates for new tutorialGregory Becker1-2/+2
update s3 bucket update tutorial branch
2021-04-13Documentation: update intel-parallel-studio instructions (#22248)Tiziano Müller1-36/+36
* Clarify stub compiler definition in compilers.yaml * Update explanation of why stub compiler definition is needed * Add note about required module definition when using Spack-installed intel-parallel-studio as intel-compiler * Add suggestion about updating package config preferences based on choice of variants when installing intel-parallel-studio to avoid reinstallation
2021-04-13intel-parallel-studio: fix vtune installation for 2020+ (#22255)Tiziano Müller1-3/+5
vtune_amplifier got renamed to vtune_profiler for the 2020+ suite
2021-04-12Externals with merged prefixes (#22653)Peter Scheibel2-17/+85
We remove system paths from search variables like PATH and from -L options because they may contain many packages and could interfere with Spack-built packages. External packages may be installed to prefixes that are not actually system paths but are still "merged" in the sense that many other packages are installed there. To avoid conflicts, this PR places all external packages at the end of search paths.
2021-04-11ASP-based solver: assign OS correctly with inheritance from parent (#22896)Massimiliano Culpo3-0/+28
fixes #22871 When in presence of multiple choices for the operating system we were lacking a rule to derive the node OS if it was inherited.
2021-04-09Build process output: handle UTF-8 for python 3.x to 3.7 (#22888)Peter Scheibel1-2/+9
We set LC_ALL=C to encourage a build process to generate ASCII output (so our logger daemon can decode it). Most packages respect this but it appears that intel-oneapi-compilers does not in some cases (see #22813). This reads the output of the build process as UTF-8, which still works if the build process respects LC_ALL=C but also works if the process generates UTF-8 output. For Python >= 3.7 all files are opened with UTF-8 encoding by default. Python 2 does not support the encoding argument on 'open', so to support Python 2 the files would have to be opened in byte mode and explicitly decoded (as a side note, this would be the only way to handle other encodings without being informed of them in advance).
2021-04-08bugfix: `spack config blame` should print all lines of config (#22598)Todd Gamblin2-7/+44
* bugfix: fix representation of null in spack_yaml output Nulls were previously printed differently by `spack config blame config` and `spack config get config`. Fix this in the `spack_yaml` dumpers. * bugfix: `spack config blame` should print all lines of config `spack config blame` was not printing all lines of configuration because there were no annotations for empty lines in the YAML dump output. Fix this by removing empty lines.
2021-04-08autotools: ensure config.guess and config.sub are writeable before patching ↵Toyohisa Kameyama1-0/+4
them (#19837)
2021-04-07[oneapi] fix mkl deps, externally installed, and docs (#22607)Robert Cohn2-24/+45
2021-04-06meson: added variants, changed defaults for the build system (#22715)Harmen Stoppels2-4/+21
- Use debugoptimized as default build type, just like RelWithDebInfo for cmake - Do not strip by default, and add a default_library variant which conveniently support both shared and static
2021-04-06spack location: fix usage without args (#22755)Harmen Stoppels2-4/+5
2021-04-06Remove erroneous warnings about quotes for from_source_file (#22767)Adam J. Stewart2-10/+18
2021-04-02Check against a list of known-broken specs in `ci generate` (#22690)Zack Galbreath7-16/+124
* Strip leading slash from S3 key in url_exists() * Check against a list of known-broken specs in `ci generate`
2021-04-02Document unzip (#22723)Harmen Stoppels1-1/+1
2021-04-02concretizer: improve display of optimization criteria (#22433)Todd Gamblin4-18/+78
By default, clingo doesn't show any optimization criteria (maximized or minimized sums) if the set they aggregate is empty. Per the clingo mailing list, we can get around that by adding, e.g.: ``` #minimize{ 0@2 : #true }. ``` for the 2nd criterion. This forces clingo to print out the criterion but does not affect the optimization. This PR adds directives as above for all of our optimization criteria, as well as facts with descriptions of each criterion,like this: ``` opt_criterion(2, "number of non-default variants") ``` We use facts in `concretize.lp` rather than hard-coding these in `asp.py` so that the names can be maintained in the same place as the other optimization criteria. The now-displayed weights and the names are used to display optimization output like this: ```console (spackle):solver> spack solve --show opt zlib ==> Best of 0 answers. ==> Optimization Criteria: Priority Criterion Value 1 version weight 0 2 number of non-default variants (roots) 0 3 multi-valued variants + preferred providers for roots 0 4 number of non-default variants (non-roots) 0 5 number of non-default providers (non-roots) 0 6 count of non-root multi-valued variants 0 7 compiler matches + number of nodes 1 8 version badness 0 9 non-preferred compilers 0 10 target matches 0 11 non-preferred targets 0 zlib@1.2.11%apple-clang@12.0.0+optimize+pic+shared arch=darwin-catalina-skylake ``` Note that this is all hidden behind a `--show opt` option to `spack solve`. Optimization weights are no longer shown by default, but you can at least inspect them and more easily understand what is going on. - [x] always show optimization criteria in `clingo` output - [x] add `opt_criterion()` facts for all optimizationc criteria - [x] make display of opt criteria optional in `spack solve` - [x] rework how optimization criteria are displayed, and add a `--show opt` optiong to `spack solve`
2021-04-01add CachedCMakePackage for using CMake initial config filesGreg Becker2-0/+253
CachedCMakePackage is a CMakePackage subclass for using CMake initial cache. This feature of CMake allows packages to increase reproducibility, especially between spack builds and manual builds. It also allows packages to sidestep certain parsing bugs in extremely long cmake commands, and to avoid system limits on the length of the command line. Co-authored by: Chris White <white238@llnl.gov>
2021-04-01Revert "CachedCMakePackage for using *.cmake initial config files (#19316)""Todd Gamblin2-253/+0
This reverts commit 7daf5823574dc18522f559a084095714cc9f3fb9.
2021-04-01bugfix: compiler wrappers should handle extra spaces between arguments (#22725)Elizabeth Fischer1-1/+9
In the face of two consecutive spaces in the command line, the compiler wrapper would skip all remaining arguments, causing problems building py-scipy with Intel compiler. This PR solves the problem. * Fixed compiler wrapper in the face of extra spaces between arguments Co-authored-by: Elizabeth Fischer <elizabeth.fischer@alaska.edu>
2021-03-31CachedCMakePackage for using *.cmake initial config files (#19316)"Greg Becker2-0/+253
Original commit message: This feature of CMake allows packages to increase reproducibility, especially between Spack- and manual builds. It also allows packages to sidestep certain parsing bugs in extremely long ``cmake`` commands, and to avoid system limits on the length of the command line. Adding: Co-authored by: Chris White <white238@llnl.gov> This reverts commit c4f0a3cf6cd2ab282f6abf20fd72fcb4739a432a.
2021-03-31Revert "CachedCMakePackage for using *.cmake initial config files (#19316)"Chris White2-253/+0
This reverts commit 764c17053041a65f684ce565a2598d705b04a16b.