Commit graph

5 commits

Author SHA1 Message Date
Maxim Cournoyer
f59df1aa3c
build-systems: gnu: Export %default-gnu-imported-modules and %default-gnu-modules.
Until now users would have to cargo cult or inspect the private
%default-modules variable of (guix build-systems gnu) to discover which
modules to include when extending the used modules via the #:modules argument.

The renaming was automated via the command:

  $ git grep -l %gnu-build-system-modules
    | xargs sed 's/%gnu-build-system-modules/%default-gnu-imported-modules/' -i

* guix/build-system/gnu.scm (%gnu-build-system-modules): Rename to...
(%default-gnu-imported-modules): ... this.
(%default-modules): Rename to...
(%default-gnu-modules): ... this.  Export.
(dist-package, gnu-build, gnu-cross-build): Adjust accordingly.

Change-Id: Idef307fff13cb76f3182d782b26e1cd3a5c757ee
2024-08-31 10:42:16 +02:00
Ludovic Courtès
e3dfed59d3
modules: ‘file-name->module-name’ strips leading “./”.
Fixes <https://issues.guix.gnu.org/71979>.

* guix/modules.scm (file-name->module-name): Strip leading “.” component
from FILE.
* tests/modules.scm ("file-name->module-name")
("file-name->module-name, leading dot"): New tests.

Reported-by: Tomas Volf <~@wolfsden.cz>
Change-Id: I3d1b9f3f21448050cac4f3b1aed5f8f03758d4c9
2024-07-18 17:31:19 +02:00
Mathieu Othacehe
05a9d1f378
Remove VM generation dead-code.
This code duplicates the (gnu system image) and (gnu build image) code. Using
VM for image generation is not needed, not portable and really slow. Remove
all the VM image generation code to make sure that only the image API is used.

* gnu/build/vm.scm: Remove it. Move the qemu-command procedure to ...
* gnu/build/marionette.scm: ... here.
* gnu/local.mk (GNU_SYSTEM_MODULES): Adapt it.
* tests/modules.scm: Ditto.
* gnu/tests/install.scm: Ditto.
* gnu/system/vm.scm: Adapt it and remove expression->derivation-in-linux-vm,
qemu-img, system-qemu-image/shared-store and system-docker-image procedures.
* doc/guix.texi (G-Expressions): Adapt it.
2021-12-23 10:54:00 +01:00
Ludovic Courtès
bfe5264aa1
modules: Raise an error when a dependency could not be found.
* guix/modules.scm (&missing-dependency-error): New error condition.
(source-module-dependencies): Raise it when 'search-path' returns #f.
* tests/modules.scm ("&missing-dependency-error"): New test.
2017-05-25 14:25:17 +02:00
Ludovic Courtès
7ca87354db
Add (guix modules).
* guix/modules.scm, tests/modules.scm: New files.
* Makefile.am (MODULES, SCM_TESTS): Add them.
* doc/guix.texi (G-Expressions): Add an example of
'source-module-closure'.
2016-09-05 00:06:47 +02:00