2013-01-06 00:47:50 +01:00
|
|
|
|
;;; GNU Guix --- Functional package management for GNU
|
2020-01-06 15:14:09 +01:00
|
|
|
|
;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
|
Build newest versions unless specified, and implement upgrades.
* gnu/packages.scm (find-newest-available-packages):
New exported procedure.
* guix-build.in (newest-available-packages, find-best-packages-by-name):
New procedures.
(find-package): Use find-best-packages-by-name, to guarantee that
if a version number is not specified, only the newest versions will
be considered.
* guix-package.in (%options): Add --upgrade/-u option.
(newest-available-packages, find-best-packages-by-name, upgradeable?):
New procedures.
(find-package): Use find-best-packages-by-name, to guarantee that
if a version number is not specified, only the newest versions will
be considered.
(process-actions): Implement upgrade option.
* doc/guix.texi (Invoking guix-package): In the description of --install,
mention that if no version number is specified, the newest available
version will be selected.
2013-02-12 07:24:21 +01:00
|
|
|
|
;;; Copyright © 2013 Mark H Weaver <mhw@netris.org>
|
2020-02-05 18:47:31 +01:00
|
|
|
|
;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com>
|
2020-04-14 18:01:49 +02:00
|
|
|
|
;;; Copyright © 2020 Ricardo Wurmus <rekado@elephly.net>
|
2012-07-01 00:56:24 +02:00
|
|
|
|
;;;
|
2013-01-06 00:47:50 +01:00
|
|
|
|
;;; This file is part of GNU Guix.
|
2012-07-01 00:56:24 +02:00
|
|
|
|
;;;
|
2013-01-06 00:47:50 +01:00
|
|
|
|
;;; GNU Guix is free software; you can redistribute it and/or modify it
|
2012-07-01 00:56:24 +02:00
|
|
|
|
;;; under the terms of the GNU General Public License as published by
|
|
|
|
|
;;; the Free Software Foundation; either version 3 of the License, or (at
|
|
|
|
|
;;; your option) any later version.
|
|
|
|
|
;;;
|
2013-01-06 00:47:50 +01:00
|
|
|
|
;;; GNU Guix is distributed in the hope that it will be useful, but
|
2012-07-01 00:56:24 +02:00
|
|
|
|
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
;;; GNU General Public License for more details.
|
|
|
|
|
;;;
|
|
|
|
|
;;; You should have received a copy of the GNU General Public License
|
2013-01-06 00:47:50 +01:00
|
|
|
|
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
|
2012-07-01 00:56:24 +02:00
|
|
|
|
|
Replace individual scripts with master 'guix' script.
* scripts/guix.in: New script.
* Makefile.am (bin_SCRIPTS): Add 'scripts/guix'. Remove 'guix-build',
'guix-download', 'guix-import', 'guix-package', and 'guix-gc'.
(MODULES): Add 'guix/scripts/build.scm', 'guix/scripts/download.scm',
'guix/scripts/import.scm', 'guix/scripts/package.scm', and
'guix/scripts/gc.scm'.
* configure.ac (AC_CONFIG_FILES): Add 'scripts/guix'. Remove 'guix-build',
'guix-download', 'guix-import', 'guix-package', and 'guix-gc'.
* guix-build.in, guix-download.in, guix-gc.in, guix-import.in,
guix-package.in: Remove shell script boilerplate. Move to guix-COMMAND.in
to guix/scripts/COMMAND.scm. Rename module from (guix-COMMAND) to
(guix scripts COMMAND). Change "guix-COMMAND" to "guix COMMAND" in
usage help string.
* pre-inst-env.in: Add "@abs_top_builddir@/scripts" to the front of $PATH.
Export $GUIX_UNINSTALLED.
* tests/guix-build.sh, tests/guix-daemon.sh, tests/guix-download.sh,
tests/guix-gc.sh, tests/guix-package.sh: Use "guix COMMAND" instead of
"guix-COMMAND".
* doc/guix.texi: Replace all occurrences of "guix-COMMAND" with
"guix COMMAND".
* po/POTFILES.in: Update.
2013-02-14 10:15:25 +01:00
|
|
|
|
(define-module (guix scripts build)
|
2012-11-01 00:50:01 +01:00
|
|
|
|
#:use-module (guix ui)
|
2015-09-10 11:37:36 +02:00
|
|
|
|
#:use-module (guix scripts)
|
2020-04-14 18:01:49 +02:00
|
|
|
|
#:use-module (guix import json)
|
2012-07-01 00:56:24 +02:00
|
|
|
|
#:use-module (guix store)
|
|
|
|
|
#:use-module (guix derivations)
|
|
|
|
|
#:use-module (guix packages)
|
2020-09-28 18:56:00 +02:00
|
|
|
|
#:use-module (guix memoization)
|
2016-02-22 16:29:44 +01:00
|
|
|
|
#:use-module (guix grafts)
|
2016-03-23 22:32:44 +01:00
|
|
|
|
|
2017-12-22 23:40:57 +01:00
|
|
|
|
#:use-module (guix utils)
|
|
|
|
|
|
2016-03-23 22:32:44 +01:00
|
|
|
|
;; Use the procedure that destructures "NAME-VERSION" forms.
|
2017-12-22 23:40:57 +01:00
|
|
|
|
#:use-module ((guix build utils)
|
|
|
|
|
#:select ((package-name->name+version
|
|
|
|
|
. hyphen-package-name->name+version)))
|
2016-03-23 22:32:44 +01:00
|
|
|
|
|
2013-11-18 23:08:20 +01:00
|
|
|
|
#:use-module (guix monads)
|
2014-06-14 22:37:24 +02:00
|
|
|
|
#:use-module (guix gexp)
|
2020-02-05 18:47:31 +01:00
|
|
|
|
#:use-module (guix profiles)
|
2020-09-16 23:32:00 +02:00
|
|
|
|
#:use-module (guix diagnostics)
|
2015-09-10 23:10:50 +02:00
|
|
|
|
#:autoload (guix http-client) (http-fetch http-get-error?)
|
2012-07-01 00:56:24 +02:00
|
|
|
|
#:use-module (ice-9 format)
|
|
|
|
|
#:use-module (ice-9 match)
|
Build newest versions unless specified, and implement upgrades.
* gnu/packages.scm (find-newest-available-packages):
New exported procedure.
* guix-build.in (newest-available-packages, find-best-packages-by-name):
New procedures.
(find-package): Use find-best-packages-by-name, to guarantee that
if a version number is not specified, only the newest versions will
be considered.
* guix-package.in (%options): Add --upgrade/-u option.
(newest-available-packages, find-best-packages-by-name, upgradeable?):
New procedures.
(find-package): Use find-best-packages-by-name, to guarantee that
if a version number is not specified, only the newest versions will
be considered.
(process-actions): Implement upgrade option.
* doc/guix.texi (Invoking guix-package): In the description of --install,
mention that if no version number is specified, the newest available
version will be selected.
2013-02-12 07:24:21 +01:00
|
|
|
|
#:use-module (ice-9 vlist)
|
2012-07-01 00:56:24 +02:00
|
|
|
|
#:use-module (srfi srfi-1)
|
2020-10-28 16:37:35 +01:00
|
|
|
|
#:use-module (srfi srfi-9)
|
2013-01-22 22:13:10 +01:00
|
|
|
|
#:use-module (srfi srfi-11)
|
2012-07-01 00:56:24 +02:00
|
|
|
|
#:use-module (srfi srfi-26)
|
2012-10-27 14:56:38 +02:00
|
|
|
|
#:use-module (srfi srfi-34)
|
2020-09-16 23:32:00 +02:00
|
|
|
|
#:use-module (srfi srfi-35)
|
2012-07-01 00:56:24 +02:00
|
|
|
|
#:use-module (srfi srfi-37)
|
2020-01-07 10:35:02 +01:00
|
|
|
|
#:use-module (gnu packages)
|
2014-03-11 22:08:40 +01:00
|
|
|
|
#:autoload (guix download) (download-to-store)
|
2020-01-06 15:14:09 +01:00
|
|
|
|
#:autoload (guix git-download) (git-reference? git-reference-url)
|
2020-01-07 10:35:02 +01:00
|
|
|
|
#:autoload (guix git) (git-checkout git-checkout? git-checkout-url)
|
2019-02-11 23:05:36 +01:00
|
|
|
|
#:use-module ((guix status) #:select (with-status-verbosity))
|
2017-01-18 23:21:29 +01:00
|
|
|
|
#:use-module ((guix progress) #:select (current-terminal-columns))
|
|
|
|
|
#:use-module ((guix build syscalls) #:select (terminal-columns))
|
2014-03-13 19:21:49 +01:00
|
|
|
|
#:export (%standard-build-options
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
set-build-options-from-command-line
|
2015-05-21 00:48:10 +02:00
|
|
|
|
set-build-options-from-command-line*
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
show-build-options-help
|
2016-01-31 20:44:21 +01:00
|
|
|
|
|
|
|
|
|
%transformation-options
|
2016-01-31 20:18:52 +01:00
|
|
|
|
options->transformation
|
2020-09-24 22:13:06 +02:00
|
|
|
|
manifest-entry-with-transformations
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
|
2017-04-04 08:47:22 +02:00
|
|
|
|
guix-build
|
2017-04-05 05:24:54 +02:00
|
|
|
|
register-root
|
|
|
|
|
register-root*))
|
2012-07-01 00:56:24 +02:00
|
|
|
|
|
2015-09-10 23:10:50 +02:00
|
|
|
|
(define %default-log-urls
|
|
|
|
|
;; Default base URLs for build logs.
|
2019-05-01 11:05:47 +02:00
|
|
|
|
'("http://ci.guix.gnu.org/log"))
|
2015-09-10 23:10:50 +02:00
|
|
|
|
|
|
|
|
|
;; XXX: The following procedure cannot be in (guix store) because of the
|
|
|
|
|
;; dependency on (guix derivations).
|
|
|
|
|
(define* (log-url store file #:key (base-urls %default-log-urls))
|
|
|
|
|
"Return a URL under one of the BASE-URLS where a build log for FILE can be
|
|
|
|
|
found. Return #f if no build log was found."
|
|
|
|
|
(define (valid-url? url)
|
|
|
|
|
;; Probe URL and return #t if it is accessible.
|
2018-03-26 10:05:54 +02:00
|
|
|
|
(catch #t
|
2016-05-14 16:56:21 +02:00
|
|
|
|
(lambda ()
|
|
|
|
|
(guard (c ((http-get-error? c) #f))
|
|
|
|
|
(close-port (http-fetch url #:buffered? #f))
|
|
|
|
|
#t))
|
2018-03-26 10:05:54 +02:00
|
|
|
|
(match-lambda*
|
|
|
|
|
(('getaddrinfo-error . _)
|
|
|
|
|
#f)
|
|
|
|
|
(('tls-certificate-error args ...)
|
|
|
|
|
(report-error (G_ "cannot access build log at '~a':~%") url)
|
|
|
|
|
(print-exception (current-error-port) #f
|
|
|
|
|
'tls-certificate-error args)
|
|
|
|
|
(exit 1))
|
|
|
|
|
((key . args)
|
|
|
|
|
(apply throw key args)))))
|
2015-09-10 23:10:50 +02:00
|
|
|
|
|
|
|
|
|
(define (find-url file)
|
|
|
|
|
(let ((base (basename file)))
|
|
|
|
|
(any (lambda (base-url)
|
|
|
|
|
(let ((url (string-append base-url "/" base)))
|
|
|
|
|
(and (valid-url? url) url)))
|
|
|
|
|
base-urls)))
|
|
|
|
|
|
|
|
|
|
(cond ((derivation-path? file)
|
|
|
|
|
(catch 'system-error
|
|
|
|
|
(lambda ()
|
|
|
|
|
;; Usually we'll have more luck with the output file name since
|
|
|
|
|
;; the deriver that was used by the server could be different, so
|
|
|
|
|
;; try one of the output file names.
|
2017-06-12 17:11:22 +02:00
|
|
|
|
(let ((drv (read-derivation-from-file file)))
|
2015-09-10 23:10:50 +02:00
|
|
|
|
(or (find-url (derivation->output-path drv))
|
|
|
|
|
(find-url file))))
|
|
|
|
|
(lambda args
|
|
|
|
|
;; As a last resort, try the .drv.
|
|
|
|
|
(if (= ENOENT (system-error-errno args))
|
|
|
|
|
(find-url file)
|
|
|
|
|
(apply throw args)))))
|
|
|
|
|
(else
|
|
|
|
|
(find-url file))))
|
|
|
|
|
|
2013-12-21 22:53:58 +01:00
|
|
|
|
(define (register-root store paths root)
|
|
|
|
|
"Register ROOT as an indirect GC root for all of PATHS."
|
2017-01-18 16:57:56 +01:00
|
|
|
|
(let* ((root (if (string-prefix? "/" root)
|
|
|
|
|
root
|
|
|
|
|
(string-append (canonicalize-path (dirname root))
|
2019-04-15 16:57:12 +02:00
|
|
|
|
"/" (basename root)))))
|
2013-12-21 22:53:58 +01:00
|
|
|
|
(catch 'system-error
|
|
|
|
|
(lambda ()
|
|
|
|
|
(match paths
|
|
|
|
|
((path)
|
|
|
|
|
(symlink path root)
|
|
|
|
|
(add-indirect-root store root))
|
|
|
|
|
((paths ...)
|
|
|
|
|
(fold (lambda (path count)
|
|
|
|
|
(let ((root (string-append root
|
|
|
|
|
"-"
|
|
|
|
|
(number->string count))))
|
|
|
|
|
(symlink path root)
|
|
|
|
|
(add-indirect-root store root))
|
|
|
|
|
(+ 1 count))
|
|
|
|
|
0
|
|
|
|
|
paths))))
|
|
|
|
|
(lambda args
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(leave (G_ "failed to create GC root `~a': ~a~%")
|
2013-12-21 22:53:58 +01:00
|
|
|
|
root (strerror (system-error-errno args)))))))
|
|
|
|
|
|
2017-04-05 05:24:54 +02:00
|
|
|
|
(define register-root*
|
|
|
|
|
(store-lift register-root))
|
|
|
|
|
|
2017-12-22 23:40:57 +01:00
|
|
|
|
(define (numeric-extension? file-name)
|
|
|
|
|
"Return true if FILE-NAME ends with digits."
|
|
|
|
|
(string-every char-set:hex-digit (file-extension file-name)))
|
|
|
|
|
|
|
|
|
|
(define (tarball-base-name file-name)
|
|
|
|
|
"Return the \"base\" of FILE-NAME, removing '.tar.gz' or similar
|
|
|
|
|
extensions."
|
|
|
|
|
;; TODO: Factorize.
|
|
|
|
|
(cond ((not (file-extension file-name))
|
|
|
|
|
file-name)
|
|
|
|
|
((numeric-extension? file-name)
|
|
|
|
|
file-name)
|
|
|
|
|
((string=? (file-extension file-name) "tar")
|
|
|
|
|
(file-sans-extension file-name))
|
|
|
|
|
((file-extension file-name)
|
|
|
|
|
=>
|
|
|
|
|
(match-lambda
|
|
|
|
|
("scm" file-name)
|
|
|
|
|
(else (tarball-base-name (file-sans-extension file-name)))))
|
|
|
|
|
(else
|
|
|
|
|
file-name)))
|
|
|
|
|
|
2020-10-28 16:37:35 +01:00
|
|
|
|
|
|
|
|
|
;; Files to be downloaded.
|
|
|
|
|
(define-record-type <downloaded-file>
|
|
|
|
|
(downloaded-file uri recursive?)
|
|
|
|
|
downloaded-file?
|
|
|
|
|
(uri downloaded-file-uri)
|
|
|
|
|
(recursive? downloaded-file-recursive?))
|
|
|
|
|
|
|
|
|
|
(define download-to-store*
|
|
|
|
|
(store-lift download-to-store))
|
|
|
|
|
|
|
|
|
|
(define-gexp-compiler (compile-downloaded-file (file <downloaded-file>)
|
|
|
|
|
system target)
|
|
|
|
|
"Download FILE and return the result as a store item."
|
|
|
|
|
(match file
|
|
|
|
|
(($ <downloaded-file> uri recursive?)
|
|
|
|
|
(download-to-store* uri #:recursive? recursive?))))
|
|
|
|
|
|
|
|
|
|
(define* (package-with-source p uri #:optional version)
|
2014-03-11 22:08:40 +01:00
|
|
|
|
"Return a package based on P but with its source taken from URI. Extract
|
|
|
|
|
the new package's version number from URI."
|
|
|
|
|
(let ((base (tarball-base-name (basename uri))))
|
2017-12-22 23:40:57 +01:00
|
|
|
|
(let-values (((_ version*)
|
|
|
|
|
(hyphen-package-name->name+version base)))
|
2014-03-11 22:08:40 +01:00
|
|
|
|
(package (inherit p)
|
2017-12-22 23:40:57 +01:00
|
|
|
|
(version (or version version*
|
|
|
|
|
(package-version p)))
|
2015-06-11 11:19:12 +02:00
|
|
|
|
|
|
|
|
|
;; Use #:recursive? #t to allow for directories.
|
2020-10-28 16:40:08 +01:00
|
|
|
|
(source (downloaded-file uri #t))))))
|
2014-03-11 22:08:40 +01:00
|
|
|
|
|
2016-01-31 20:44:21 +01:00
|
|
|
|
|
|
|
|
|
;;;
|
|
|
|
|
;;; Transformations.
|
|
|
|
|
;;;
|
|
|
|
|
|
|
|
|
|
(define (transform-package-source sources)
|
|
|
|
|
"Return a transformation procedure that replaces package sources with the
|
|
|
|
|
matching URIs given in SOURCES."
|
|
|
|
|
(define new-sources
|
|
|
|
|
(map (lambda (uri)
|
2017-12-22 23:40:57 +01:00
|
|
|
|
(match (string-index uri #\=)
|
|
|
|
|
(#f
|
|
|
|
|
;; Determine the package name and version from URI.
|
|
|
|
|
(call-with-values
|
|
|
|
|
(lambda ()
|
|
|
|
|
(hyphen-package-name->name+version
|
|
|
|
|
(tarball-base-name (basename uri))))
|
|
|
|
|
(lambda (name version)
|
|
|
|
|
(list name version uri))))
|
|
|
|
|
(index
|
|
|
|
|
;; What's before INDEX is a "PKG@VER" or "PKG" spec.
|
|
|
|
|
(call-with-values
|
|
|
|
|
(lambda ()
|
|
|
|
|
(package-name->name+version (string-take uri index)))
|
|
|
|
|
(lambda (name version)
|
|
|
|
|
(list name version
|
|
|
|
|
(string-drop uri (+ 1 index))))))))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
sources))
|
|
|
|
|
|
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(let loop ((sources new-sources)
|
|
|
|
|
(result '()))
|
|
|
|
|
(match obj
|
|
|
|
|
((? package? p)
|
2017-12-22 23:40:57 +01:00
|
|
|
|
(match (assoc-ref sources (package-name p))
|
|
|
|
|
((version source)
|
2020-10-28 16:37:35 +01:00
|
|
|
|
(package-with-source p source version))
|
2017-12-22 23:40:57 +01:00
|
|
|
|
(#f
|
|
|
|
|
p)))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
(_
|
|
|
|
|
obj)))))
|
|
|
|
|
|
2016-10-17 22:43:49 +02:00
|
|
|
|
(define (evaluate-replacement-specs specs proc)
|
2019-03-13 10:11:54 +01:00
|
|
|
|
"Parse SPECS, a list of strings like \"guile=guile@2.1\" and return a list
|
|
|
|
|
of package spec/procedure pairs as expected by 'package-input-rewriting/spec'.
|
|
|
|
|
PROC is called with the package to be replaced and its replacement according
|
|
|
|
|
to SPECS. Raise an error if an element of SPECS uses invalid syntax, or if a
|
|
|
|
|
package it refers to could not be found."
|
2016-01-31 23:22:18 +01:00
|
|
|
|
(define not-equal
|
|
|
|
|
(char-set-complement (char-set #\=)))
|
|
|
|
|
|
2016-10-17 22:43:49 +02:00
|
|
|
|
(map (lambda (spec)
|
|
|
|
|
(match (string-tokenize spec not-equal)
|
2019-03-13 10:11:54 +01:00
|
|
|
|
((spec new)
|
|
|
|
|
(cons spec
|
|
|
|
|
(let ((new (specification->package new)))
|
|
|
|
|
(lambda (old)
|
|
|
|
|
(proc old new)))))
|
2016-10-17 22:43:49 +02:00
|
|
|
|
(x
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(leave (G_ "invalid replacement specification: ~s~%") spec))))
|
2016-10-17 22:43:49 +02:00
|
|
|
|
specs))
|
|
|
|
|
|
|
|
|
|
(define (transform-package-inputs replacement-specs)
|
|
|
|
|
"Return a procedure that, when passed a package, replaces its direct
|
|
|
|
|
dependencies according to REPLACEMENT-SPECS. REPLACEMENT-SPECS is a list of
|
|
|
|
|
strings like \"guile=guile@2.1\" meaning that, any dependency on a package
|
|
|
|
|
called \"guile\" must be replaced with a dependency on a version 2.1 of
|
|
|
|
|
\"guile\"."
|
2019-03-13 10:11:54 +01:00
|
|
|
|
(let* ((replacements (evaluate-replacement-specs replacement-specs
|
|
|
|
|
(lambda (old new)
|
|
|
|
|
new)))
|
|
|
|
|
(rewrite (package-input-rewriting/spec replacements)))
|
2016-09-01 22:39:41 +02:00
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(rewrite obj)
|
|
|
|
|
obj))))
|
2016-01-31 23:22:18 +01:00
|
|
|
|
|
2016-10-17 23:40:03 +02:00
|
|
|
|
(define (transform-package-inputs/graft replacement-specs)
|
|
|
|
|
"Return a procedure that, when passed a package, replaces its direct
|
|
|
|
|
dependencies according to REPLACEMENT-SPECS. REPLACEMENT-SPECS is a list of
|
|
|
|
|
strings like \"gnutls=gnutls@3.5.4\" meaning that packages are built using the
|
|
|
|
|
current 'gnutls' package, after which version 3.5.4 is grafted onto them."
|
2019-03-13 10:11:54 +01:00
|
|
|
|
(define (set-replacement old new)
|
|
|
|
|
(package (inherit old) (replacement new)))
|
2016-10-17 23:40:03 +02:00
|
|
|
|
|
|
|
|
|
(let* ((replacements (evaluate-replacement-specs replacement-specs
|
2019-03-13 10:11:54 +01:00
|
|
|
|
set-replacement))
|
|
|
|
|
(rewrite (package-input-rewriting/spec replacements)))
|
2016-10-17 23:40:03 +02:00
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(rewrite obj)
|
|
|
|
|
obj))))
|
|
|
|
|
|
2019-03-12 15:50:13 +01:00
|
|
|
|
(define %not-equal
|
|
|
|
|
(char-set-complement (char-set #\=)))
|
|
|
|
|
|
2019-03-12 22:12:18 +01:00
|
|
|
|
(define (package-git-url package)
|
|
|
|
|
"Return the URL of the Git repository for package, or raise an error if
|
|
|
|
|
the source of PACKAGE is not fetched from a Git repository."
|
|
|
|
|
(let ((source (package-source package)))
|
|
|
|
|
(cond ((and (origin? source)
|
|
|
|
|
(git-reference? (origin-uri source)))
|
|
|
|
|
(git-reference-url (origin-uri source)))
|
|
|
|
|
((git-checkout? source)
|
|
|
|
|
(git-checkout-url source))
|
|
|
|
|
(else
|
|
|
|
|
(leave (G_ "the source of ~a is not a Git reference~%")
|
|
|
|
|
(package-full-name package))))))
|
|
|
|
|
|
2018-11-30 13:24:48 +01:00
|
|
|
|
(define (evaluate-git-replacement-specs specs proc)
|
2018-11-27 15:34:34 +01:00
|
|
|
|
"Parse SPECS, a list of strings like \"guile=stable-2.2\", and return a list
|
2018-11-30 13:24:48 +01:00
|
|
|
|
of package pairs, where (PROC PACKAGE URL BRANCH-OR-COMMIT) returns the
|
|
|
|
|
replacement package. Raise an error if an element of SPECS uses invalid
|
|
|
|
|
syntax, or if a package it refers to could not be found."
|
2018-11-27 15:34:34 +01:00
|
|
|
|
(map (lambda (spec)
|
2019-03-12 15:50:13 +01:00
|
|
|
|
(match (string-tokenize spec %not-equal)
|
2019-03-13 10:11:54 +01:00
|
|
|
|
((spec branch-or-commit)
|
|
|
|
|
(define (replace old)
|
|
|
|
|
(let* ((source (package-source old))
|
|
|
|
|
(url (package-git-url old)))
|
|
|
|
|
(proc old url branch-or-commit)))
|
|
|
|
|
|
|
|
|
|
(cons spec replace))
|
2018-11-27 15:34:34 +01:00
|
|
|
|
(x
|
|
|
|
|
(leave (G_ "invalid replacement specification: ~s~%") spec))))
|
|
|
|
|
specs))
|
|
|
|
|
|
|
|
|
|
(define (transform-package-source-branch replacement-specs)
|
|
|
|
|
"Return a procedure that, when passed a package, replaces its direct
|
|
|
|
|
dependencies according to REPLACEMENT-SPECS. REPLACEMENT-SPECS is a list of
|
|
|
|
|
strings like \"guile-next=stable-3.0\" meaning that packages are built using
|
|
|
|
|
'guile-next' from the latest commit on its 'stable-3.0' branch."
|
2018-11-30 13:24:48 +01:00
|
|
|
|
(define (replace old url branch)
|
|
|
|
|
(package
|
|
|
|
|
(inherit old)
|
2019-03-13 10:33:17 +01:00
|
|
|
|
(version (string-append "git." (string-map (match-lambda
|
|
|
|
|
(#\/ #\-)
|
|
|
|
|
(chr chr))
|
|
|
|
|
branch)))
|
2019-02-08 09:29:39 +01:00
|
|
|
|
(source (git-checkout (url url) (branch branch)
|
|
|
|
|
(recursive? #t)))))
|
2018-11-30 13:24:48 +01:00
|
|
|
|
|
|
|
|
|
(let* ((replacements (evaluate-git-replacement-specs replacement-specs
|
|
|
|
|
replace))
|
2019-03-13 10:11:54 +01:00
|
|
|
|
(rewrite (package-input-rewriting/spec replacements)))
|
2018-11-30 13:24:48 +01:00
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(rewrite obj)
|
|
|
|
|
obj))))
|
|
|
|
|
|
|
|
|
|
(define (transform-package-source-commit replacement-specs)
|
|
|
|
|
"Return a procedure that, when passed a package, replaces its direct
|
|
|
|
|
dependencies according to REPLACEMENT-SPECS. REPLACEMENT-SPECS is a list of
|
|
|
|
|
strings like \"guile-next=cabba9e\" meaning that packages are built using
|
|
|
|
|
'guile-next' from commit 'cabba9e'."
|
|
|
|
|
(define (replace old url commit)
|
|
|
|
|
(package
|
|
|
|
|
(inherit old)
|
2019-07-26 11:17:31 +02:00
|
|
|
|
(version (if (and (> (string-length commit) 1)
|
|
|
|
|
(string-prefix? "v" commit)
|
|
|
|
|
(char-set-contains? char-set:digit
|
|
|
|
|
(string-ref commit 1)))
|
|
|
|
|
(string-drop commit 1) ;looks like a tag like "v1.0"
|
|
|
|
|
(string-append "git."
|
|
|
|
|
(if (< (string-length commit) 7)
|
|
|
|
|
commit
|
|
|
|
|
(string-take commit 7)))))
|
2019-03-13 10:26:31 +01:00
|
|
|
|
(source (git-checkout (url url) (commit commit)
|
|
|
|
|
(recursive? #t)))))
|
2018-11-30 13:24:48 +01:00
|
|
|
|
|
|
|
|
|
(let* ((replacements (evaluate-git-replacement-specs replacement-specs
|
|
|
|
|
replace))
|
2019-03-13 10:11:54 +01:00
|
|
|
|
(rewrite (package-input-rewriting/spec replacements)))
|
2018-11-27 15:34:34 +01:00
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(rewrite obj)
|
|
|
|
|
obj))))
|
|
|
|
|
|
2019-03-12 15:50:13 +01:00
|
|
|
|
(define (transform-package-source-git-url replacement-specs)
|
|
|
|
|
"Return a procedure that, when passed a package, replaces its dependencies
|
|
|
|
|
according to REPLACEMENT-SPECS. REPLACEMENT-SPECS is a list of strings like
|
|
|
|
|
\"guile-json=https://gitthing.com/…\" meaning that packages are built using
|
|
|
|
|
a checkout of the Git repository at the given URL."
|
|
|
|
|
(define replacements
|
|
|
|
|
(map (lambda (spec)
|
|
|
|
|
(match (string-tokenize spec %not-equal)
|
2019-03-13 10:11:54 +01:00
|
|
|
|
((spec url)
|
|
|
|
|
(cons spec
|
|
|
|
|
(lambda (old)
|
|
|
|
|
(package
|
|
|
|
|
(inherit old)
|
|
|
|
|
(source (git-checkout (url url)
|
2019-05-14 12:08:03 +02:00
|
|
|
|
(recursive? #t)))))))
|
|
|
|
|
(_
|
|
|
|
|
(leave (G_ "~a: invalid Git URL replacement specification~%")
|
|
|
|
|
spec))))
|
2019-03-12 15:50:13 +01:00
|
|
|
|
replacement-specs))
|
|
|
|
|
|
|
|
|
|
(define rewrite
|
2019-03-13 10:11:54 +01:00
|
|
|
|
(package-input-rewriting/spec replacements))
|
2019-03-12 15:50:13 +01:00
|
|
|
|
|
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(rewrite obj)
|
|
|
|
|
obj)))
|
|
|
|
|
|
2020-09-28 18:56:00 +02:00
|
|
|
|
(define (package-dependents/spec top bottom)
|
|
|
|
|
"Return the list of dependents of BOTTOM, a spec string, that are also
|
|
|
|
|
dependencies of TOP, a package."
|
|
|
|
|
(define-values (name version)
|
|
|
|
|
(package-name->name+version bottom))
|
|
|
|
|
|
|
|
|
|
(define dependent?
|
|
|
|
|
(mlambda (p)
|
|
|
|
|
(and (package? p)
|
|
|
|
|
(or (and (string=? name (package-name p))
|
|
|
|
|
(or (not version)
|
|
|
|
|
(version-prefix? version (package-version p))))
|
|
|
|
|
(match (bag-direct-inputs (package->bag p))
|
|
|
|
|
(((labels dependencies . _) ...)
|
|
|
|
|
(any dependent? dependencies)))))))
|
|
|
|
|
|
|
|
|
|
(filter dependent? (package-closure (list top))))
|
|
|
|
|
|
|
|
|
|
(define (package-toolchain-rewriting p bottom toolchain)
|
|
|
|
|
"Return a procedure that, when passed a package that's either BOTTOM or one
|
|
|
|
|
of its dependents up to P so, changes it so it is built with TOOLCHAIN.
|
|
|
|
|
TOOLCHAIN must be an input list."
|
|
|
|
|
(define rewriting-property
|
|
|
|
|
(gensym " package-toolchain-rewriting"))
|
|
|
|
|
|
|
|
|
|
(match (package-dependents/spec p bottom)
|
|
|
|
|
(() ;P does not depend on BOTTOM
|
|
|
|
|
identity)
|
|
|
|
|
(set
|
|
|
|
|
;; SET is the list of packages "between" P and BOTTOM (included) whose
|
|
|
|
|
;; toolchain needs to be changed.
|
|
|
|
|
(package-mapping (lambda (p)
|
|
|
|
|
(if (or (assq rewriting-property
|
|
|
|
|
(package-properties p))
|
|
|
|
|
(not (memq p set)))
|
|
|
|
|
p
|
|
|
|
|
(let ((p (package-with-c-toolchain p toolchain)))
|
|
|
|
|
(package/inherit p
|
|
|
|
|
(properties `((,rewriting-property . #t)
|
|
|
|
|
,@(package-properties p)))))))
|
|
|
|
|
(lambda (p)
|
|
|
|
|
(or (assq rewriting-property (package-properties p))
|
|
|
|
|
(not (memq p set))))
|
|
|
|
|
#:deep? #t))))
|
|
|
|
|
|
|
|
|
|
(define (transform-package-toolchain replacement-specs)
|
|
|
|
|
"Return a procedure that, when passed a package, changes its toolchain or
|
|
|
|
|
that of its dependencies according to REPLACEMENT-SPECS. REPLACEMENT-SPECS is
|
|
|
|
|
a list of strings like \"fftw=gcc-toolchain@10\" meaning that the package to
|
|
|
|
|
the left of the equal sign must be built with the toolchain to the right of
|
|
|
|
|
the equal sign."
|
|
|
|
|
(define split-on-commas
|
|
|
|
|
(cute string-tokenize <> (char-set-complement (char-set #\,))))
|
|
|
|
|
|
|
|
|
|
(define (specification->input spec)
|
|
|
|
|
(let ((package (specification->package spec)))
|
|
|
|
|
(list (package-name package) package)))
|
|
|
|
|
|
|
|
|
|
(define replacements
|
|
|
|
|
(map (lambda (spec)
|
|
|
|
|
(match (string-tokenize spec %not-equal)
|
|
|
|
|
((spec (= split-on-commas toolchain))
|
|
|
|
|
(cons spec (map specification->input toolchain)))
|
|
|
|
|
(_
|
|
|
|
|
(leave (G_ "~a: invalid toolchain replacement specification~%")
|
|
|
|
|
spec))))
|
|
|
|
|
replacement-specs))
|
|
|
|
|
|
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(or (any (match-lambda
|
|
|
|
|
((bottom . toolchain)
|
|
|
|
|
((package-toolchain-rewriting obj bottom toolchain) obj)))
|
|
|
|
|
replacements)
|
|
|
|
|
obj)
|
|
|
|
|
obj)))
|
|
|
|
|
|
2020-10-09 18:17:41 +02:00
|
|
|
|
(define (transform-package-with-debug-info specs)
|
|
|
|
|
"Return a procedure that, when passed a package, set its 'replacement' field
|
|
|
|
|
to the same package but with #:strip-binaries? #f in its 'arguments' field."
|
|
|
|
|
(define (non-stripped p)
|
|
|
|
|
(package
|
|
|
|
|
(inherit p)
|
|
|
|
|
(arguments
|
|
|
|
|
(substitute-keyword-arguments (package-arguments p)
|
|
|
|
|
((#:strip-binaries? _ #f) #f)))))
|
|
|
|
|
|
|
|
|
|
(define (package-with-debug-info p)
|
|
|
|
|
(if (member "debug" (package-outputs p))
|
|
|
|
|
p
|
|
|
|
|
(let loop ((p p))
|
|
|
|
|
(match (package-replacement p)
|
|
|
|
|
(#f
|
|
|
|
|
(package
|
|
|
|
|
(inherit p)
|
|
|
|
|
(replacement (non-stripped p))))
|
|
|
|
|
(next
|
|
|
|
|
(package
|
|
|
|
|
(inherit p)
|
|
|
|
|
(replacement (loop next))))))))
|
|
|
|
|
|
|
|
|
|
(define rewrite
|
|
|
|
|
(package-input-rewriting/spec (map (lambda (spec)
|
|
|
|
|
(cons spec package-with-debug-info))
|
|
|
|
|
specs)))
|
|
|
|
|
|
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(rewrite obj)
|
|
|
|
|
obj)))
|
|
|
|
|
|
2020-09-23 22:29:17 +02:00
|
|
|
|
(define (transform-package-tests specs)
|
|
|
|
|
"Return a procedure that, when passed a package, sets #:tests? #f in its
|
|
|
|
|
'arguments' field."
|
|
|
|
|
(define (package-without-tests p)
|
|
|
|
|
(package/inherit p
|
|
|
|
|
(arguments
|
|
|
|
|
(substitute-keyword-arguments (package-arguments p)
|
|
|
|
|
((#:tests? _ #f) #f)))))
|
|
|
|
|
|
|
|
|
|
(define rewrite
|
|
|
|
|
(package-input-rewriting/spec (map (lambda (spec)
|
|
|
|
|
(cons spec package-without-tests))
|
|
|
|
|
specs)))
|
|
|
|
|
|
|
|
|
|
(lambda (store obj)
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(rewrite obj)
|
|
|
|
|
obj)))
|
|
|
|
|
|
2016-01-31 20:44:21 +01:00
|
|
|
|
(define %transformations
|
|
|
|
|
;; Transformations that can be applied to things to build. The car is the
|
|
|
|
|
;; key used in the option alist, and the cdr is the transformation
|
|
|
|
|
;; procedure; it is called with two arguments: the store, and a list of
|
|
|
|
|
;; things to build.
|
2016-01-31 23:22:18 +01:00
|
|
|
|
`((with-source . ,transform-package-source)
|
2016-10-17 23:40:03 +02:00
|
|
|
|
(with-input . ,transform-package-inputs)
|
2018-11-27 15:34:34 +01:00
|
|
|
|
(with-graft . ,transform-package-inputs/graft)
|
2018-11-30 13:24:48 +01:00
|
|
|
|
(with-branch . ,transform-package-source-branch)
|
2019-03-12 15:50:13 +01:00
|
|
|
|
(with-commit . ,transform-package-source-commit)
|
2020-09-23 22:29:17 +02:00
|
|
|
|
(with-git-url . ,transform-package-source-git-url)
|
2020-09-28 18:56:00 +02:00
|
|
|
|
(with-c-toolchain . ,transform-package-toolchain)
|
2020-10-09 18:17:41 +02:00
|
|
|
|
(with-debug-info . ,transform-package-with-debug-info)
|
2020-09-23 22:29:17 +02:00
|
|
|
|
(without-tests . ,transform-package-tests)))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
|
2020-09-24 22:13:06 +02:00
|
|
|
|
(define (transformation-procedure key)
|
|
|
|
|
"Return the transformation procedure associated with KEY, a symbol such as
|
|
|
|
|
'with-source', or #f if there is none."
|
|
|
|
|
(any (match-lambda
|
|
|
|
|
((k . proc)
|
|
|
|
|
(and (eq? k key) proc)))
|
|
|
|
|
%transformations))
|
|
|
|
|
|
2016-01-31 20:44:21 +01:00
|
|
|
|
(define %transformation-options
|
|
|
|
|
;; The command-line interface to the above transformations.
|
2016-10-17 22:51:38 +02:00
|
|
|
|
(let ((parser (lambda (symbol)
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons symbol arg result)
|
|
|
|
|
rest)))))
|
|
|
|
|
(list (option '("with-source") #t #f
|
|
|
|
|
(parser 'with-source))
|
|
|
|
|
(option '("with-input") #t #f
|
2016-10-17 23:40:03 +02:00
|
|
|
|
(parser 'with-input))
|
|
|
|
|
(option '("with-graft") #t #f
|
2018-11-27 15:34:34 +01:00
|
|
|
|
(parser 'with-graft))
|
|
|
|
|
(option '("with-branch") #t #f
|
2018-11-30 13:24:48 +01:00
|
|
|
|
(parser 'with-branch))
|
|
|
|
|
(option '("with-commit") #t #f
|
2019-03-12 15:50:13 +01:00
|
|
|
|
(parser 'with-commit))
|
|
|
|
|
(option '("with-git-url") #t #f
|
2020-09-23 22:29:17 +02:00
|
|
|
|
(parser 'with-git-url))
|
2020-09-28 18:56:00 +02:00
|
|
|
|
(option '("with-c-toolchain") #t #f
|
|
|
|
|
(parser 'with-c-toolchain))
|
2020-10-09 18:17:41 +02:00
|
|
|
|
(option '("with-debug-info") #t #f
|
|
|
|
|
(parser 'with-debug-info))
|
2020-09-23 22:29:17 +02:00
|
|
|
|
(option '("without-tests") #t #f
|
|
|
|
|
(parser 'without-tests)))))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
|
|
|
|
|
(define (show-transformation-options-help)
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2020-09-16 00:17:29 +02:00
|
|
|
|
--with-source=[PACKAGE=]SOURCE
|
2016-01-31 23:22:18 +01:00
|
|
|
|
use SOURCE when building the corresponding package"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2016-01-31 23:22:18 +01:00
|
|
|
|
--with-input=PACKAGE=REPLACEMENT
|
2016-10-17 23:40:03 +02:00
|
|
|
|
replace dependency PACKAGE by REPLACEMENT"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2016-10-17 23:40:03 +02:00
|
|
|
|
--with-graft=PACKAGE=REPLACEMENT
|
2018-11-27 15:34:34 +01:00
|
|
|
|
graft REPLACEMENT on packages that refer to PACKAGE"))
|
2018-11-30 13:24:48 +01:00
|
|
|
|
(display (G_ "
|
2018-11-27 15:34:34 +01:00
|
|
|
|
--with-branch=PACKAGE=BRANCH
|
2018-11-30 13:24:48 +01:00
|
|
|
|
build PACKAGE from the latest commit of BRANCH"))
|
|
|
|
|
(display (G_ "
|
|
|
|
|
--with-commit=PACKAGE=COMMIT
|
2019-03-12 15:50:13 +01:00
|
|
|
|
build PACKAGE from COMMIT"))
|
|
|
|
|
(display (G_ "
|
|
|
|
|
--with-git-url=PACKAGE=URL
|
2020-09-23 22:29:17 +02:00
|
|
|
|
build PACKAGE from the repository at URL"))
|
2020-09-28 18:56:00 +02:00
|
|
|
|
(display (G_ "
|
|
|
|
|
--with-c-toolchain=PACKAGE=TOOLCHAIN
|
|
|
|
|
build PACKAGE and its dependents with TOOLCHAIN"))
|
2020-10-09 18:17:41 +02:00
|
|
|
|
(display (G_ "
|
|
|
|
|
--with-debug-info=PACKAGE
|
|
|
|
|
build PACKAGE and preserve its debug info"))
|
2020-09-23 22:29:17 +02:00
|
|
|
|
(display (G_ "
|
|
|
|
|
--without-tests=PACKAGE
|
|
|
|
|
build PACKAGE without running its tests")))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(define (options->transformation opts)
|
|
|
|
|
"Return a procedure that, when passed an object to build (package,
|
|
|
|
|
derivation, etc.), applies the transformations specified by OPTS."
|
|
|
|
|
(define applicable
|
2019-03-13 10:11:54 +01:00
|
|
|
|
;; List of applicable transformations as symbol/procedure pairs in the
|
|
|
|
|
;; order in which they appear on the command line.
|
2016-01-31 20:44:21 +01:00
|
|
|
|
(filter-map (match-lambda
|
2019-03-13 10:11:54 +01:00
|
|
|
|
((key . value)
|
2020-09-24 22:13:06 +02:00
|
|
|
|
(match (transformation-procedure key)
|
2019-03-13 10:11:54 +01:00
|
|
|
|
(#f
|
|
|
|
|
#f)
|
|
|
|
|
(transform
|
|
|
|
|
;; XXX: We used to pass TRANSFORM a list of several
|
|
|
|
|
;; arguments, but we now pass only one, assuming that
|
|
|
|
|
;; transform composes well.
|
2020-09-24 22:13:06 +02:00
|
|
|
|
(list key value (transform (list value)))))))
|
2019-03-13 10:11:54 +01:00
|
|
|
|
(reverse opts)))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
|
2020-09-24 22:13:06 +02:00
|
|
|
|
(define (package-with-transformation-properties p)
|
|
|
|
|
(package/inherit p
|
|
|
|
|
(properties `((transformations
|
|
|
|
|
. ,(map (match-lambda
|
|
|
|
|
((key value _)
|
|
|
|
|
(cons key value)))
|
|
|
|
|
applicable))
|
|
|
|
|
,@(package-properties p)))))
|
|
|
|
|
|
2016-01-31 20:44:21 +01:00
|
|
|
|
(lambda (store obj)
|
2020-09-24 22:13:06 +02:00
|
|
|
|
(define (tagged-object new)
|
|
|
|
|
(if (and (not (eq? obj new))
|
|
|
|
|
(package? new) (not (null? applicable)))
|
|
|
|
|
(package-with-transformation-properties new)
|
|
|
|
|
new))
|
|
|
|
|
|
|
|
|
|
(tagged-object
|
|
|
|
|
(fold (match-lambda*
|
|
|
|
|
(((name value transform) obj)
|
|
|
|
|
(let ((new (transform store obj)))
|
|
|
|
|
(when (eq? new obj)
|
|
|
|
|
(warning (G_ "transformation '~a' had no effect on ~a~%")
|
|
|
|
|
name
|
|
|
|
|
(if (package? obj)
|
|
|
|
|
(package-full-name obj)
|
|
|
|
|
obj)))
|
|
|
|
|
new)))
|
|
|
|
|
obj
|
|
|
|
|
applicable))))
|
|
|
|
|
|
|
|
|
|
(define (package-transformations package)
|
|
|
|
|
"Return the transformations applied to PACKAGE according to its properties."
|
|
|
|
|
(match (assq-ref (package-properties package) 'transformations)
|
|
|
|
|
(#f '())
|
|
|
|
|
(transformations transformations)))
|
|
|
|
|
|
|
|
|
|
(define (manifest-entry-with-transformations entry)
|
|
|
|
|
"Return ENTRY with an additional 'transformations' property if it's not
|
|
|
|
|
already there."
|
|
|
|
|
(let ((properties (manifest-entry-properties entry)))
|
|
|
|
|
(if (assq 'transformations properties)
|
|
|
|
|
entry
|
|
|
|
|
(let ((item (manifest-entry-item entry)))
|
|
|
|
|
(manifest-entry
|
|
|
|
|
(inherit entry)
|
|
|
|
|
(properties
|
|
|
|
|
(match (and (package? item)
|
|
|
|
|
(package-transformations item))
|
|
|
|
|
((or #f '())
|
|
|
|
|
properties)
|
|
|
|
|
(transformations
|
|
|
|
|
`((transformations . ,transformations)
|
|
|
|
|
,@properties)))))))))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
|
2012-07-01 00:56:24 +02:00
|
|
|
|
|
|
|
|
|
;;;
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
;;; Standard command-line build options.
|
2012-07-01 00:56:24 +02:00
|
|
|
|
;;;
|
|
|
|
|
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(define (show-build-options-help)
|
|
|
|
|
"Display on the current output port help about the standard command-line
|
|
|
|
|
options handled by 'set-build-options-from-command-line', and listed in
|
|
|
|
|
'%standard-build-options'."
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2014-09-24 11:26:30 +02:00
|
|
|
|
-L, --load-path=DIR prepend DIR to the package module search path"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2012-07-01 00:56:24 +02:00
|
|
|
|
-K, --keep-failed keep build tree of failed builds"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2016-01-19 21:57:40 +01:00
|
|
|
|
-k, --keep-going keep going when some of the derivations fail"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2012-07-01 00:56:24 +02:00
|
|
|
|
-n, --dry-run do not build the derivations"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2013-05-29 23:08:06 +02:00
|
|
|
|
--fallback fall back to building when the substituter fails"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2012-10-24 15:01:16 +02:00
|
|
|
|
--no-substitutes build instead of resorting to pre-built substitutes"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2015-07-13 16:07:59 +02:00
|
|
|
|
--substitute-urls=URLS
|
|
|
|
|
fetch substitute from URLS if they are authorized"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2016-03-02 13:43:13 +01:00
|
|
|
|
--no-grafts do not graft packages"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2019-11-21 15:14:33 +01:00
|
|
|
|
--no-offload do not attempt to offload builds"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2013-05-20 18:14:55 +02:00
|
|
|
|
--max-silent-time=SECONDS
|
|
|
|
|
mark the build as failed after SECONDS of silence"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2014-03-09 23:09:18 +01:00
|
|
|
|
--timeout=SECONDS mark the build as failed after SECONDS of activity"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2015-12-08 23:27:53 +01:00
|
|
|
|
--rounds=N build N times in a row to detect non-determinism"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2014-11-25 22:32:26 +01:00
|
|
|
|
-c, --cores=N allow the use of up to N CPU cores for the build"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
-M, --max-jobs=N allow at most N build jobs"))
|
2020-10-12 15:16:51 +02:00
|
|
|
|
(display (G_ "
|
|
|
|
|
--help-transform list package transformation options not shown here"))
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
(display (G_ "
|
|
|
|
|
--debug=LEVEL produce debugging output at LEVEL")))
|
2012-07-01 00:56:24 +02:00
|
|
|
|
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(define (set-build-options-from-command-line store opts)
|
|
|
|
|
"Given OPTS, an alist as returned by 'args-fold' given
|
|
|
|
|
'%standard-build-options', set the corresponding build options on STORE."
|
2019-10-24 18:15:15 +02:00
|
|
|
|
|
|
|
|
|
;; '--keep-failed' has no effect when talking to a remote daemon. Catch the
|
|
|
|
|
;; case where GUIX_DAEMON_SOCKET=guix://….
|
|
|
|
|
(when (and (assoc-ref opts 'keep-failed?)
|
|
|
|
|
(let* ((socket (store-connection-socket store))
|
|
|
|
|
(peer (catch 'system-error
|
|
|
|
|
(lambda ()
|
|
|
|
|
(and (file-port? socket)
|
|
|
|
|
(getpeername socket)))
|
|
|
|
|
(const #f))))
|
|
|
|
|
(and peer (not (= AF_UNIX (sockaddr:fam peer))))))
|
|
|
|
|
(warning (G_ "'--keep-failed' ignored since you are \
|
|
|
|
|
talking to a remote daemon\n")))
|
|
|
|
|
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(set-build-options store
|
|
|
|
|
#:keep-failed? (assoc-ref opts 'keep-failed?)
|
2016-01-19 21:57:40 +01:00
|
|
|
|
#:keep-going? (assoc-ref opts 'keep-going?)
|
2015-12-08 23:27:53 +01:00
|
|
|
|
#:rounds (assoc-ref opts 'rounds)
|
2017-01-15 15:32:43 +01:00
|
|
|
|
#:build-cores (assoc-ref opts 'cores)
|
|
|
|
|
#:max-build-jobs (assoc-ref opts 'max-jobs)
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
#:fallback? (assoc-ref opts 'fallback?)
|
|
|
|
|
#:use-substitutes? (assoc-ref opts 'substitutes?)
|
2015-10-28 15:20:06 +01:00
|
|
|
|
#:substitute-urls (assoc-ref opts 'substitute-urls)
|
2019-11-21 15:41:11 +01:00
|
|
|
|
#:offload? (and (assoc-ref opts 'offload?)
|
|
|
|
|
(not (assoc-ref opts 'keep-failed?)))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
#:max-silent-time (assoc-ref opts 'max-silent-time)
|
2014-03-09 23:09:18 +01:00
|
|
|
|
#:timeout (assoc-ref opts 'timeout)
|
2014-06-09 18:54:52 +02:00
|
|
|
|
#:print-build-trace (assoc-ref opts 'print-build-trace?)
|
2017-01-18 23:21:29 +01:00
|
|
|
|
#:print-extended-build-trace?
|
|
|
|
|
(assoc-ref opts 'print-extended-build-trace?)
|
2018-10-15 23:06:55 +02:00
|
|
|
|
#:multiplexed-build-output?
|
|
|
|
|
(assoc-ref opts 'multiplexed-build-output?)
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
#:verbosity (assoc-ref opts 'debug)))
|
2012-07-01 00:56:24 +02:00
|
|
|
|
|
2015-05-21 00:48:10 +02:00
|
|
|
|
(define set-build-options-from-command-line*
|
|
|
|
|
(store-lift set-build-options-from-command-line))
|
|
|
|
|
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(define %standard-build-options
|
|
|
|
|
;; List of standard command-line options for tools that build something.
|
2014-09-24 11:26:30 +02:00
|
|
|
|
(list (option '(#\L "load-path") #t #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
;; XXX: Imperatively modify the search paths.
|
|
|
|
|
(%package-module-path (cons arg (%package-module-path)))
|
2015-12-30 18:15:54 +01:00
|
|
|
|
(%patch-path (cons arg (%patch-path)))
|
2014-09-24 11:26:30 +02:00
|
|
|
|
(set! %load-path (cons arg %load-path))
|
|
|
|
|
(set! %load-compiled-path (cons arg %load-compiled-path))
|
|
|
|
|
|
|
|
|
|
(apply values (cons result rest))))
|
|
|
|
|
(option '(#\K "keep-failed") #f #f
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'keep-failed? #t result)
|
|
|
|
|
rest)))
|
2016-01-19 21:57:40 +01:00
|
|
|
|
(option '(#\k "keep-going") #f #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'keep-going? #t result)
|
|
|
|
|
rest)))
|
2015-12-08 23:27:53 +01:00
|
|
|
|
(option '("rounds") #t #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'rounds (string->number* arg)
|
|
|
|
|
result)
|
|
|
|
|
rest)))
|
2013-05-29 23:08:06 +02:00
|
|
|
|
(option '("fallback") #f #f
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'fallback? #t
|
|
|
|
|
(alist-delete 'fallback? result))
|
|
|
|
|
rest)))
|
2012-10-24 15:01:16 +02:00
|
|
|
|
(option '("no-substitutes") #f #f
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'substitutes? #f
|
|
|
|
|
(alist-delete 'substitutes? result))
|
|
|
|
|
rest)))
|
2015-07-13 16:07:59 +02:00
|
|
|
|
(option '("substitute-urls") #t #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'substitute-urls
|
|
|
|
|
(string-tokenize arg)
|
|
|
|
|
(alist-delete 'substitute-urls result))
|
|
|
|
|
rest)))
|
2016-03-02 13:43:13 +01:00
|
|
|
|
(option '("no-grafts") #f #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'graft? #f
|
|
|
|
|
(alist-delete 'graft? result eq?))
|
|
|
|
|
rest)))
|
2019-11-21 15:14:33 +01:00
|
|
|
|
(option '("no-offload" "no-build-hook") #f #f
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(lambda (opt name arg result . rest)
|
2019-11-21 15:14:33 +01:00
|
|
|
|
(when (string=? name "no-build-hook")
|
|
|
|
|
(warning (G_ "'--no-build-hook' is deprecated; \
|
|
|
|
|
use '--no-offload' instead~%")))
|
|
|
|
|
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(apply values
|
2019-11-21 15:28:13 +01:00
|
|
|
|
(alist-cons 'offload? #f
|
|
|
|
|
(alist-delete 'offload? result))
|
2014-03-01 18:29:29 +01:00
|
|
|
|
rest)))
|
2013-05-20 18:14:55 +02:00
|
|
|
|
(option '("max-silent-time") #t #f
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'max-silent-time (string->number* arg)
|
|
|
|
|
result)
|
|
|
|
|
rest)))
|
2014-03-09 23:09:18 +01:00
|
|
|
|
(option '("timeout") #t #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'timeout (string->number* arg) result)
|
|
|
|
|
rest)))
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
(option '("debug") #t #f
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(lambda (opt name arg result . rest)
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
(let ((level (string->number* arg)))
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(apply values
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
(alist-cons 'debug level
|
|
|
|
|
(alist-delete 'debug result))
|
2014-03-01 18:29:29 +01:00
|
|
|
|
rest))))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(option '(#\c "cores") #t #f
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(lambda (opt name arg result . rest)
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(let ((c (false-if-exception (string->number arg))))
|
|
|
|
|
(if c
|
2014-03-01 18:29:29 +01:00
|
|
|
|
(apply values (alist-cons 'cores c result) rest)
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(leave (G_ "not a number: '~a' option argument: ~a~%")
|
2014-11-25 22:32:26 +01:00
|
|
|
|
name arg)))))
|
|
|
|
|
(option '(#\M "max-jobs") #t #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(let ((c (false-if-exception (string->number arg))))
|
|
|
|
|
(if c
|
|
|
|
|
(apply values (alist-cons 'max-jobs c result) rest)
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(leave (G_ "not a number: '~a' option argument: ~a~%")
|
2020-10-12 15:16:51 +02:00
|
|
|
|
name arg)))))
|
|
|
|
|
(option '("help-transform") #f #f
|
|
|
|
|
(lambda _
|
|
|
|
|
(format #t
|
|
|
|
|
(G_ "Available package transformation options:~%"))
|
|
|
|
|
(show-transformation-options-help)
|
|
|
|
|
(newline)
|
|
|
|
|
(exit 0)))))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
;;;
|
|
|
|
|
;;; Command-line options.
|
|
|
|
|
;;;
|
|
|
|
|
|
|
|
|
|
(define %default-options
|
|
|
|
|
;; Alist of default option values.
|
2019-04-19 15:18:20 +02:00
|
|
|
|
`((build-mode . ,(build-mode normal))
|
packages: Implement grafts.
Thanks to Mark H. Weaver <mhw@netris.org> for insightful discussions
and suggestions.
* guix/packages.scm (<package>)[graft]: New field.
(patch-and-repack): Invoke 'package-derivation' with #:graft? #f.
(package-source-derivation): Likewise. Do not use (%guile-for-build)
in call to 'patch-and-repack', and we could end up using a grafted
Guile.
(expand-input): Likewise, also for 'package-cross-derivation' call.
(package->bag): Add #:graft? parameter. Honor it. Use 'strip-append'
instead of 'package-full-name'.
(input-graft, input-cross-graft, bag-grafts, package-grafts): New
procedures.
(package-derivation, package-cross-derivation): Add #:graft? parameter
and honor it.
* gnu/packages/bootstrap.scm (package-with-bootstrap-guile): Add
recursive call on 'graft'.
* guix/build-system/gnu.scm (package-with-explicit-inputs,
package-with-extra-configure-variable, static-package): Likewise.
(gnu-build): Use the ungrafted Guile to avoid full rebuilds.
(gnu-cross-build): Likewise.
* guix/build-system/cmake.scm (cmake-build): Likewise.
* guix/build-system/glib-or-gtk.scm (glib-or-gtk-build): Likewise.
* guix/build-system/perl.scm (perl-build): Likewise.
* guix/build-system/python.scm (python-build): Likewise.
* guix/build-system/ruby.scm (ruby-build): Likewise.
* guix/build-system/trivial.scm (guile-for-build): Likewise.
* tests/packages.scm ("package-derivation, direct graft",
"package-cross-derivation, direct graft", "package-grafts,
indirect grafts", "package-grafts, indirect grafts, cross",
"package-grafts, indirect grafts, propagated inputs",
"package-derivation, indirect grafts"): New tests.
("bag->derivation", "bag->derivation, cross-compilation"): Wrap in
'parameterize'.
* doc/guix.texi (Security Updates): New node.
(Invoking guix build): Document --no-graft.
2014-10-27 18:09:00 +01:00
|
|
|
|
(graft? . #t)
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(substitutes? . #t)
|
2019-11-21 15:28:13 +01:00
|
|
|
|
(offload? . #t)
|
2014-06-09 18:54:52 +02:00
|
|
|
|
(print-build-trace? . #t)
|
2017-01-18 23:21:29 +01:00
|
|
|
|
(print-extended-build-trace? . #t)
|
2018-10-15 23:06:55 +02:00
|
|
|
|
(multiplexed-build-output? . #t)
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
(verbosity . 2)
|
|
|
|
|
(debug . 0)))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
|
|
|
|
|
(define (show-help)
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "Usage: guix build [OPTION]... PACKAGE-OR-DERIVATION...
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
Build the given PACKAGE-OR-DERIVATION and return their output paths.\n"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
-e, --expression=EXPR build the package or derivation EXPR evaluates to"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2015-10-26 23:09:28 +01:00
|
|
|
|
-f, --file=FILE build the package or derivation that the code within
|
|
|
|
|
FILE evaluates to"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2020-02-05 18:47:31 +01:00
|
|
|
|
-m, --manifest=FILE build the packages that the manifest given in FILE
|
|
|
|
|
evaluates to"))
|
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
-S, --source build the packages' source derivations"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2015-05-04 21:16:28 +02:00
|
|
|
|
--sources[=TYPE] build source derivations; TYPE may optionally be one
|
2015-01-28 20:33:28 +01:00
|
|
|
|
of \"package\", \"all\" (default), or \"transitive\""))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
-s, --system=SYSTEM attempt to build for SYSTEM--e.g., \"i686-linux\""))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
--target=TRIPLET cross-build for TRIPLET--e.g., \"armel-linux-gnu\""))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
-d, --derivations return the derivation paths of the given packages"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2015-12-09 11:04:57 +01:00
|
|
|
|
--check rebuild items to check for non-determinism issues"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
2017-01-15 22:28:24 +01:00
|
|
|
|
--repair repair the specified items"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
-r, --root=FILE make FILE a symlink to the result, and register it
|
|
|
|
|
as a garbage collector root"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
-v, --verbosity=LEVEL use the given verbosity LEVEL"))
|
|
|
|
|
(display (G_ "
|
2016-03-08 22:00:17 +01:00
|
|
|
|
-q, --quiet do not show the build log"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
--log-file return the log file names for the given derivations"))
|
|
|
|
|
(newline)
|
|
|
|
|
(show-build-options-help)
|
|
|
|
|
(newline)
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
-h, --help display this help and exit"))
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(display (G_ "
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
-V, --version display version information and exit"))
|
|
|
|
|
(newline)
|
|
|
|
|
(show-bug-report-information))
|
|
|
|
|
|
|
|
|
|
(define %options
|
|
|
|
|
;; Specifications of the command-line options.
|
|
|
|
|
(cons* (option '(#\h "help") #f #f
|
|
|
|
|
(lambda args
|
|
|
|
|
(show-help)
|
|
|
|
|
(exit 0)))
|
|
|
|
|
(option '(#\V "version") #f #f
|
|
|
|
|
(lambda args
|
|
|
|
|
(show-version-and-exit "guix build")))
|
|
|
|
|
(option '(#\S "source") #f #f
|
|
|
|
|
(lambda (opt name arg result)
|
2015-01-28 20:33:28 +01:00
|
|
|
|
(alist-cons 'source #t result)))
|
|
|
|
|
(option '("sources") #f #t
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(match arg
|
|
|
|
|
("package"
|
|
|
|
|
(alist-cons 'source #t result))
|
|
|
|
|
((or "all" #f)
|
|
|
|
|
(alist-cons 'source package-direct-sources result))
|
|
|
|
|
("transitive"
|
|
|
|
|
(alist-cons 'source package-transitive-sources result))
|
|
|
|
|
(else
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(leave (G_ "invalid argument: '~a' option argument: ~a, ~
|
2015-01-28 20:33:28 +01:00
|
|
|
|
must be one of 'package', 'all', or 'transitive'~%")
|
|
|
|
|
name arg)))))
|
2016-01-31 20:44:21 +01:00
|
|
|
|
(option '("check") #f #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'build-mode (build-mode check)
|
|
|
|
|
result)
|
|
|
|
|
rest)))
|
2017-01-15 22:28:24 +01:00
|
|
|
|
(option '("repair") #f #f
|
|
|
|
|
(lambda (opt name arg result . rest)
|
|
|
|
|
(apply values
|
|
|
|
|
(alist-cons 'build-mode (build-mode repair)
|
|
|
|
|
result)
|
|
|
|
|
rest)))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(option '(#\s "system") #t #f
|
|
|
|
|
(lambda (opt name arg result)
|
2019-04-19 15:18:20 +02:00
|
|
|
|
(alist-cons 'system arg result)))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(option '("target") #t #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(alist-cons 'target arg
|
|
|
|
|
(alist-delete 'target result eq?))))
|
|
|
|
|
(option '(#\d "derivations") #f #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(alist-cons 'derivations-only? #t result)))
|
|
|
|
|
(option '(#\e "expression") #t #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(alist-cons 'expression arg result)))
|
2015-10-26 23:09:28 +01:00
|
|
|
|
(option '(#\f "file") #t #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(alist-cons 'file arg result)))
|
2020-02-05 18:47:31 +01:00
|
|
|
|
(option '(#\m "manifest") #t #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(alist-cons 'manifest arg result)))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(option '(#\n "dry-run") #f #f
|
|
|
|
|
(lambda (opt name arg result)
|
2020-03-25 15:05:15 +01:00
|
|
|
|
(alist-cons 'dry-run? #t result)))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(option '(#\r "root") #t #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(alist-cons 'gc-root arg result)))
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
(option '(#\v "verbosity") #t #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(let ((level (string->number* arg)))
|
|
|
|
|
(alist-cons 'verbosity level
|
|
|
|
|
(alist-delete 'verbosity result)))))
|
2016-03-08 22:00:17 +01:00
|
|
|
|
(option '(#\q "quiet") #f #f
|
|
|
|
|
(lambda (opt name arg result)
|
guix build: Re-purpose '--verbosity' and add '--debug'.
The previous '--verbosity' option was misleading and rarely what users
were looking for. The new option provides a consistent way to choose
whether or not to display the build log.
* guix/scripts/build.scm (show-build-options-help): Remove "--verbosity"
and add "--debug".
(set-build-options-from-command-line): Use the 'debug key of OPTS for
#:verbosity.
(%standard-build-options): Change "verbosity" to "debug". Use
'string->number*' instead of 'string->number'.
(%default-options): Change 'verbosity to 'debug and add a 'verbosity
key.
(show-help): Add '--verbosity'.
(%options): Likewise, and change '--quiet' to set the 'verbosity key of
RESULT.
(guix-build): Use 'with-status-verbosity' instead of parameterizing
CURRENT-BUILD-OUTPUT-PORT, honor the 'verbosity key of OPTS, and remove
'quiet?'.
* guix/scripts/environment.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug'.
(guix-environment): Honor the 'verbosity key of OPTS.
* guix/scripts/pack.scm (%default-options): Add 'debug.
(%options, show-help): Add '--verbosity'.
(guix-pack): Honor the 'verbosity key of OPTS.
* guix/scripts/package.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'. Mark '--verbose' as
deprecated and change it to set 'verbosity.
(guix-package): Honor the 'verbosity key of OPTS and remove 'verbose?'.
* guix/scripts/pull.scm (%default-options): Add 'debug.
(show-help, %options): Add '--verbosity'.
(guix-pull): Honor the 'verbosity key of OPTS.
* guix/scripts/system.scm (show-help, %options): Add '--verbosity'.
(%default-options): Add 'debug.
(guix-system): Honor the 'verbosity key of OPTS.
* guix/scripts/archive.scm (%default-options): Add 'debug,
'print-build-trace?, 'print-extended-build-trace?, and
'multiplexed-build-output?.
(show-help, %options): Add '--verbosity'.
(export-from-store): Remove call to 'set-build-options-from-command-line'.
(guix-archive): Wrap body in 'with-status-verbosity'. Add call to
'set-build-options-from-command-line.
* doc/guix.texi (Common Build Options): Document '--verbosity' and
'--debug'.
(Additional Build Options): Adjust description of '--quiet'.
2019-01-09 14:17:19 +01:00
|
|
|
|
(alist-cons 'verbosity 0
|
|
|
|
|
(alist-delete 'verbosity result))))
|
guix build: Factorize common options.
* guix/scripts/build.scm (show-build-options-help,
set-build-options-from-command-line): New procedures.
(show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%standard-build-options): New variable.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(guix-build): Use 'set-build-options-from-command-line' instead of
'set-build-options'.
* guix/scripts/archive.scm (show-help): Remove description of --dry-run,
--fallback, --no-substitutes, --max-silent-time, and --cores. Call
'show-build-options-help'.
(%options): Remove --dry-run, --fallback, --no-substitutes,
--verbosity, --max-silent-time, and --cores. Add
%STANDARD-BUILD-OPTIONS.
(export-from-store): Call 'set-build-options-from-command-line'
instead of 'set-build-options.
2014-02-18 00:13:06 +01:00
|
|
|
|
(option '("log-file") #f #f
|
|
|
|
|
(lambda (opt name arg result)
|
|
|
|
|
(alist-cons 'log-file? #t result)))
|
|
|
|
|
|
2016-01-31 20:44:21 +01:00
|
|
|
|
(append %transformation-options
|
|
|
|
|
%standard-build-options)))
|
2012-07-01 00:56:24 +02:00
|
|
|
|
|
2015-11-30 22:07:35 +01:00
|
|
|
|
(define (options->things-to-build opts)
|
|
|
|
|
"Read the arguments from OPTS and return a list of high-level objects to
|
|
|
|
|
build---packages, gexps, derivations, and so on."
|
2015-12-13 21:13:16 +01:00
|
|
|
|
(define (validate-type x)
|
2018-10-09 18:52:37 +02:00
|
|
|
|
(unless (or (derivation? x) (file-like? x) (gexp? x) (procedure? x))
|
2020-09-16 23:32:00 +02:00
|
|
|
|
(raise (make-compound-condition
|
|
|
|
|
(formatted-message (G_ "~s: not something we can build~%") x)
|
|
|
|
|
(condition
|
|
|
|
|
(&fix-hint
|
|
|
|
|
(hint
|
|
|
|
|
(if (unspecified? x)
|
|
|
|
|
(G_ "If you build from a file, make sure the last Scheme
|
|
|
|
|
expression returns a package value. @code{define-public} defines a variable,
|
|
|
|
|
but returns @code{#<unspecified>}. To fix this, add a Scheme expression at
|
|
|
|
|
the end of the file that consists only of the package's variable name you
|
|
|
|
|
defined, as in this example:
|
|
|
|
|
|
|
|
|
|
@example
|
|
|
|
|
(define-public my-package
|
|
|
|
|
(package
|
|
|
|
|
...))
|
|
|
|
|
|
|
|
|
|
my-package
|
|
|
|
|
@end example")
|
|
|
|
|
(G_ "If you build from a file, make sure the last
|
|
|
|
|
Scheme expression returns a package, gexp, derivation or a list of such
|
|
|
|
|
values.")))))))))
|
2015-12-13 21:13:16 +01:00
|
|
|
|
|
|
|
|
|
(define (ensure-list x)
|
|
|
|
|
(let ((lst (match x
|
|
|
|
|
((x ...) x)
|
|
|
|
|
(x (list x)))))
|
|
|
|
|
(for-each validate-type lst)
|
|
|
|
|
lst))
|
2015-11-30 22:07:35 +01:00
|
|
|
|
|
|
|
|
|
(append-map (match-lambda
|
|
|
|
|
(('argument . (? string? spec))
|
|
|
|
|
(cond ((derivation-path? spec)
|
2019-11-17 23:10:34 +01:00
|
|
|
|
(catch 'system-error
|
|
|
|
|
(lambda ()
|
2020-01-24 18:13:38 +01:00
|
|
|
|
;; Ask for absolute file names so that .drv file
|
|
|
|
|
;; names passed from the user to 'read-derivation'
|
|
|
|
|
;; are absolute when it returns.
|
|
|
|
|
(let ((spec (canonicalize-path spec)))
|
|
|
|
|
(list (read-derivation-from-file spec))))
|
2019-11-17 23:10:34 +01:00
|
|
|
|
(lambda args
|
|
|
|
|
;; Non-existent .drv files can be substituted down
|
|
|
|
|
;; the road, so don't error out.
|
|
|
|
|
(if (= ENOENT (system-error-errno args))
|
|
|
|
|
'()
|
|
|
|
|
(apply throw args)))))
|
2015-11-30 22:07:35 +01:00
|
|
|
|
((store-path? spec)
|
|
|
|
|
;; Nothing to do; maybe for --log-file.
|
|
|
|
|
'())
|
|
|
|
|
(else
|
|
|
|
|
(list (specification->package spec)))))
|
|
|
|
|
(('file . file)
|
2020-04-14 18:01:49 +02:00
|
|
|
|
(let ((file (or (and (string-suffix? ".json" file)
|
|
|
|
|
(json->scheme-file file))
|
|
|
|
|
file)))
|
|
|
|
|
(ensure-list (load* file (make-user-module '())))))
|
2020-02-05 18:47:31 +01:00
|
|
|
|
(('manifest . manifest)
|
2020-03-03 10:34:35 +01:00
|
|
|
|
(map manifest-entry-item
|
|
|
|
|
(manifest-entries
|
|
|
|
|
(load* manifest
|
|
|
|
|
(make-user-module '((guix profiles) (gnu)))))))
|
2015-11-30 22:07:35 +01:00
|
|
|
|
(('expression . str)
|
|
|
|
|
(ensure-list (read/eval str)))
|
|
|
|
|
(('argument . (? derivation? drv))
|
|
|
|
|
drv)
|
|
|
|
|
(_ '()))
|
|
|
|
|
opts))
|
|
|
|
|
|
2013-12-21 22:53:58 +01:00
|
|
|
|
(define (options->derivations store opts)
|
|
|
|
|
"Given OPTS, the result of 'args-fold', return a list of derivations to
|
|
|
|
|
build."
|
2015-11-30 22:07:35 +01:00
|
|
|
|
(define transform
|
|
|
|
|
(options->transformation opts))
|
|
|
|
|
|
2013-12-21 22:53:58 +01:00
|
|
|
|
(define package->derivation
|
|
|
|
|
(match (assoc-ref opts 'target)
|
|
|
|
|
(#f package-derivation)
|
|
|
|
|
(triplet
|
|
|
|
|
(cut package-cross-derivation <> <> triplet <>))))
|
|
|
|
|
|
2015-01-28 20:33:28 +01:00
|
|
|
|
(define src (assoc-ref opts 'source))
|
packages: Implement grafts.
Thanks to Mark H. Weaver <mhw@netris.org> for insightful discussions
and suggestions.
* guix/packages.scm (<package>)[graft]: New field.
(patch-and-repack): Invoke 'package-derivation' with #:graft? #f.
(package-source-derivation): Likewise. Do not use (%guile-for-build)
in call to 'patch-and-repack', and we could end up using a grafted
Guile.
(expand-input): Likewise, also for 'package-cross-derivation' call.
(package->bag): Add #:graft? parameter. Honor it. Use 'strip-append'
instead of 'package-full-name'.
(input-graft, input-cross-graft, bag-grafts, package-grafts): New
procedures.
(package-derivation, package-cross-derivation): Add #:graft? parameter
and honor it.
* gnu/packages/bootstrap.scm (package-with-bootstrap-guile): Add
recursive call on 'graft'.
* guix/build-system/gnu.scm (package-with-explicit-inputs,
package-with-extra-configure-variable, static-package): Likewise.
(gnu-build): Use the ungrafted Guile to avoid full rebuilds.
(gnu-cross-build): Likewise.
* guix/build-system/cmake.scm (cmake-build): Likewise.
* guix/build-system/glib-or-gtk.scm (glib-or-gtk-build): Likewise.
* guix/build-system/perl.scm (perl-build): Likewise.
* guix/build-system/python.scm (python-build): Likewise.
* guix/build-system/ruby.scm (ruby-build): Likewise.
* guix/build-system/trivial.scm (guile-for-build): Likewise.
* tests/packages.scm ("package-derivation, direct graft",
"package-cross-derivation, direct graft", "package-grafts,
indirect grafts", "package-grafts, indirect grafts, cross",
"package-grafts, indirect grafts, propagated inputs",
"package-derivation, indirect grafts"): New tests.
("bag->derivation", "bag->derivation, cross-compilation"): Wrap in
'parameterize'.
* doc/guix.texi (Security Updates): New node.
(Invoking guix build): Document --no-graft.
2014-10-27 18:09:00 +01:00
|
|
|
|
(define graft? (assoc-ref opts 'graft?))
|
2019-04-19 15:18:20 +02:00
|
|
|
|
(define systems
|
|
|
|
|
(match (filter-map (match-lambda
|
|
|
|
|
(('system . system) system)
|
|
|
|
|
(_ #f))
|
|
|
|
|
opts)
|
|
|
|
|
(() (list (%current-system)))
|
|
|
|
|
(systems systems)))
|
|
|
|
|
|
|
|
|
|
(define things-to-build
|
|
|
|
|
(map (cut transform store <>)
|
|
|
|
|
(options->things-to-build opts)))
|
|
|
|
|
|
|
|
|
|
(define (compute-derivation obj system)
|
|
|
|
|
;; Compute the derivation of OBJ for SYSTEM.
|
|
|
|
|
(match obj
|
|
|
|
|
((? package? p)
|
|
|
|
|
(let ((p (or (and graft? (package-replacement p)) p)))
|
|
|
|
|
(match src
|
|
|
|
|
(#f
|
|
|
|
|
(list (package->derivation store p system)))
|
|
|
|
|
(#t
|
|
|
|
|
(match (package-source p)
|
|
|
|
|
(#f
|
2019-06-23 19:18:32 +02:00
|
|
|
|
(warning (package-location p)
|
|
|
|
|
(G_ "package '~a' has no source~%")
|
|
|
|
|
(package-name p))
|
2019-04-19 15:18:20 +02:00
|
|
|
|
'())
|
|
|
|
|
(s
|
|
|
|
|
(list (package-source-derivation store s)))))
|
|
|
|
|
(proc
|
|
|
|
|
(map (cut package-source-derivation store <>)
|
|
|
|
|
(proc p))))))
|
|
|
|
|
((? derivation? drv)
|
|
|
|
|
(list drv))
|
|
|
|
|
((? procedure? proc)
|
|
|
|
|
(list (run-with-store store
|
|
|
|
|
(mbegin %store-monad
|
|
|
|
|
(set-guile-for-build (default-guile))
|
|
|
|
|
(proc))
|
|
|
|
|
#:system system)))
|
|
|
|
|
((? file-like? obj)
|
|
|
|
|
(list (run-with-store store
|
|
|
|
|
(lower-object obj system
|
|
|
|
|
#:target (assoc-ref opts 'target))
|
|
|
|
|
#:system system)))
|
|
|
|
|
((? gexp? gexp)
|
|
|
|
|
(list (run-with-store store
|
|
|
|
|
(mbegin %store-monad
|
|
|
|
|
(set-guile-for-build (default-guile))
|
|
|
|
|
(gexp->derivation "gexp" gexp
|
|
|
|
|
#:system system))
|
|
|
|
|
#:system system)))))
|
2013-12-21 22:53:58 +01:00
|
|
|
|
|
2018-05-04 15:05:05 +02:00
|
|
|
|
;; We may get 'unbound-variable' errors while evaluating the 'inputs' fields
|
|
|
|
|
;; of user packages. Since 'guix build' is the primary tool for people
|
|
|
|
|
;; testing new packages, report such errors gracefully.
|
|
|
|
|
(with-unbound-variable-handling
|
|
|
|
|
(parameterize ((%graft? graft?))
|
2019-04-19 15:18:20 +02:00
|
|
|
|
(append-map (lambda (system)
|
2020-03-25 12:42:54 +01:00
|
|
|
|
(concatenate
|
|
|
|
|
(map/accumulate-builds store
|
|
|
|
|
(cut compute-derivation <> system)
|
|
|
|
|
things-to-build)))
|
2019-04-19 15:18:20 +02:00
|
|
|
|
systems))))
|
2015-11-30 22:07:35 +01:00
|
|
|
|
|
2015-11-29 17:42:01 +01:00
|
|
|
|
(define (show-build-log store file urls)
|
|
|
|
|
"Show the build log for FILE, falling back to remote logs from URLS if
|
|
|
|
|
needed."
|
|
|
|
|
(let ((log (or (log-file store file)
|
|
|
|
|
(log-url store file #:base-urls urls))))
|
|
|
|
|
(if log
|
|
|
|
|
(format #t "~a~%" log)
|
ui: Rename '_' to 'G_'.
This avoids collisions with '_' when the latter is used as a 'match'
pattern for instance. See
<https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>.
* guix/ui.scm: Rename '_' to 'G_'.
* po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly.
* build-aux/compile-all.scm (warnings): Remove 'format'.
* gnu/packages.scm,
gnu/services.scm,
gnu/services/shepherd.scm,
gnu/system.scm,
gnu/system/shadow.scm,
guix/gnupg.scm,
guix/http-client.scm,
guix/import/cpan.scm,
guix/import/elpa.scm,
guix/import/pypi.scm,
guix/nar.scm,
guix/scripts.scm,
guix/scripts/archive.scm,
guix/scripts/authenticate.scm,
guix/scripts/build.scm,
guix/scripts/challenge.scm,
guix/scripts/container.scm,
guix/scripts/container/exec.scm,
guix/scripts/copy.scm,
guix/scripts/download.scm,
guix/scripts/edit.scm,
guix/scripts/environment.scm,
guix/scripts/gc.scm,
guix/scripts/graph.scm,
guix/scripts/hash.scm,
guix/scripts/import.scm,
guix/scripts/import/cpan.scm,
guix/scripts/import/cran.scm,
guix/scripts/import/crate.scm,
guix/scripts/import/elpa.scm,
guix/scripts/import/gem.scm,
guix/scripts/import/gnu.scm,
guix/scripts/import/hackage.scm,
guix/scripts/import/nix.scm,
guix/scripts/import/pypi.scm,
guix/scripts/import/stackage.scm,
guix/scripts/lint.scm,
guix/scripts/offload.scm,
guix/scripts/pack.scm,
guix/scripts/package.scm,
guix/scripts/perform-download.scm,
guix/scripts/publish.scm,
guix/scripts/pull.scm,
guix/scripts/refresh.scm,
guix/scripts/size.scm,
guix/scripts/substitute.scm,
guix/scripts/system.scm,
guix/ssh.scm,
guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was
obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-05-03 15:57:02 +02:00
|
|
|
|
(leave (G_ "no build log for '~a'~%") file))))
|
2015-11-29 17:42:01 +01:00
|
|
|
|
|
2012-07-01 00:56:24 +02:00
|
|
|
|
|
|
|
|
|
;;;
|
|
|
|
|
;;; Entry point.
|
|
|
|
|
;;;
|
|
|
|
|
|
2020-09-01 22:13:11 +02:00
|
|
|
|
(define-command (guix-build . args)
|
|
|
|
|
(category packaging)
|
|
|
|
|
(synopsis "build packages or derivations without installing them")
|
|
|
|
|
|
2016-03-04 17:50:30 +01:00
|
|
|
|
(define opts
|
|
|
|
|
(parse-command-line args %options
|
|
|
|
|
(list %default-options)))
|
|
|
|
|
|
2020-03-05 15:52:37 +01:00
|
|
|
|
(define graft?
|
|
|
|
|
(assoc-ref opts 'graft?))
|
|
|
|
|
|
2012-11-01 00:50:01 +01:00
|
|
|
|
(with-error-handling
|
2020-01-24 18:13:38 +01:00
|
|
|
|
(with-status-verbosity (assoc-ref opts 'verbosity)
|
|
|
|
|
(with-store store
|
|
|
|
|
;; Set the build options before we do anything else.
|
|
|
|
|
(set-build-options-from-command-line store opts)
|
|
|
|
|
|
2020-03-18 22:46:39 +01:00
|
|
|
|
(with-build-handler (build-notifier #:use-substitutes?
|
|
|
|
|
(assoc-ref opts 'substitutes?)
|
2020-07-22 23:22:13 +02:00
|
|
|
|
#:verbosity
|
|
|
|
|
(assoc-ref opts 'verbosity)
|
2020-03-18 22:46:39 +01:00
|
|
|
|
#:dry-run?
|
|
|
|
|
(assoc-ref opts 'dry-run?))
|
|
|
|
|
(parameterize ((current-terminal-columns (terminal-columns))
|
|
|
|
|
|
|
|
|
|
;; Set grafting upfront in case the user's input
|
|
|
|
|
;; depends on it (e.g., a manifest or code snippet that
|
|
|
|
|
;; calls 'gexp->derivation').
|
|
|
|
|
(%graft? graft?))
|
|
|
|
|
(let* ((mode (assoc-ref opts 'build-mode))
|
|
|
|
|
(drv (options->derivations store opts))
|
|
|
|
|
(urls (map (cut string-append <> "/log")
|
|
|
|
|
(if (assoc-ref opts 'substitutes?)
|
|
|
|
|
(or (assoc-ref opts 'substitute-urls)
|
|
|
|
|
;; XXX: This does not necessarily match the
|
|
|
|
|
;; daemon's substitute URLs.
|
|
|
|
|
%default-substitute-urls)
|
|
|
|
|
'())))
|
|
|
|
|
(items (filter-map (match-lambda
|
|
|
|
|
(('argument . (? store-path? file))
|
|
|
|
|
;; If FILE is a .drv that's not in
|
|
|
|
|
;; store, keep it so that it can be
|
|
|
|
|
;; substituted.
|
|
|
|
|
(and (or (not (derivation-path? file))
|
|
|
|
|
(not (file-exists? file)))
|
|
|
|
|
file))
|
|
|
|
|
(_ #f))
|
|
|
|
|
opts))
|
|
|
|
|
(roots (filter-map (match-lambda
|
|
|
|
|
(('gc-root . root) root)
|
|
|
|
|
(_ #f))
|
|
|
|
|
opts)))
|
|
|
|
|
|
|
|
|
|
(cond ((assoc-ref opts 'log-file?)
|
|
|
|
|
;; Pass 'show-build-log' the output file names, not the
|
|
|
|
|
;; derivation file names, because there can be several
|
|
|
|
|
;; derivations leading to the same output.
|
|
|
|
|
(for-each (cut show-build-log store <> urls)
|
|
|
|
|
(delete-duplicates
|
|
|
|
|
(append (map derivation->output-path drv)
|
|
|
|
|
items))))
|
|
|
|
|
((assoc-ref opts 'derivations-only?)
|
|
|
|
|
(format #t "~{~a~%~}" (map derivation-file-name drv))
|
|
|
|
|
(for-each (cut register-root store <> <>)
|
|
|
|
|
(map (compose list derivation-file-name) drv)
|
|
|
|
|
roots))
|
|
|
|
|
(else
|
|
|
|
|
(and (build-derivations store (append drv items)
|
|
|
|
|
mode)
|
|
|
|
|
(for-each show-derivation-outputs drv)
|
|
|
|
|
(for-each (cut register-root store <> <>)
|
|
|
|
|
(map (lambda (drv)
|
|
|
|
|
(map cdr
|
|
|
|
|
(derivation->output-paths drv)))
|
|
|
|
|
drv)
|
|
|
|
|
roots)))))))))))
|