Commit Graph

72 Commits

Author SHA1 Message Date
Pierre Neidhardt fea338c6ca
Add (guix lzlib).
* guix/lzlib.scm, tests/lzlib.scm: New files.
* Makefile.am (MODULES): Add guix/lzlib.scm.
(SCM_TESTS): Add tests/lzlib.scm.
* m4/guix.m4 (GUIX_LIBLZ_LIBDIR): New macro.
* configure.ac (LIBLZ_LIBDIR): Use it.  Define and substitute
'LIBLZ'.
* guix/config.scm.in (%liblz): New variable.
* guix/self.scm (make-config.scm): Add TODO comment.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2019-05-06 23:21:33 +02:00
Ludovic Courtès 757e633d57
build: Change default substitute server to "ci.guix.gnu.org".
* config-daemon.ac: Replace "ci.guix.info" with "ci.guix.gnu.org".
* doc/guix.texi (SUBSTITUTE-SERVER): Likewise.
* etc/substitutes/ci.guix.gnu.org.pub: New file.
* Makefile.am (dist_pkgdata_DATA): Add it.
* guix/scripts/build.scm (%default-log-urls): Update.
* guix/scripts/substitute.scm (%default-substitute-urls): Likewise.
* guix/store.scm (%default-substitute-urls): Likewise.
* guix/self.scm (miscellaneous-files): Add "ci.guix.gnu.org".
2019-05-01 11:05:47 +02:00
Julien Lepiller 554b30d2ac
self: Rebuild translated manuals.
* guix/self.scm (info-manual): Run po4a and related commands to generate
translated texi files before building translated manuals.
* guix/build/po.scm: New file.
* Makefile.am (MODULES_NOT_COMPILED): Add it.
2019-04-27 17:13:18 +02:00
Ludovic Courtès 17503ea8a2
self: Install 'guix.zh_CN.info'.
Reported by Julien Lepiller.

* guix/self.scm (info-manual): Adjust file name regexp so that it
matches *.zh_CN.texi.
2019-04-25 00:45:34 +02:00
Ludovic Courtès ab77b69eca
self: Remove unused variable.
This variable is unused since commit
45779fa676.

