| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
| |
* guix/utils.scm (lzip-port): New procedure.
(decompressed-port, compressed-port, compressed-output-port): Add 'lzip
case.
* tests/utils.scm <top level>: Call 'test-compression/decompression' for
'lzip as well.
|
|
|
|
| |
* guix/utils.scm (absolute-dirname): Wrap in 'mlambda'.
|
|
|
|
|
|
|
| |
Threaded compression makes archives non-deterministic: the result depends on
the number of threads used for compressing. See <https://bugs.gnu.org/31015>.
This reverts commit 63102406f22412bb922de5549deb89d3594a38c0.
|
|
|
|
|
|
|
| |
Fixes <https://bugs.gnu.org/32126>.
* guix/utils.scm (call-with-temporary-directory): Use DELETE-FILE-RECURSIVELY
instead of RMDIR.
|
|
|
|
|
| |
* guix/utils.scm (source-properties->location): Destructure LOC with
'match', adding a fast path without 'assq-ref' calls.
|
|
|
|
|
|
| |
This was getting 25% hits, which did not quite justify the overhead.
* guix/utils.scm (location): Remove 'mlambda'.
|
|
|
|
|
|
| |
* guix/utils.scm (target-64bit?): New procedure.
* gnu/packages/samba.scm (ldb)[inputs]: Only add LMDB on 64-bit systems.
[arguments]: Make #:tests? conditional on LMDB availability.
|
|
|
|
|
| |
* guix/utils.scm (version-prefix?): New procedure.
* tests/utils.scm ("version-prefix?"): New test.
|
|
|
|
| |
* guix/utils.scm (version-major): New procedure.
|
|
|
|
| |
* guix/utils.scm (target-arm32?): New exported procedure.
|
|
|
|
|
|
| |
* guix/utils.scm (&error-location, &fix-hint): New condition types.
* guix/ui.scm (report-load-error): Handle them.
(call-with-error-handling): Honor '&error-location'.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Among other things, this removes (guix utils), (guix ui), (guix config),
etc. from the closure of (guix build download), as was the case since
798648515b77507c242752457b4dc17c155bad6e.
* guix/utils.scm (<progress-reporter>, call-with-progress-reporter):
Move to...
* guix/progress.scm: ... here. New file.
* Makefile.am (MODULES): Add it.
* guix/build/download.scm (current-terminal-columns)
(nearest-exact-integer, duration->seconds, seconds->string)
(byte-count->string, progress-bar, string-pad-middle)
(rate-limited, progress-reporter/file, dump-port*)
(time-monotonic): Move to progress.scm.
* guix/scripts/download.scm: Adjust accordingly.
* guix/scripts/substitute.scm: Likewise.
|
|
|
|
|
|
|
|
|
| |
Fixes <https://bugs.gnu.org/28756>.
* guix/utils.scm (filtered-port): Close the 'input' port for the current
process, and close it upon exit in the child process.
* guix/scripts/substitute.scm (progress-substitution): Display "\n\n" after
the reporter has finished.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* guix/utils.scm (<progress-reporter>): New record type.
(call-with-progress-reporter): New procedure.
* guix/build/download.scm (dump-port*, rate-limited, progress-reporter/file):
New procedures.
(ftp-fetch, http-fetch): Use 'dump-port*'.
(progress-proc): Remove procedure.
* guix/scripts/substitute.scm (progress-report-port): Rewrite in terms of
<progress-reporter>.
(process-substitution): Adjust accordingly.
|
|
|
|
|
| |
* guix/utils.scm (current-source-directory): Adjust for when
'syntax-source' returns #f.
|
|
|
|
|
|
|
|
| |
* guix/ui.scm (config-directory): Remove.
* guix/utils.scm (xdg-directory, config-directory): New procedures.
(cache-directory): Rewrite in terms of 'xdg-directory'.
* guix/scripts/substitute.scm (%narinfo-cache-directory): Pass #:ensure?
#f to 'cache-directory'.
|
|
|
|
| |
* guix/utils.scm (compressed-file?): Add "lzma" to the list.
|
|
|
|
|
|
|
|
|
| |
Fixes test failures related to xz compression in tests/utils.scm.
This is a followup to commit 63102406f22412bb922de5549deb89d3594a38c0.
* guix/utils.scm (decompressed-port, compressed-port, compressed-output-port):
Split each shell argument into its own list element.
|
|
|
|
|
|
| |
* guix/scripts/pack.scm (%compressors): Add flag '-T0' when calling "xz".
* guix/utils.scm (decompressed-port, compressed-port,
compressed-output-port): Same.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* guix/utils.scm (bytevector->base16-string, base16-string->bytevector):
Move to...
* guix/base16.scm: ... here. New file.
* tests/utils.scm ("bytevector->base16-string->bytevector"): Move to...
* tests/base16.scm: ... here. New file.
* Makefile.am (MODULES): Add guix/base16.scm.
(SCM_TESTS): Add tests/base16.scm.
* build-aux/download.scm, guix/derivations.scm,
guix/docker.scm, guix/import/snix.scm, guix/pk-crypto.scm,
guix/scripts/authenticate.scm, guix/scripts/download.scm,
guix/scripts/hash.scm, guix/store.scm, tests/hash.scm,
tests/pk-crypto.scm: Adjust imports accordingly.
|
|
|
|
|
|
|
|
| |
Fixes a regression introduced in 7447aa36e16fb77f75df4d3369db9c942615632e.
Reported by Ricardo Wurmus.
* guix/utils.scm: Revert 7447aa36e16fb77f75df4d3369db9c942615632e. Use
#:prefix for (ice-9 iconv) to support both 2.0 and 2.2.
|
|
|
|
|
|
|
| |
In Guile 2.2, (rnrs io ports) exports 'bytevector->string', which
conflicts with that of (ice-9 iconv).
* guix/utils.scm: Hide 'bytevector->string' from (rnrs io ports).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* gnu/packages.scm (find-newest-available-packages): Use 'mlambda'
instead of (memoize (lambda ...) ...).
* gnu/packages/bootstrap.scm (package-with-bootstrap-guile): Likewise.
* guix/build-system/gnu.scm (package-with-explicit-inputs)[rewritten-input]:
Likewise.
* guix/build-system/python.scm (package-with-explicit-python)[transform]:
Likewise.
* guix/derivations.scm (derivation->string): Likewise.
* guix/gnu-maintenance.scm (gnu-package?): Likewise.
* guix/modules.scm (module-file-dependencies): Likewise.
* guix/scripts/graph.scm (standard-package-set): Likewise.
* guix/scripts/lint.scm (official-gnu-packages*): Likewise.
* guix/store.scm (store-regexp*): Likewise.
* guix/utils.scm (location): Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* guix/combinators.scm (memoize): Remove.
* guix/memoization.scm: New file.
* Makefile.am (MODULES): Add it.
* gnu/packages.scm, gnu/packages/bootstrap.scm,
guix/build-system/gnu.scm, guix/build-system/python.scm,
guix/derivations.scm, guix/gnu-maintenance.scm,
guix/import/cran.scm, guix/import/elpa.scm,
guix/modules.scm, guix/scripts/build.scm,
guix/scripts/graph.scm, guix/scripts/lint.scm,
guix/store.scm, guix/utils.scm: Adjust imports accordingly.
|
|
|
|
|
|
|
|
|
| |
* guix/utils.scm (package-name->name+version): Add optional 'delimiter'
parameter.
* guix/scripts/package.scm (store-item->manifest-entry): Pass #\- as the
delimiter for 'package-name->name+version'. Use "out" instead of #f for
the 'output' field.
* tests/guix-package.sh: Add test.
|
|
|
|
|
|
|
|
|
|
| |
* guix/utils.scm (mingw-target?): New function.
* gnu/packages/cross-base.scm (cross-gcc-snippet): New procedure
(cross-gcc): Use it.
(cross-gcc-arguments, cross-gcc-patches, cross-gcc): Support MinGW.
(native-libc, cross-newlib?): New functions.
(cross-libc): Use cross-newlib? to support MinGW.
(%gcc-include-paths, %gcc-cross-include-paths): New variables.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reduces the closure of (guix ui) from 123 to 106 modules.
* guix/derivations.scm: Use (ice-9 binary-ports) instead of (rnrs io
ports).
(map-derivation)[substitute-file]: Use 'read-string' instead of
'get-string-all'.
* guix/ftp-client.scm: Likewise.
* guix/hash.scm: Likewise.
* guix/http-client.scm: Likewise.
* guix/pki.scm (ensure-acl, current-acl): Likewise.
* guix/scripts/archive.scm (authorize-key)[read-key]: Likewise.
* guix/scripts/authenticate.scm (read-canonical-sexp)
(read-hash-data): Likewise.
* guix/scripts/download.scm: Likewise.
* guix/scripts/offload.scm (register-gc-root, remove-gc-roots)
(send-files): Likewise.
* guix/scripts/publish.scm (lazy-read-file-sexp): Likewise.
* guix/scripts/refresh.scm: Likewise.
* guix/scripts/substitute.scm (check-acl-initialized): Likewise.
* guix/serialization.scm (read-maybe-utf8-string): Likewise.
* guix/scripts/hash.scm (guix-hash): Use 'force-output' instead of
'flush-output-port'.
* guix/store.scm (process-stderr): Likewise.
* guix/tests.scm: Likewise.
* guix/utils.scm: Use (ice-9 binary-ports) and autoload (rnrs io ports)
for 'make-custom-binary-input-port'.
|
|
|
|
|
|
|
| |
* guix/utils.scm (collect-default-args, expand-default-args): New
syntax.
(substitute-keyword-arguments): Allow default value declarations.
* tests/utils.scm (substitute-keyword-arguments): New test.
|
|
|
|
|
|
| |
* guix/utils.scm (default-keyword-arguments): Properly test for present
keywords.
* tests/utils.scm (default-keyword-arguments): New test.
|
|
|
|
|
|
|
| |
* guix/scripts/publish.scm (narinfo-string): Force %NO-COMPRESSION when
STORE-PATH matches 'compressed-file?'.
* guix/utils.scm (compressed-file?): New procedure.
* tests/publish.scm ("/*.narinfo for a compressed file"): New test.
|
|
|
|
|
|
|
|
| |
Fixes <http://bugs.gnu.org/23836>.
Fixes a regression introduced in f10dcbf1a92c147a2fedba6f774afa6a7013fcdf.
Reported by myglc2 <myglc2@gmail.com>.
* guix/utils.scm (cache-directory): Always append "/guix".
|
|
|
|
|
| |
* guix/utils.scm (cache-directory): Honor 'XDG_CACHE_HOME', not
'XDG_CONFIG_HOME'.
|
|
|
|
|
| |
* guix/utils.scm (current-source-directory): Add case for when FILE-NAME
is #f.
|
|
|
|
|
|
| |
* guix/utils.scm (absolute-dirname): New procedure.
(current-source-directory): Emit code to use it instead of calling
'search-path'.
|
|
|
|
|
| |
* guix/utils.scm (current-source-directory): When FILE-NAME is relative,
use 'search-path' to determine the absolute file name.
|
|
|
|
|
| |
* guix/utils.scm (extract-directory): Remove.
(current-source-directory): Rewrite as a 'syntax-case' macro.
|
|
|
|
|
|
| |
* guix/gexp.scm (extract-directory, current-source-directory): Move to...
* guix/utils.scm (extract-directory, current-source-directory):
... here. New procedures.
|
|
|
|
|
|
| |
Previously it could have left the file descriptor open.
* guix/utils.scm (with-atomic-file-output): Call 'close-port' in handler.
|
|
|
|
|
|
|
|
|
| |
Suggested by Danny Milosavljevic <dannym@scratchpost.org>
at <https://lists.gnu.org/archive/html/guix-devel/2016-06/msg00456.html>.
* guix/build/syscalls.scm (fdatasync): New procedure.
* guix/utils.scm (with-atomic-file-output): Use it. Use 'close-port'
instead of 'close'.
|
|
|
|
|
|
|
|
|
| |
Suggested by Ludovic Courtès <ludo@gnu.org>.
* guix/utils.scm: Re-export 'memoize' to avoid a potential breakage of
emacs interface. See
<http://lists.gnu.org/archive/html/guix-devel/2016-05/msg00146.html>
for details.
|
|
|
|
|
|
|
|
|
|
|
| |
* guix/utils.scm (%struct-flock, F_SETLKW, F_SETLK, F_xxLCK)
(fcntl-flock): Move to...
* guix/build/syscalls.scm: ... here. New variables.
* guix/nar.scm: Adjust imports accordingly.
* tests/utils.scm ("fcntl-flock wait", "fcntl-flock non-blocking"): Move
to...
* tests/syscalls.scm: ... here. New tests.
(temp-file): New variable.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* guix/utils.scm (compile-time-value, memoize, fold2)
(fold-tree, fold-tree-leaves): Move to...
* guix/combinators: ... here. New file.
* tests/utils.scm ("fold2, 1 list", "fold2, 2 lists")
(fold-tree tests): Move to...
* tests/combinators.scm: ... here. New file.
* Makefile.am (MODULES, SCM_TESTS): Add them.
* gnu/packages.scm, gnu/packages/bootstrap.scm,
gnu/services/herd.scm, guix/build-system/gnu.scm,
guix/build-system/python.scm, guix/derivations.scm,
guix/gnu-maintenance.scm, guix/import/elpa.scm,
guix/scripts/archive.scm, guix/scripts/build.scm,
guix/scripts/graph.scm, guix/scripts/lint.scm,
guix/scripts/size.scm, guix/scripts/substitute.scm,
guix/serialization.scm, guix/store.scm, guix/ui.scm: Adjust imports
accordingly.
|
|
|
|
|
|
|
|
| |
This procedure was redundant with SRFI-1's 'break'.
* guix/utils.scm (split): Remove.
* tests/utils.scm ("split, element is in list")
("split, element is not in list"): Remove.
|
|
|
|
|
|
| |
Fixes <http://bugs.gnu.org/23165>.
* guix/utils.scm (cache-directory): Use 'getpwuid' when 'HOME' is unset.
|
|
|
|
| |
* guix/utils (location-source->properties): New procedure.
|
|
|
|
|
| |
* guix/utils.scm (edit-expression): New procedure.
* tests/utils.scm (edit-expression): New test.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This provides the ability to use numbers in package names.
Fixes <http://bugs.gnu.org/19219>.
* guix/utils.scm (package-name->name+version): New procedure.
* gnu/packages.scm (%find-package): Add a FALLBACK? keyword argument.
Use the previous method when no package is found.
(specification->package+output, specification->package): Adapt
documentation to new syntax.
* doc/guix.texi (Invoking guix package, Invoking guix import): Likewise.
* guix/ui.scm (package-specification->name+version+output): Likewise.
* guix/scripts/import/hackage.scm (show-help): Likewise.
* tests/guix-build.sh: Adapt to new syntax.
* tests/guix-lint.sh: Likewise.
* tests/guix-package.sh: Likewise.
* tests/ui.scm ("package-specification->name+version+output"): Likewise.
* tests/utils.scm ("package-name->name+version"): Likewise.
* NEWS: Mention new syntax.
|
|
|
|
|
| |
* guix/utils.scm (delkw, ensure-keyword-arguments): New procedures.
* tests/utils.scm ("ensure-keyword-arguments"): New test.
|
|
|
|
|
| |
* guix/utils.scm (canonical-newline-port): New procedure.
* tests/utils.scm ("canonical-newline-port"): New test.
|
|
|
|
|
|
| |
* guix/ui.scm (switch-symlinks): Move to...
* guix/utils.scm: ... here. New procedure.
* guix/scripts/pull.scm: Use it.
|