guix build command builds packages or derivations and
their dependencies, and prints the resulting store paths. Note that it
does not modify the user’s profile—this is the job of the
guix package command (see Invoking guix package). Thus,
it is mainly useful for distribution developers.
The general syntax is:
guix build options package-or-derivation…
As an example, the following command builds the latest versions of Emacs and of Guile, displays their build logs, and finally displays the resulting directories:
guix build emacs guile
Similarly, the following command builds all the available packages:
guix build --quiet --keep-going \ `guix package -A | cut -f1,2 --output-delimiter=@`
package-or-derivation may be either the name of a package found in
the software distribution such as
coreutils-8.20, or a derivation such as
/gnu/store/…-coreutils-8.19.drv. In the former case, a
package with the corresponding name (and optionally version) is searched
for among the GNU distribution modules (see Package Modules).
--expression option may be used to specify a
Scheme expression that evaluates to a package; this is useful when
disambiguating among several same-named packages or package variants is
There may be zero or more options. The available options are described in the subsections below.
|• Common Build Options:||Build options for most commands.|
|• Package Transformation Options:||Creating variants of packages.|
|• Additional Build Options:||Options specific to ’guix build’.|