Peter Scheibel
60f7756626
Executable.__call__ original semantics were to avoid redirecting process output
...
to the output stream if return_output was set. This branch undid that and this
commit restores those semantics.
2015-11-25 12:28:43 -08:00
Todd Gamblin
04f032d6e3
Rename spack.db -> spack.repo
...
Making distinction between install database and package repositories clearer.
2015-11-25 10:01:44 -08:00
Todd Gamblin
e6d232bfef
Rename packages.py to repository.py, PackageFinder to RepoPath.
2015-11-25 09:58:10 -08:00
Peter Scheibel
18dea24df8
Use the xunit nose plugin to generate JUnit XML test results from Spack's unit
...
tests.
2015-11-24 19:08:37 -08:00
Peter Scheibel
0adf93853d
Update log_output to handle cases where sys.stdout/stderr streams do not have
...
an associated file descriptor (e.g. holds for nose tests where sys.stdout is
assigned to a StringIO object)
2015-11-24 17:58:17 -08:00
Peter Scheibel
5081ba6802
It appears the same test object was returned multiple times for different
...
unit tests, so tracking tests with sets wouldn't work unless I extracted the
details relevant to the particular test. For now a simple count will work so
using a set was unnecessary anyways.
2015-11-24 10:45:07 -08:00
Peter Scheibel
70049185a5
Activation of Tally plugin to count tests. It doesn't appear to be actually
...
counting the individual unit tests correctly so I need to chase that down.
2015-11-24 10:39:42 -08:00
Peter Scheibel
099fa1df34
Use nose to run unit tests.
...
1. Adding a plugin to keep track of the total number of tests run as well as the
number of tests with failures/errors.
2. Some nose plugins (including xunit which will be added in a future commit)
assign stdout to a stream object that does not have a .fileno attribute.
spack.util.executable.Executable now avoids passing stdout to subprocess (and
always uses subprocess.PIPE)
TODO:
1. Still need to figure out how to activate the plugin (as of now it is
being ignored by nose). Newer versions of nose appear to make this simpler
(e.g. the "addplugins" argument to nose.run)
2. Need to include new version of nose in order to use xunit
2015-11-23 18:59:48 -08:00
Todd Gamblin
cf3d236b9f
Merge branch 'scheibelp-features/externaldeps' into develop
2015-11-23 17:50:49 -08:00
Todd Gamblin
1447fd0a12
Merge pull request #160 from SteVwonder/stevwonder/develop
...
Fixed -l flag for 'spack extensions'
2015-11-23 15:50:18 -08:00
Todd Gamblin
8c06b92225
Working PackageFinder / Repo
2015-11-22 20:28:59 -08:00
Tom Scogland
5e93dd6592
modified warning to reference spack clean
...
clean --dist has been removed, command fixed to something that works.
2015-11-20 11:49:46 -08:00
Todd Gamblin
38fdd063d9
Fix and move NamespaceTrie to spack.util.naming
...
- fix up routines in namespace trie.
- trie can now hold intermediate elements.
- trie now has a test case.
2015-11-12 15:17:39 -08:00
Todd Gamblin
72c9604bcb
Small fix to prevent this test from interfering with others.
2015-11-12 15:17:09 -08:00
Todd Gamblin
55662eca69
Merge branch 'develop' into mplegendre-multi_pkgsrc_roots
...
Conflicts:
lib/spack/spack/__init__.py
lib/spack/spack/directives.py
lib/spack/spack/packages.py
2015-11-12 15:16:06 -08:00
Stephen Herbein
9c30e0210b
Fixed -l flag for 'spack extensions'
2015-11-12 08:15:38 -08:00
Peter Scheibel
6d7b26d4e0
Insert lib/spack/external into sys.path. This avoids cases where the system
...
python install and lib/spack/external have the same library installed. This
requires modifying the names of some modules in lib/spack/external in cases
where both the system python and backported features of future python versions
(i.e. after 2.6) are used (previously distinguished by "from external import X"
and "import X").
2015-11-11 18:04:22 -08:00
Gregory Becker
cd69681ae5
merged in work from other computer and starting to track down bugs
2015-11-11 10:09:03 -08:00
Todd Gamblin
5417a514e9
Eliminated two bugs found by spack test and rewrote the parser to be more sane
2015-11-10 18:44:01 -08:00
Gregory Becker
5e75a5c81c
Fixed bug that spack.db.exists() returned True for anonymous specs
2015-11-10 15:45:22 -08:00
Gregory Becker
6f339939c4
Removed "any-pkg-name" and replaced it with empty string. Also changed cflag concretizer to concretize each flag individually, allowing us to have unconcretized FlagMap objects for find and uninstall. Now empty flags in find match any, whereas specifying +cflags=\'\' matches only those with empty strings for flags
2015-11-10 15:45:22 -08:00
Gregory Becker
6fa0bb991a
Removed cflags from default format string and made them an option within the compiler string. Added -f option to find command; with -f, find prints flags
2015-11-10 15:45:22 -08:00
Gregory Becker
5a9394c65f
added default compilers into spec and fixed constrain/concretize bug
2015-11-10 15:45:22 -08:00
Gregory Becker
cb5bc242db
Changed flag default to "". Updated printing and other logic to match. Seems to have solved error in normalize.
2015-11-10 15:45:22 -08:00
Gregory Becker
2d77173dfa
partial commit of cflags for debugging
2015-11-10 15:45:22 -08:00
Gregory Becker
42b5b7d2dd
Commit of compiler flags addition:
...
Flags are passed from the command line all the way through
build environments to environment variables.
Flags are specified using +name=value and values are quoted
using escaped quotes when necessary.
Future work includes using the flags in the compiler wrapper script
and hopefully updating the parser for a gentler user experience of
the spec language.
2015-11-10 15:45:22 -08:00
Gregory Becker
db1b21b9aa
reclaimed the = sign. Architectures now specified by +arch= instead. Decided to prepend flag names with + for clarity in spec names and ease of parsing. Also generalized variants, although there is not yet a way to specify a generalized (name=value) variant.
2015-11-10 15:45:22 -08:00
Gregory Becker
7989a7f903
Headless specs and /hash spec specification
2015-11-10 15:42:10 -08:00
Gregory Becker
f9c8c4d216
partial commit to merge database
2015-11-10 15:40:00 -08:00
Gregory Becker
4ed22ad932
partial commit of cflags work
2015-11-10 15:39:27 -08:00
Todd Gamblin
0d993947ee
Fix SPACK-93, SPACK-94, GitHub #150
...
- `remove_prefix` was modified to remove from the DB, but the package
may not have been added to the DB yet when `remove_prefix` is called
from `cleanup`.
- Made `remove_prefix` a pure utility function (it just removes the prefix)
- Added `installed_db.remove()` call only after the `remove_prefix` in
`uninstall`.
2015-11-04 16:44:33 -08:00
Todd Gamblin
339da1da3d
Make architecture reflect OS *and* machine. Use Python's platform module.
2015-11-04 07:46:17 -08:00
Massimiliano Culpo
6db2a58008
Fixed typo : write_lock() -> write_transaction()
2015-10-30 07:42:58 +01:00
Todd Gamblin
a1c42c2753
Merge Greg Becker's build database support into develop.
2015-10-29 02:22:20 -07:00
Todd Gamblin
671faa4b99
Merge pull request #124 from scheibelp/features/testinstall-cmd
...
Features/testinstall cmd
2015-10-29 00:16:52 -07:00
Todd Gamblin
ed0c80e1cb
Merge pull request #145 from markcmiller86/v-char-bugfix
...
generalize one of the cases to handle many more kinds of formatting o…
2015-10-29 00:02:01 -07:00
Todd Gamblin
fec6674597
Merge pull request #139 from mathstuf/use-uname-for-arch
...
architecture: use uname if available
2015-10-29 00:01:30 -07:00
miller86
21e9d5c5c3
generalize one of the cases to handle many more kinds of formatting options
2015-10-27 17:05:27 -07:00
Todd Gamblin
a58ae0c5d0
Build database working with simple transaction support; all tests passing.
2015-10-27 16:36:44 -07:00
Todd Gamblin
bf8479bec6
Fix stupid lock bug.
...
- Code simplification ignored case where exception was raised.
- If LockError was raised, read and write counts were incremented erroneously.
- updated lock test.
2015-10-27 16:34:26 -07:00
Peter Scheibel
50d0a2643b
Not all package stages have an archive file (e.g. source code repos) but all of
...
them do have a source_path: use this instead to check whether the package
resources were successfully retrieved.
2015-10-27 13:34:46 -07:00
Todd Gamblin
af7b96c14a
Lock acquires return True/False depending on whether they got POSIX lock.
2015-10-27 00:35:06 -07:00
Ben Boeckel
6c9b10f73d
architecture: remove custom mac_type method
2015-10-26 18:55:10 -04:00
Ben Boeckel
17a58ee0a9
architecture: use uname if available
2015-10-26 18:54:04 -04:00
Peter Scheibel
3b554c709b
Fetch errors were also terminating runs of test-install with system exit, so
...
stage.fetch() was updated to raise a FetchError instead of calling tty.die().
Output is the same for spack install in case of a fetch error.
2015-10-26 15:26:08 -07:00
Ben Boeckel
9d90cb6962
python: use the setdefault method on dict
...
It allows more concise code and skips some key lookups.
2015-10-26 17:38:19 -04:00
Peter Scheibel
9576860f8c
Making SpackError reference consistent.
2015-10-26 14:27:44 -07:00
Peter Scheibel
6a16040462
Automatically create a 'test-output' directory in the current directory if no
...
output path is specified. Test output files are placed in this directory.
Furthermore the filenames now have the prefix "test" (but otherwise are the
string representation of the spec ID as before).
2015-10-26 11:58:52 -07:00
Todd Gamblin
ead8ac58c6
Working Lock class, now uses POSIX fcntl locks, extensive unit test.
...
- llnl.util.lock now uses fcntl.lockf instead of flock
- purported to have more NFS compatibility.
- Added an extensive test case for locks.
- tests acquiring, releasing, upgrading, timeouts, shared, & exclusive cases.
2015-10-24 19:57:43 -07:00
Todd Gamblin
908a93a470
Add a multiprocess Barrier class to use for testing parallel code.
2015-10-24 19:54:52 -07:00