* guix/self.scm (%dependency-variables): Remove.
* build-aux/build-self.scm (%dependency-variables): Remove.
2019-04-17 11:53:53 +02:00
Ludovic Courtès 5a6e04c53c
self: Ship all the (gnu bootloader …) modules.
* guix/self.scm (compiled-guix)[*system-modules*]: Explicitly add all of
gnu/bootloader/*.
2019-04-03 18:21:43 +02:00
Ludovic Courtès 54eadc42d2
self: Generated (guix config) honors %CURRENT-SYSTEM.
Fixes <https://bugs.gnu.org/34468>.
Reported by Diego Nicola Barbato <dnbarbato@posteo.de>.

* guix/self.scm (%config-variables): Remove %SYSTEM.
(make-config.scm): Define '%system' to (%current-system).
2019-02-17 00:04:57 +01:00
Ludovic Courtès ba48895899
self: Bundle 'glibc-utf8-locales'.
This minimizes the risk of locale-related warnings, at least for those
who use one of the bundled UTF-8 locales.

* guix/self.scm (guix-command)[glibc-utf8-locales]: New variable.
In program body, set GUIX_LOCPATH.
2019-02-16 01:00:08 +01:00
Ludovic Courtès 765a5bf167
self: Ensure the daemon refers to the right 'guix' command.
Previously it would refer to
/var/guix/profiles/per-user/root/current-guix/bin/guix, which would fail
when that profile does not exist.  This is notably the case when using
'channel-instance->package' as done in commit
7e6d8d366a.

* gnu/packages/package-management.scm (guix-daemon)[arguments]: In
'install phase, honor environment variable 'GUIX'.
* guix/self.scm (whole-package)[wrap]: New procedure.
Use it.
2019-02-04 00:03:30 +01:00
Ludovic Courtès a87d66f371
daemon: Rename 'NIX_STATE_DIR' and 'NIX_DB_DIR' environment variables.
Fixes <https://bugs.gnu.org/22459>.
Reported by Jeff Mickey <j@codemac.net>.

* guix/config.scm.in (%state-directory): Change NIX_STATE_DIR to
GUIX_STATE_DIRECTORY.
(%store-database-directory): Change NIX_DB_DIR to
GUIX_DATABASE_DIRECTORY.
* nix/libstore/globals.cc (Settings::processEnvironment): Likewise.
* guix/self.scm (make-config.scm): Likewise.
* build-aux/build-self.scm (make-config.scm): Likewise.
* build-aux/test-env.in: Likewise.
* tests/derivations.scm ("derivation #:leaked-env-vars"): Likewise.
* tests/guix-build.sh (GUIX_DAEMON_SOCKET): Likewise.
* tests/guix-daemon.sh (socket): Likewise.
2019-02-04 00:03:30 +01:00
Ludovic Courtès 35dcaa119e
self: Produce progress reports compatible with (guix status).
* guix/self.scm (compiled-modules)[build](report-load)
(report-compilation): Write "[M/N]" progress reports.
Use line-buffering.
2019-01-29 12:09:52 +01:00
Ludovic Courtès 5f2daffe09
self: System tests depend on CLI modules.
This is because (gnu tests docker) depends on (guix scripts pack).

* guix/self.scm (compiled-guix)[*system-test-modules*]: Add dependency
on *CLI-MODULES*.
2019-01-22 23:04:05 +01:00
Ludovic Courtès 567f0d2590
self: Remove leftover export.
* guix/self.scm: Remove 'reload-guix' export.
2019-01-22 23:04:05 +01:00
Ludovic Courtès 54800977d9
self: Build the (gnu tests …) modules.
* guix/self.scm (compiled-guix)[*system-modules*]: Remove gnu/tests/*
from #:extra-files.
[*system-test-modules*]: New variable.
[build-modules]: Add them.
2019-01-20 23:54:54 +01:00
Ludovic Courtès 8bb62ae10c
self: Add gnu/tests/* to the installed files.
* guix/self.scm (compiled-guix)[*system-modules*]: Add gnu/tests/*.
2019-01-19 01:26:34 +01:00
Mathieu Othacehe a49d633c0c
installer: Move everything to the build side.
* gnu/installer.scm: Rename to ...
* gnu/installer/record.scm: ... this.
* gnu/installer/build-installer.scm: Move everything to the build side and
rename to gnu/installer.scm.
* gnu/installer/newt.scm: Remove all the gexps and add depencies to newt
modules as this code will only be used on the build side by now.
* gnu/local.mk (GNU_SYSTEM_MODULES): Adapt it,
(dist_installer_DATA): New rule to install installer's aux-files.
* gnu/system/install.scm (%installation-services): Use only
'installer-program' from (gnu installer). The installer is now choosen on the
build side.
* guix/self.scm (*system-modules*): Restore previous behaviour and add all
installer files to #:extra-files field of the scheme-node.
* po/guix/POTFILES.in: Adapt it.
2019-01-17 14:04:21 +01:00
Mathieu Othacehe 16006a05a1
guix: self: Do not install (gnu system install).
As we do not want to add a dependency to newt and the graphical installer
in (guix self), do not install (gnu system install).

* guix/self.scm (*system-modules*): Remove (gnu system install) from
"guix-system" scheme-node.
2019-01-17 14:04:21 +01:00
Ludovic Courtès 6e54e488c6
self: Drop support for Guix < 0.15 on Guile 2.0.
* guix/self.scm (false-if-wrong-guile, package-for-guile): Remove.
(specification->package): Remove "guile2.0-" variants.
(compiled-guix): #:guile-for-build defaults to (default-guile).
Use 'specification->package' instead of 'package-for-guile'.
(guile-for-build): Remove.
(guix-derivation): Use 'default-guile' instead of 'guile-for-build'.
Check whether we're running on Guile 2.0 with PULL-VERSION < 1.
2019-01-09 14:47:53 +01:00
Ludovic Courtès 76832d3420
Remove most uses of the _IO*F constants.
These constants, for use with 'setvbuf', were deprecated in Guile 2.2
and disappeared in Guile 3.0.  Here we keep these constants in
build-side code where removing them is not feasible.

* guix/build/download-nar.scm (download-nar): Adjust 'setvbuf' calls to
the Guile 2.2+ API.
* guix/build/download.scm (open-socket-for-uri): Likewise.
(open-connection-for-uri, url-fetch): Likewise.
* guix/build/make-bootstrap.scm (make-stripped-libc): Likewise.
* guix/build/union.scm (setvbuf) [guile-2.0]: New conditional wrapper.
(union-build): Adjust to new API.
* guix/ftp-client.scm (ftp-open, ftp-list, ftp-retr): Likewise.
* guix/http-client.scm (http-fetch): Likewise.
* guix/inferior.scm (proxy): Likewise.
* guix/scripts/substitute.scm (fetch, http-multiple-get): Likewise.
* guix/self.scm (compiled-modules): Likewise.
* guix/ssh.scm (remote-daemon-channel, store-import-channel)
(store-export-channel): Likewise.
* guix/ui.scm (initialize-guix): Likewise.
* tests/publish.scm (http-get-port): Likewise.
* guix/store.scm (%newlines): Adjust comment.
2019-01-09 14:47:53 +01:00
Ludovic Courtès 08fdee3911
self: Compress Info files.
Fixes <https://bugs.gnu.org/33993>.
Reported by Adonay Felipe Nogueira <adfeno@hyperbola.info>.

* guix/self.scm (info-manual): Compress Info files.
2019-01-08 18:38:15 +01:00
Ludovic Courtès 49c35bbb71
self: Move all modules into a single directory.
This halves the number of elements in %LOAD-PATH and %LOAD-COMPILED-PATH
and halves the number of 'stat' calls as reported by:

  env -i $(type -P guix) build -e '(@ (gnu packages base) coreutils)' -nd

* guix/self.scm (node-source+compiled, guile-module-union): New
procedures.
(guix-command): Remove 'compiled-modules' parameter.  Remove
'source-directories' and 'object-directories' variables and add
'module-directory'.  Change command so that it adds nothing but
MODULE-DIRECTORY to %LOAD-PATH and %LOAD-COMPILED-PATH.
(whole-package): Remove #:compiled-modules.  Assume MODULES contains
'share/guile/site' and 'lib/guile' and adjust code accordingly.
(compiled-guix): When PULL-VERSION is 1, use 'node-source+compiled'
only.  Remove #:compiled-modules argument to 'whole-package'.
* guix/channels.scm (whole-package-for-legacy): Add 'module+compiled'
and pass it to 'whole-package'.
2019-01-07 23:50:56 +01:00
Ludovic Courtès b5f8c2c885
hydra: Compute jobs in an inferior.
Previously we would rely on auto-compilation of all the Guix modules.
The complete evaluation would take ~15mn on berlin.guixsd.org and
require lots of RAM.  This approach should be faster since potentially
only part of the modules are rebuilt.  Furthermore, as a side-effect, it
builds the derivations that 'guix pull' uses.

* build-aux/hydra/gnu-system.scm: Remove 'eval-when' form.
(hydra-jobs): New procedure.
* gnu/ci.scm (package->alist, qemu-jobs, system-test-jobs)
(tarball-jobs): Return strings for the 'license' field.
* guix/self.scm (compiled-guix)[*cli-modules*]: Add (gnu ci).
2019-01-06 21:41:07 +01:00
Ludovic Courtès 6a837b6062
etc: Add "ci.guix.info.pub" public key file.
* etc/substitutes/ci.guix.info.pub: New file.
* Makefile.am (dist_pkgdata_DATA): Add it.
* guix/self.scm (miscellaneous-files): Add
"share/guix/ci.guix.info.pub".
2018-12-04 10:57:56 +01:00
Ludovic Courtès 194451347d
Merge branch 'core-updates' 2018-12-03 08:52:17 +01:00
Ludovic Courtès 2d33776050
self: Provide UTF-8 locales when building the manual.
Fixes <https://bugs.gnu.org/33580>.
Reported by <znavko@tutanota.com>.

* guix/self.scm (info-manual)[glibc-utf8-locales]: New variable.
[build]: Add call to 'setenv' for "GUIX_LOCPATH".
2018-12-02 22:53:22 +01:00
Marius Bakke 55174e668f
Merge branch 'master' into core-updates 2018-11-07 21:09:57 +01:00
Ludovic Courtès e3744779aa
self: Install shell completion files.
* guix/self.scm (miscellaneous-files): New procedure.
(whole-package): Remove #:substitute-keys, add #:miscellany.
[build]: Remove code for SUBSTITUTE-KEYS and add code to copy MISCELLANY
to OUTPUT.
(compiled-guix): Adjust call to 'whole-package'.
2018-11-06 17:00:02 +01:00
Ludovic Courtès 6cf502d164
self: Rename 'sub-directory' to 'file-append*'.
* guix/self.scm (sub-directory): Rename to...
(file-append*): ... this.  Add #:recursive? parameter and pass it to
'local-file'.
(locale-data, info-manual, compiled-guix): Adjust accordingly.
2018-11-06 17:00:02 +01:00
Ludovic Courtès 8d3beb3a44
self: Install substitute keys.
* guix/self.scm (whole-package): Add #:substitute-keys and honor it.
(compiled-guix): Pass #:substitute-keys to 'whole-package' when
PULL-VERSION is one.
2018-11-06 00:04:11 +01:00
Ludovic Courtès cbe7387c04
self: Remove extra paren in manual version string.
* guix/self.scm (info-manual)[build]: Remove extra closing paren in
VERSION.
2018-11-06 00:04:11 +01:00
Marius Bakke d02bb02f7d
Merge branch 'master' into core-updates 2018-10-17 20:47:11 +02:00
Ludovic Courtès 099bb0175f
self: Use Guile 2.2 unconditionally for recent 'guix pull'.
Fixes <https://bugs.gnu.org/32929>.
Reported by Michael Bowcutt <mwb71@case.edu>.

* guix/self.scm (guix-derivation)[guile]: Use "2.2" when PULL-VERSION >= 1.
Likewise for the #:guile-version argument.
2018-10-10 14:54:18 +02:00
Marius Bakke 0aeb134850
Merge branch 'master' into core-updates 2018-09-09 17:40:35 +02:00
Ludovic Courtès ca71942445
Switch to Guile-Gcrypt.
This removes (guix hash) and (guix pk-crypto), which now live as part of
Guile-Gcrypt (version 0.1.0.)

* guix/gcrypt.scm, guix/hash.scm, guix/pk-crypto.scm,
tests/hash.scm, tests/pk-crypto.scm: Remove.
* configure.ac: Test for Guile-Gcrypt.  Remove LIBGCRYPT and
LIBGCRYPT_LIBDIR assignments.
* m4/guix.m4 (GUIX_ASSERT_LIBGCRYPT_USABLE): Remove.
* README: Add Guile-Gcrypt to the dependencies; move libgcrypt as
"required unless --disable-daemon".
* doc/guix.texi (Requirements): Likewise.
* gnu/packages/bash.scm, guix/derivations.scm, guix/docker.scm,
guix/git.scm, guix/http-client.scm, guix/import/cpan.scm,
guix/import/cran.scm, guix/import/crate.scm, guix/import/elpa.scm,
guix/import/gnu.scm, guix/import/hackage.scm,
guix/import/texlive.scm, guix/import/utils.scm, guix/nar.scm,
guix/pki.scm, guix/scripts/archive.scm,
guix/scripts/authenticate.scm, guix/scripts/download.scm,
guix/scripts/hash.scm, guix/scripts/pack.scm,
guix/scripts/publish.scm, guix/scripts/refresh.scm,
guix/scripts/substitute.scm, guix/store.scm,
guix/store/deduplication.scm, guix/tests.scm, tests/base32.scm,
tests/builders.scm, tests/challenge.scm, tests/cpan.scm,
tests/crate.scm, tests/derivations.scm, tests/gem.scm,
tests/nar.scm, tests/opam.scm, tests/pki.scm,
tests/publish.scm, tests/pypi.scm, tests/store-deduplication.scm,
tests/store.scm, tests/substitute.scm: Adjust imports.
* gnu/system/vm.scm: Likewise.
(guile-sqlite3&co): Rename to...
(gcrypt-sqlite3&co): ... this.  Add GUILE-GCRYPT.
(expression->derivation-in-linux-vm)[config]: Remove.
(iso9660-image)[config]: Remove.
(qemu-image)[config]: Remove.
(system-docker-image)[config]: Remove.
* guix/scripts/pack.scm: Adjust imports.
(guile-sqlite3&co): Rename to...
(gcrypt-sqlite3&co): ... this.  Add GUILE-GCRYPT.
(self-contained-tarball)[build]: Call 'make-config.scm' without
 #:libgcrypt argument.
(squashfs-image)[libgcrypt]: Remove.
[build]: Call 'make-config.scm' without #:libgcrypt.
(docker-image)[config, json]: Remove.
[build]: Add GUILE-GCRYPT to the extensions  Remove (guix config) from
the imported modules.
* guix/self.scm (specification->package): Remove "libgcrypt", add
"guile-gcrypt".
(compiled-guix): Remove #:libgcrypt.
[guile-gcrypt]: New variable.
[dependencies]: Add it.
[*core-modules*]: Remove #:libgcrypt from 'make-config.scm' call.
Add #:extensions.
[*config*]: Remove #:libgcrypt from 'make-config.scm' call.
(%dependency-variables): Remove %libgcrypt.
(make-config.scm): Remove #:libgcrypt.
* build-aux/build-self.scm (guile-gcrypt): New variable.
(make-config.scm): Remove #:libgcrypt.
(build-program)[fake-gcrypt-hash]: New variable.
Add (gcrypt hash) to the imported modules.  Adjust load path
assignments.
* gnu/packages/package-management.scm (guix)[propagated-inputs]: Add
GUILE-GCRYPT.
[arguments]: In 'wrap-program' phase, add GUILE-GCRYPT to the search
path.
2018-09-04 17:25:11 +02:00
Marius Bakke 70dc8db8e7
Merge branch 'master' into core-updates 2018-09-03 19:20:06 +02:00
Ludovic Courtès 02fa1d251c
discovery: Add 'scheme-modules*'.
* guix/self.scm (scheme-modules*): Move to...
* guix/discovery.scm (scheme-modules*): ... here.  New procedure.  Make
'sub-directory' an optional parameter.
2018-09-02 16:43:10 +02:00
Marius Bakke 61fca0fd22
Merge branch 'master' into core-updates 2018-08-28 01:22:24 +02:00
Ludovic Courtès f2d0a2cf5c
self: Shrink the module search path of the 'guix' command.
Previously we'd have lots of useless entries on the search paths, such
as libtasn1, libidn2, zlib, gmp, etc. because they are propagated by
gnutls.

* guix/self.scm (guix-command)[source-directories, object-directories]:
New variables.  Use them in the body of "guix-command".  Filter their
items with 'file-exists?'.
2018-08-27 23:22:17 +02:00
Ludovic Courtès 8bece84022
gnu: guile: Remove version 2.2.2.
* gnu/packages/guile.scm (guile-2.2.2): Remove.
* guix/self.scm (guile-for-build): Remove special case for "2.2.2".
(guix-derivation): Likewise.
* build-aux/build-self.scm (build): Likewise.
2018-07-27 11:28:15 +02:00
Ludovic Courtès 2abd76e8af
gnu: guile: Update to 2.2.4.
* gnu/packages/guile.scm (guile-2.2): Update to 2.2.4.
(guile-2.2.4): Remove.
* gnu/packages/package-management.scm (guix)[inputs]: Switch to
GUILE-2.2.
* guix/self.scm (guile-for-build): Likewise.
2018-07-27 11:22:12 +02:00
Ludovic Courtès f5db54eaa5
self: Use the new 'imported-files'.
That way, the source of most nodes is now a content-addressed store item
instead of a derivation.

* guix/self.scm (<file-mapping>): New record type.
(file-mapping-compiler): New procedure.
(scheme-node): Use 'file-mapping' instead of 'imported-files'.
(imported-files): Remove.
2018-07-19 11:48:04 +02:00
Ludovic Courtès 084f64cb03
self: Build with Guile 2.2.4.
* guix/self.scm (guile-for-build): In the "2.2" case, choose
GUILE-2.2.4.
2018-07-02 15:28:35 +02:00
Ludovic Courtès 8970a886e6
self: Use #:guile-for-build in the shebang of the 'guix' executable.
* guix/self.scm (guix-command): Add #:guile and pass it to 'program-file'.
(whole-package): Add #:guile and pass it to 'guix-command'.
(compiled-guix): Pass #:guile to 'guix-command' and 'whole-package'.
2018-07-02 15:28:35 +02:00
Ludovic Courtès 108015df6d
self: Add dependency on GnuTLS.
Fixes <https://bugs.gnu.org/31983>.
Reported by Fis Trivial <ybbs.daans@hotmail.com>.

* guix/self.scm (specification->package): Add "gnutls" and
"guile2.0-gnutls".
(compiled-guix)[gnutls]: New variable.
[dependencies]: Add it.
2018-06-27 23:30:44 +02:00
Ludovic Courtès 7af5c2a248
self: Define derived '-directory' variables in config.scm.
This is a followup to d6b5aa0b03.

* guix/self.scm (%config-variables): Remove %CONFIG-DIRECTORY,
%STATE-DIRECTORY, %STORE-DATABASE-DIRECTORY, and %STORE-DIRECTORY.
(make-config.scm): Define them here.
* build-aux/build-self.scm (%config-variables, make-config.scm):
Likewise.
2018-06-18 23:56:16 +02:00
Ludovic Courtès e8cb9c01c6
build: Remove checks for 'nix-instantiate'.
* guix/import/snix.scm (open-nixpkgs): Use "nix-instantiate"
unconditionally.
* configure.ac: Remove check for 'nix-instantiate'.
* guix/config.scm.in (%nix-instantiate): Remove.
* guix/self.scm (%dependency-variables): Remove '%nix-instantiate'.
(make-config.scm): Remove it from the generated "config.scm".
* build-aux/build-self.scm (%dependency-variables, make-config.scm):
Likewise.
2018-06-18 23:19:51 +02:00
Ludovic Courtès 45779fa676
self: Make (guix config) generation really stateless.
Previously the %CONFIG-VARIABLES list would be generated based on what
the current (guix config) contains.  Thus, it would include
'%guix-register-program', which we recently removed, because
existing (guix config) most likely contained that variable.  Since its
value could differ from machine to machine, the build farm could be
building a different config.scm, thereby preventing people from getting
substitutes.

* guix/self.scm (%config-variables): Turn into a white list instead of
taking all the remaining variables from the current (guix config).
* build-aux/build-self.scm (%config-variables): Likewise.
2018-06-18 23:19:51 +02:00
Ludovic Courtès a89faa3faa
self: Install .go files to 'lib/guile/X.Y/site-ccache'.
* guix/self.scm (guix-command): Add 'compiled-modules' parameter and
honor it.
(whole-package): Likewise.
(compiled-guix)[built-modules]: Turn into a procedure.
When PULL-VERSION is 1, use separate source and compiled modules.
When PULL-VERSION is 0, return a single directory containing both .scm
and .go files.
2018-06-17 01:40:14 +02:00
Ludovic Courtès baed923682
self: Add 'guix-daemon' to the result.
* gnu/packages/package-management.scm (guix-daemon): New variable.
* guix/self.scm (whole-package): Add #:daemon and honor it.
(compiled-guix): Pass #:daemon to 'whole-package'.
2018-06-14 23:34:59 +02:00
Ludovic Courtès ea0a06cee2
Remove 'guix-register' and its traces.
* Makefile.am (SH_TESTS): Remove tests/guix-register.sh.
* build-aux/pre-inst-env.in (GUIX_REGISTER): Remove.
* gnu/build/install.scm (directives): Remove outdated comment.
* gnu/build/vm.scm (root-partition-initializer): Update comment.
* gnu/packages/package-management.scm (guix-register): Remove.
* guix/config.scm.in (%sbindir, %guix-register-program): Remove.
* guix/scripts/system.scm (install): Adjust docstring.
* guix/self.scm (make-config.scm): Remove #:guix.  Do not generate
%sbindir and %guix-register-program.
(specification->package): Remove "guix".
* nix/guix-register/guix-register.cc: Remove.
* nix/libstore/store-api.cc (decodeValidPathInfo): Remove.
* nix/libstore/store-api.hh (decodeValidPathInfo): Remove declaration.
* nix/local.mk (sbin_PROGRAMS, guix_register_SOURCES)
(guix_register_CPPFLAGS, guix_register_LDFLAGS): Remove.
* tests/guix-register.sh: Remove.
2018-06-14 11:17:00 +02:00