Age | Commit message (Expand) | Author |
2015-08-08 | build: container: Add #:host-uids argument to call-with-container....It's not always possible to map 65536 uids when creating a container as the
root user within another user namespace. This is true when building Guix
within the build daemon's container. By using a uid range of 1 by default,
even as the root user, the tests now pass.
* gnu/build/linux-container.scm (initialize-user-namespace, run-container):
Add 'host-uids' argument.
(call-with-container): Add #:host-uids keyword argument.
* tests/containers.scm ("container-excursion"): Update 'run-container' call.
| David Thompson |
2015-07-25 | syscalls: Add 'network-interfaces', which wraps libc's 'getifaddrs'....Based on discussions with Rohan Prinja <rohan.prinja@gmail.com>.
* guix/build/syscalls.scm (<interface>): New record type.
(write-interface, values->interface, unfold-interface-list,
network-interfaces, free-ifaddrs): New procedures.
(ifaddrs): New C struct.
(%struct-ifaddrs-type, %sizeof-ifaddrs): New macros.
* tests/syscalls.scm ("network-interfaces returns one or more interfaces",
"network-interfaces returns \"lo\""): New tests.
| Ludovic Courtès |
2015-07-25 | syscalls: Rename 'network-interfaces' and 'all-network-interfaces'....* guix/build/syscalls.scm (network-interfaces): Rename to...
(network-interface-names): ... this.
(all-network-interfaces): Rename to...
(all-network-interface-names): ... this.
* gnu/services/networking.scm (dhcp-client-service): Adjust accordingly.
* tests/syscalls.scm ("all-network-interfaces"): Rename to...
("all-network-interface-names"): ... this, and adjust accordingly.
("network-interfaces"): Rename to...
("network-interface-names"): ... this, and adjust accordingly.
| Ludovic Courtès |
2015-07-20 | tests: Skip container tests if namespaces are not available....* tests/containers.scm: Skip all tests if user namespaces do not exist.
| David Thompson |
2015-07-20 | tests: Make #:references-graphs gexp test more tolerant....* tests/gexp.scm ("gexp->derivation #:references-graphs"): Use 'lset=' instead
of 'equal?' since the order in which references are listed in not
guaranteed.
| Ludovic Courtès |
2015-07-19 | Merge branch 'master' into core-updates | Mark H Weaver |
2015-07-18 | tests: Fix 'publish' test for nix-base32 format....This is a followup to commit 3b307162e892e0050836434b12e14376758419cc.
* tests/publish.scm ("/*.narinfo"): Use 'bytevector->nix-base32-string',
not 'bytevector->base32-string'.
| Alex Kost |
2015-07-16 | file-systems: 'uuid' raises a syntax error for invalid UUIDs....* gnu/system/file-systems.scm (uuid): Call 'syntax-violation' when
'string->uuid' returns #f.
* tests/file-systems.scm ("uuid, syntax error"): New test.
| Ludovic Courtès |
2015-07-15 | Merge branch 'master' into core-updates | Mark H Weaver |
2015-07-14 | file-systems: Allow users to specify file system UUIDs as strings....Fixes <http://bugs.gnu.org/19778>.
Reported by Mark H Weaver <mhw@netris.org>.
* gnu/system/file-systems.scm (%uuid-rx): New variable.
(string->uuid): New procedure.
(uuid): New macro.
* tests/file-systems.scm: New file.
* Makefile.am (SCM_TESTS): Add it.
* doc/guix.texi (File Systems): Give an example of UUID.
| Ludovic Courtès |
2015-07-13 | substitute: Honor "substitute-urls" option passed by "untrusted" clients....* guix/scripts/substitute.scm (or*): New macro.
(%cache-url): Honor "untrusted-substitute-urls".
* guix/tests.scm (%test-substitute-urls): New variable.
(open-connection-for-tests): Use it.
* tests/derivations.scm ("derivation-prerequisites-to-build and substitutes",
"derivation-prerequisites-to-build and substitutes, non-substitutable
build", "derivation-prerequisites-to-build and substitutes, local build"):
Pass it to 'set-build-options'.
* tests/guix-daemon.sh: Likewise.
* tests/store.scm ("substitute query, alternating URLs"): New test.
("substitute query", "substitute", "substitute + build-things with output
path", "substitute, corrupt output hash", "substitute --fallback"): Pass
#:substitute-urls to 'set-build-options'.
| Ludovic Courtès |
2015-07-13 | substitute: Store cached narinfo in cache-specific sub-directories....This ensures that switching between different substitute servers doesn't lead
to a polluted narinfo cache.
* guix/scripts/substitute.scm (narinfo-cache-file): Add 'cache-url'
parameter. Add the base32 of CACHE-URL as a sub-directory under
%NARINFO-CACHE-DIRECTORY. Update callers.
(cached-narinfo): Likewise. Call 'mkdir-p' on the dirname of the cache
file. Update callers.
(remove-expired-cached-narinfos): Add 'directory' parameter and use it
instead of %NARINFO-CACHE-DIRECTORY.
(narinfo-cache-directories): New procedure.
(maybe-remove-expired-cached-narinfo): Call 'remove-expired-cached-narinfos'
for each item returned by 'narinfo-cache-directories'.
| Ludovic Courtès |
2015-07-12 | packages: Rewrite 'transitive-inputs' to be linear and remove duplicates....There were two issues:
1. Use of 'delete-duplicates', which is quadratic, was a serious problem for
closures with lots of propagated inputs, such as that of the 'hydra'
package (several minutes for 'guix build hydra -n'!).
2. The 'delete-duplicates' call essentially had no effect since duplicate
inputs typically had a different label and were thus kept. For
instance, (bag-transitive-inputs (package->bag inkscape)) would return
216 items whereas (delete-duplicates (map cdr THAT)) contains only 67
items.
The new implementation returns 67 items in this case. For 'hydra', we're
down from 42211 items to 361, and roughly 13s for 'guix build hydra'.
* guix/packages.scm (transitive-inputs): Rewrite as a breadth-first
traversal. Remove duplicate propagated inputs.
* tests/packages.scm ("package-transitive-inputs", "package->bag, propagated
inputs"): Adjust to use simple labels for propagated inputs, without "/".
("package-transitive-inputs, no duplicates"): New test.
| Ludovic Courtès |
2015-07-12 | tests: Adjust tests for new bootstrap Guile....This is a followup to commit 5d6792f ("gnu: bootstrap: Create a wrapper for
guile to set the system load path.")
* tests/size.scm ("store-profile"): Expect profile of 'bash' bootstrap binary.
* tests/gexp.scm ("gexp->derivation #:references-graphs"): Expect GUILE-DRV to
depend on 'bash' bootstrap binary.
| Ludovic Courtès |
2015-07-10 | tests: Skip namespace-related tests when that feature is missing....* tests/syscalls.scm ("clone", "setns", "pivot-root"): Skip
unless (user-namespace (getpid)) exists.
| Ludovic Courtès |
2015-07-09 | gnu: build: Add Linux container module....* gnu/build/linux-container.scm: New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
* .dir-locals.el: Add Scheme indent rules for 'call-with-container', and
'container-excursion'.
* tests/containers.scm: New file.
* Makefile.am (SCM_TESTS): Add it.
| David Thompson |
2015-07-08 | tests: Use the right identifier in tests/elpa.scm....* tests/elpa.scm: Change 'nil->empty' to 'ensure-list' in the whole file.
| Ludovic Courtès |
2015-07-08 | import: Add 'elpa' importer....* guix/import/elpa.scm: New file.
* guix/scripts/import.scm: Add "elpa" to 'importers'.
* guix/scripts/import/elpa.scm: New file.
* Makefile.am (MODULES): Add 'guix/import/elpa.scm' and
'guix/scripts/import/elpa.scm'.
(SCM_TESTS): Add 'tests/elpa.scm'.
* doc/guix.texi (Invoking guix import): Document it.
* tests/elpa.scm: New file.
* po/guix/POTFILES.in: Add 'guix/scripts/import/elpa.scm'.
| Federico Beffa |
2015-07-07 | build: syscalls: Add pivot-root....* guix/build/syscalls.scm (pivot-root): New procedure.
* tests/syscalls.scm ("pivot-root"): New test.
| David Thompson |
2015-07-07 | build: syscalls: Add setns....* guix/build/syscalls.scm (setns): New procedure.
* tests/syscalls.scm ("setns"): New test.
squash: setns
| David Thompson |
2015-07-07 | build: syscalls: Add clone....* guix/build/syscalls.scm (clone): New procedure.
(CLONE_NEWNS, CLONE_NEWUTS, CLONE_NEWIPC, CLONE_NEWUSER, CLONE_NEWPID,
CLONE_NEWNET): New variables.
* tests/syscalls.scm ("clone"): New test.
| David Thompson |
2015-07-07 | build: syscalls: Add mkdtemp!...* guix/build/syscalls.scm (mkdtemp!): New procedure.
* tests/syscalls.scm ("mkdtemp!"): New test.
| David Thompson |
2015-07-08 | tests: Test the exit code of 'guix environment'....This is a followup to d2cef62.
* tests/guix-environment.sh: Add test for the exit code.
| Ludovic Courtès |
2015-07-08 | store: 'run-with-store' initializes %CURRENT-TARGET-SYSTEM to #f....* guix/store.scm (run-with-store): Set %CURRENT-TARGET-SYSTEM to #f.
* tests/gexp.scm ("gexp->derivation vs. %current-target-system"): New test.
| Ludovic Courtès |
2015-07-03 | derivations: Add #:substitutable?, distinguished from #:local-build?....Fixes <http://bugs.gnu.org/18747>.
* guix/derivations.scm (substitutable-derivation?): Rewrite to check for
"allowSubstitutes".
(derivation): Add #:substitutable? parameter.
[user+system-env-vars]: Honor it.
(build-expression->derivation): Add #:substitutable? and honor it.
* guix/gexp.scm (gexp->derivation): Likewise.
* tests/derivations.scm ("derivation-prerequisites-to-build and substitutes,
non-substitutable build"): Use #:substitutable? instead of #:local-build?.
("substitutable-derivation?", "derivation-prerequisites-to-build and
substitutes, local build"): New tests.
* guix/download.scm (url-fetch): Adjust comment.
* guix/git-download.scm (git-fetch): Likewise.
* guix/build-system/gnu.scm (gnu-build, gnu-cross-build): Use #:substitutable?
instead of #:local-build?.
* doc/guix.texi (Derivations, G-Expressions): Adjust accordingly.
| Ludovic Courtès |
2015-07-01 | environment: For --ad-hoc, allow users to specify an output....* guix/scripts/environment.scm (package+propagated-inputs): Add 'output'
parameter. Use it in return value.
(options/resolve-packages): Use 'append-map' instead of 'map'. For 'load'
and 'expression', return all the outputs of the resulting package. For
'package', use 'specification->package+output' instead of
'specification->package'.
(guix-environment): Adjust uses of PACKAGES accordingly.
* doc/guix.texi (Invoking guix environment): Document it.
* tests/guix-environment.sh: Add test for --ad-hoc guile-bootstrap:out.
| Ludovic Courtès |
2015-07-01 | environment: Add only the specified outputs of the dependencies....Before that, 'guix environment guile' (for instance) would define environment
variables that would refer to the "include" output of Bash, the "debug" output
of libgc, etc., even though these are not listed as inputs in the recipe of
'guile'.
* guix/gexp.scm (lower-inputs): Export.
* guix/scripts/environment.scm (evaluate-input-search-paths): Remove
'derivations' parameter; add 'search-paths'. Expect 'inputs' to be
a list of tuples. Adjust callers.
(create-environment): Remove 'derivations' parameter; add 'search-paths'.
(show-search-paths): Likewise.
(package+propagated-inputs): New procedure.
(packages->transitive-inputs, packages+propagated-inputs): Remove.
(build-inputs): Expect INPUTS to be a list of derivation tuples.
(guix-environment): Compute INPUTS using 'package+propagated-inputs',
'package->bag', and 'bag-transitive-inputs'. Move 'run-with-store' higher.
* tests/guix-environment.sh: Add test with FINDUTILS-BOOT0.
| Ludovic Courtès |
2015-07-01 | tests: Add tests for 'guix environment'....* tests/guix-environment.sh: New file.
* Makefile.am (SH_TESTS): Add it.
| Ludovic Courtès |
2015-06-24 | import: pypi: Detect inputs....* guix/import/pypi.scm (python->package-name, maybe-inputs, compute-inputs,
guess-requirements): New procedures.
* guix/import/pypi.scm (guix-hash-url): Now takes a filename instead of an
URL as input.
* guix/import/pypi.scm (make-pypi-sexp): Now tries to generate the inputs
automagically.
* tests/pypi.scm: Update the test.
| Cyril Roelandt |
2015-06-24 | Add (guix cpio)....* guix/cpio.scm, tests/cpio.scm: New files.
* Makefile.am (MODULES): Add guix/cpio.scm.
(SCM_TESTS): Add tests/cpio.scm.
| Ludovic Courtès |
2015-06-24 | tests: Move 'file=?' to (guix tests)....* tests/nar.scm (file-tree-equal?)[file=?]: Move to...
* guix/tests.scm (file=?): ... here. New procedure.
| Ludovic Courtès |
2015-06-19 | gexp: 'local-file' canonicalizes its file argument....Reported by Alex Kost <alezost@gmail.com>
at <http://lists.gnu.org/archive/html/guix-devel/2015-06/msg00235.html>.
* guix/gexp.scm (local-file): Add call to 'canonicalize-path'.
* tests/gexp.scm ("one local file, symlink"): New test.
| Ludovic Courtès |
2015-06-19 | gexp: 'local-file' now defaults to non-recursive....Reported by Alex Kost <alezost@gmail.com>
at <http://lists.gnu.org/archive/html/guix-devel/2015-06/msg00235.html>.
* guix/gexp.scm (local-file): Change #:recursive? to default to #f.
* tests/gexp.scm ("one local file", "gexp->derivation, local-file"): Adjust
calls to 'add-to-store' and 'interned-file' accordingly.
| Ludovic Courtès |
2015-06-18 | Add 'guix size'....* guix/scripts/size.scm: New file.
* Makefile.am (MODULES): Add it.
(SCM_TESTS): Add tests/size.scm.
* doc.am (SUBCOMMANDS): Add 'size'.
* po/guix/POTFILES.in: Add guix/scripts/size.scm.
* tests/size.scm: New file.
* doc/guix.texi (Packages with Multiple Outputs): Add xref to "Invoking guix
size".
(Invoking guix size): New node.
(Invoking guix gc): Add index for "closure" and xref to the above.
* doc/contributing.texi (Submitting Patches): Use @enumerate for the check
list. Add item about 'guix size'.
| Ludovic Courtès |
2015-06-11 | tests: Avoid sequence of zero expressions....* tests/records.scm ("define-record-type* with let* behavior"): Add missing
body for clause.
| Ludovic Courtès |
2015-06-11 | records: Add support for 'innate' fields....* guix/records.scm (make-syntactic-constructor): Add #:innate parameter.
[record-inheritance]: Honor it.
[innate-field?]: New procedure.
(define-record-type*)[innate-field?]: New procedure.
Pass #:innate to 'make-syntactic-constructor'.
* tests/records.scm ("define-record-type* & inherit & innate",
"define-record-type* & thunked & innate"): New tests.
| Ludovic Courtès |
2015-06-10 | guix-register: Perform deduplication even when --prefix is passed....Fixes <http://bugs.gnu.org/19044>.
* nix/guix-register/guix-register.cc (register_validity): Change the (optimize
&& prefix.empty ()) condition to just (optimize). Change settings.nixStore
around the loop. Prepend PREFIX to the argument passed to 'optimisePath'.
* tests/guix-register.sh: Use 'guix-register -p' with duplicate files, and
make sure they are deduplicated on the target. Adjust existing tests.
| Ludovic Courtès |
2015-06-10 | tests: Make the daemon socket explicit in guix-register test....* tests/guix-register.sh: Define GUIX_DAEMON_SOCKET. Pass it explicitly to
'open-connection'.
| Ludovic Courtès |
2015-06-09 | import: hackage: Refactor parsing code and add new options....* guix/import/cabal.scm: New file.
* guix/import/hackage.scm: Update to use the new Cabal parsing module.
* tests/hackage.scm: Update tests.
* guix/scripts/import/hackage.scm: Add new '--cabal-environment' and '--stdin'
options.
* doc/guix.texi: ... and document them.
* Makefile.am (MODULES): Add 'guix/import/cabal.scm',
'guix/import/hackage.scm' and 'guix/scripts/import/hackage.scm'.
(SCM_TESTS): Add 'tests/hackage.scm'.
| Federico Beffa |
2015-06-08 | monads: Allow n-ary '>>=' expressions....Suggested by Federico Beffa <beffa@fbengineering.ch>.
* guix/monads.scm (bind-syntax): New macro.
(with-monad): Use it instead of 'identifier-syntax'.
* tests/monads.scm (">>= with more than two arguments"): New test.
* doc/guix.texi (The Store Monad): Explain that there can be several MPROC.
Add an example.
| Ludovic Courtès |
2015-06-06 | store: Add 'verify-store' RPC....* guix/store.scm (operation-id): Add 'verify-store'.
(verify-store): New procedure.
(set-build-options): Adjust comment.
* tests/store.scm ("verify-store", "verify-store + check-contents"): New
tests.
| Ludovic Courtès |
2015-06-03 | gexp: Add 'plain-file'....* guix/gexp.scm (<plain-file>): New type.
(plain-file, plain-file-compiler): New procedures.
* tests/gexp.scm ("one plain file"): New test.
* doc/guix.texi (G-Expressions): Document 'plain-file'.
| Ludovic Courtès |
2015-05-31 | base32: Use a custom error condition instead of 'misc-error'....Suggested by Christopher Allan Webber <cwebber@dustycloud.org>.
* guix/base32.scm (&invalid-base32-character): New error condition.
(make-base32-string->bytevector): Use it instead of 'error'.
* tests/base32.scm ("&invalid-base32-character"): New test.
| Ludovic Courtès |
2015-05-27 | monads: 'foldm', 'mapm', and 'anym' now take a list of regular values....* guix/monads.scm (foldm, mapm, anym): Change to take a list of regular
values as is customary.
* tests/monads.scm ("mapm", "anym"): Adjust accordingly.
| Ludovic Courtès |
2015-05-27 | tests: Make sure %BOOTSTRAP-GUILE is available when we need it....* tests/derivations.scm ("derivation-prerequisites and
valid-derivation-input?"): Renamed from "derivation-prerequisites and
derivation-input-is-valid?". Build %BOOTSTRAP-GUILE. This fixes a
regression introduced in cdb5b07 when running the whole test suite.
| Ludovic Courtès |
2015-05-26 | gc: ignore trailing slash or subdirectories for `guix gc -d'...Fixes <http://bugs.gnu.org/19757>.
* guix/scripts/gc.scm (guix-gc): Convert paths to direct store paths.
* guix/store.scm (direct-store-path): Get rid of subdirectories in store path.
* tests/guix-gc.sh: New tests.
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
| Cyrill Schenkel |
2015-05-25 | guix package: --manifest DTRT when combined with --dry-run....* guix/scripts/package.scm (guix-package)[process-actions]: Process 'manifest
action regardless of whether 'dry-run? is set. Adjust the message
accordingly.
* tests/guix-package.sh: Add error-reporting test.
| Ludovic Courtès |
2015-05-25 | ui: Auto-compile user code, and improve error reporting....Reported by Christian Grothoff.
* guix/ui.scm (load*): Add 'frame-with-source'. Set
%load-should-auto-compile. Change error handle to just (exit 1). Add
pre-unwind handler to capture the stack and call 'report-load-error'.
(report-load-error): Add optional 'frame' parameter and pass it to
'display-error'.
* tests/guix-system.sh: Add "unbound variable" test.
| Ludovic Courtès |
2015-05-24 | system: Make sure user accounts refer to existing groups....Fixes <http://bugs.gnu.org/20646>.
Reported by David Thompson <davet@gnu.org>.
* gnu/system/shadow.scm (assert-valid-users/groups): New procedure
* gnu/system.scm (operating-system-activation-script): Use it.
* tests/guix-system.sh (make_user_config): New function.
Add 3 tests using it.
* po/guix/POTFILES.in: Add gnu/system/shadow.scm.
| Ludovic Courtès |
2015-05-20 | package: Add --manifest option....* guix/scripts/package.scm (show-help): Add help text.
(%options): Add manifest option.
(guix-package): Add manifest option handler.
* doc/guix.texi ("Invoking guix package"): Document it.
* tests/guix-package.sh: Add test.
| David Thompson |