Age | Commit message (Collapse) | Author |
|
Generating a raw-with-offset image would previously not be bootable with
U-Boot.
* gnu/system/image.scm (root-partition) [file-system-options]: New field.
|
|
* gnu/system/image.scm: Adjust comment.
|
|
Cross-building a docker image with:
$ guix system image --image-type=docker --target=aarch64-linux-gnu os.scm
results in an image where the architecture declared in its config.json is
the host architecture rather than the target one. The binaries are
correctly cross-compiled, so the image can be loaded and used despite the
warning message shown by docker:
$ docker load -i vcal7bvsqcijchifhqdvprpd1niqh8sk-docker-image.tar.gz
Loaded image: guix:latest
$ docker create guix:latest
WARNING: The requested image's platform (linux/amd64) does not match the
detected host platform (linux/arm64/v8) and no specific platform was
requested
40f06aa869ed690489c4a3824a7f7721bd4bf453b85f25ac7199266939fe2fba
$ echo $?
0
This is fixed by passing the correct triplet to the build-docker-image
function.
* gnu/system/image.scm (system-docker-image) Add ‘image-target’ variable.
[builder]: Pass ‘#:system’ argument to ‘build-docker-image’.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/system/image.scm (system-tarball-image): Add it.
|
|
* gnu/image.scm (<image>)[format]: Add wsl2 support.
* gnu/system/image.scm (wsl2-image, wsl2-image-type): New variables.
(image->root-file-system): Add wsl2 image support.
(system-image): Ditto.
|
|
* gnu/image.scm (<image>)[fields]: Add tarball to the supported formats.
* gnu/system/image.scm (tarball-image, tarball-image-type): New variables.
(system-tarball-image): New procedure.
(image->root-file-system): Add tarball image support.
(system-image): Ditto.
* doc/guix.texi ("System Images"): Document it.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
Make the operating-system field mandatory as creating an image without it
makes no sense. Introduce a new macro, image-without-os for the specific cases
where the image is only created to be inherited from afterwards.
* gnu/image.scm (<image>)[operating-system]: Make it mandatory.
* gnu/system/image.scm (image-without-os): New macro.
(efi-disk-image, efi32-disk-image, iso9660-image, docker-image,
raw-with-offset-disk-image): Use it.
* gnu/system/images/hurd.scm (hurd-disk-image): Ditto.
|
|
* gnu/system/image.scm: Update it.
|
|
* gnu/system/image.scm (sytem-image): Remove it.
|
|
* gnu/system/image.scm (find-root-partition): Raise an error when 'find'
returns #f.
|
|
* gnu/system/image.scm (system-disk-image)[genimage-type-options]: Use
'partition-table-type' instead of the deprecated 'gpt' option.
|
|
Previously, the default value would lead to a wrong-type-to-apply crash.
* gnu/system/image.scm (system-disk-image)[image-builder]: When
'partition-initializer' returns #f, fall back to
INITIALIZE-ROOT-PARTITION.
* gnu/tests/base.scm (run-root-unmount-test)[test-image]: Remove
'initializer' field of partition.
* gnu/image.scm (<partition>)[initializer]: Add comment.
|
|
Previously 'system-image' would return *unspecified* in that case,
leading to a wrong-type-arg error crash down the road.
* gnu/system/image.scm (system-image): Add 'else' clause.
|
|
* gnu/bootloader/grub.scm (grub-efi32-bootloader): New variable.
(install-grub-efi32): New variable.
* gnu/build/bootloader.scm (install-efi): Add a 'targets' keyword
argument.
(install-efi-loader): Likewise.
* gnu/build/image.scm (initialize-efi32-partition): New procedure.
* gnu/packages/bootloaders.scm (grub-efi32): New variable.
* gnu/system/image.scm (esp32-partition): New variable
(efi32-disk-image): New variable.
(efi32-raw-image-type): New variable.
(system-disk-image)[partition-image]: Set '#:grub-efi32' when
calling the partition initializer.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/build/image.scm (make-vfat-image): Pass fs-bits as an argument and force
1kb logical sector size only if "ESP" flag is set.
(make-partition-image): Add "fat32" partition type, support explicit "fat16"
type with vfat alias.
* gnu/system/image.scm (partition->dos-type partition): Return file system IDs
for "fat16" and "fat32" partitions.
(partition->gpt-type partition): Ditto.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/platform.scm:
* gnu/platforms/arm.scm:
* gnu/platforms/hurd.scm:
* gnu/platforms/mips.scm:
* gnu/platforms/powerpc.scm:
* gnu/platforms/riscv.scm:
* gnu/platforms/s390.scm:
* gnu/platforms/x86.scm: Move to guix/.
* Makefile.am:
* doc/guix.texi (Porting to a New Platform):
* etc/release-manifest.scm:
* gnu/ci.scm:
* gnu/image.scm:
* gnu/local.mk:
* gnu/packages/bioinformatics.scm:
* gnu/packages/bootstrap.scm:
* gnu/packages/cross-base.scm:
* gnu/packages/instrumentation.scm:
* gnu/packages/linux.scm:
* gnu/system/image.scm:
* gnu/system/images/hurd.scm:
* gnu/system/images/novena.scm:
* gnu/system/images/pine64.scm:
* gnu/system/images/pinebook-pro.scm:
* gnu/system/images/rock64.scm:
* guix/scripts/build.scm:
* guix/scripts/system.scm:
* guix/self.scm: Update (gnu platform...) to (guix platform...).
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/build/image.scm (sexp->partition): Add flags support.
* gnu/system/image.scm (partition->gexp): Ditto.
(system-disk-image): Set the genimage bootable flag if it is part of the
partition flags.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/system/image.scm (system-disk-image): Support them.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/system/image.scm (system-disk-image): Support them.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/system/image.scm (system-disk-image): Tweak it.
|
|
* gnu/system/image.scm: Fix it.
|
|
* gnu/system/image.scm (docker-image, docker-image-type): New variables.
(system-docker-image): New procedure.
(image->root-file-system): Add docker image support.
(system-image): Ditto.
|
|
* gnu/image.scm (<image>)[partition-table-type]: New field.
* gnu/system/image.scm: Implement partition-table-type logic for
genimage.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/platform.scm: New file.
* gnu/platforms/arm.scm: Ditto.
* gnu/platforms/hurd.scm: Ditto.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add them.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/system/image.scm (raw-image-type): Rename to "efi-raw-image-type".
* guix/scripts/system.scm (%default-options): Adapt accordingly.
* doc/guix.texi: Ditto.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
Fixes: <https://issues.guix.gnu.org/45584>.
* gnu/system/image.scm (arm32-disk-image, arm64-disk-image): Turn into
procedures, taking the root partition offset as argument.
* gnu/system/images/novena.scm (novena-image-type): Adapt accordingly.
* gnu/system/images/pine64.scm (pine64-image-type): Ditto.
* gnu/system/images/pinebook-pro.scm (pinebook-pro-image-type): Use a 9MiB
offset for the root partition.
|
|
This is a follow-up of 41f27bf8702838f19b1dc5ffee8eec1d4315d4e6.
* gnu/system/image.scm (operating-system-for-image): Force "volatile-root?" to
true when producing ISO images.
|
|
When the image type is "raw" or derived from it (such as "qcow2"), an ESP
partition and file system is already added by the image generator. If a
conflicting user-provided EFI file system is provided, it causes the boot to
fail, as happens for the lightweight-desktop.tmpl and desktop.tmpl templates
under gnu/system/examples.
* gnu/system/image.scm (operating-system-for-image): Remove file systems whose
mount point is "/boot/efi".
|
|
This is a followup to 99efa804bd6df5de4760ec5974ed2297f1746366.
* gnu/system/image.scm (system-disk-image): Pass #:local-build? #f to
'computed-file'.
|
|
This builds are extremely I/O-intensive so they'd rather not run on the
head node of the build farm.
* gnu/system/image.scm (system-disk-image, system-iso9660-image): Pass
#:local-build? #f.
|
|
* gnu/system/image.scm (arm32-disk-image, arm32-image-type): New variables.
(arm64-disk-image): Inherit from arm32-disk-image.
(arm64-image-type): Change name to 'arm64-raw.
|
|
* gnu/system/image.scm: Use (srfi srfi-34) for 'raise'.
(lookup-image-type-by-name): Remove extra newline in 'formatted-message'
string.
|
|
* gnu/system/images/pine64.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* gnu/system/image.scm (arm64-disk-image, arm64-image-type): New variables.
|
|
This is a follow-up of f19cf27c2b9ff92e2c0fd931ef7fde39c376adaa. The
bootloader installation must be done on the final disk-image, hence using
"disk-image-installer" instead of "installer" callback.
* gnu/bootloader/u-boot.scm: Turn all installer callbacks into
disk-image-installer callbacks.
* gnu/build/bootloader.scm (write-file-on-device): Open the output file with
'no-truncate and 'no-create options.
* gnu/system/image.scm (with-imported-modules*): Add (gnu build bootloader)
module.
|
|
* gnu/system/image.scm (qcow2-image-type): New variable.
|
|
* gnu/system/image.scm (image-with-os): New macro. Rename the old
"image-with-os" procedure to ...
(image-with-os*): ... this new procedure,
(system-image): adapt according,
(raw-image-type, iso-image-type, uncompressed-iso-image-type
%image-types): new variables,
(lookup-image-type-by-name): new procedure.
(find-image): remove it.
* gnu/system/images/hurd.scm (hurd-image-type): New variable,
use it to define ...
(hurd-disk-image): ... this variable, using "os->image" procedure.
* gnu/tests/install.scm (run-install): Rename
installation-disk-image-file-system-type parameter to installation-image-type,
use os->config instead of find-image to compute the image passed to system-image,
(%test-iso-image-installer) adapt accordingly,
(guided-installation-test): ditto.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
|
|
* gnu/build/image.scm (convert-disk-image): New procedure.
(genimage): Remove target argument.
* gnu/system/image.scm (system-disk-image): Add support for 'compressed-qcow2
image format. Call "convert-disk-image" to apply image conversions on the
final image. Add "qemu-minimal" to the build inputs.
(system-image): Also add support for 'compressed-qcow2.
|
|
* gnu/system/image.scm (system-iso9660-image): Change the default file output
name to "image.iso".
|
|
This reverts commit 6a9581741e4ee81226aeb2f1c997df76670a6aab, which is
obsoleted by the previous commit.
|
|
* guix/scripts/system.scm (%options): Add `--label'.
(system-derivation-for-action): Take a #:label key to set volume ID.
(perform-action): Take a #:label key.
(%default-options): Add default label value.
(process-action): Pass label value from command-line to perform-action.
* gnu/system/image.scm (image-with-label): New procedure.
|
|
Image files can be very large (multiple gigabytes), and the process of
generating them is primarily I/O bound. As disk access is typically faster
than network access, it makes sense build them locally.
* gnu/system/image.scm (system-disk-image): Pass the #:local-build? #t
parameter to computed-file calls dealing with generating image files.
(system-iso9660-image): Likewise.
|
|
This is a follow-up of 755f365b02b42a5d1e8ef3000dadef069553a478.
As (zlib) is autoloaded in (gnu build linux-modules), "guile-zlib" is needed
as an extension only when it is effectively used.
* gnu/installer.scm (installer-program): Remove "guile-zlib" from the extensions.
* gnu/machine/ssh.scm (machine-check-initrd-modules): Ditto.
* gnu/services.scm (activation-script): Ditto.
* gnu/services/base.scm (default-serial-port): Ditto,
(agetty-shepherd-service): ditto,
(udev-service-type): ditto.
* gnu/system/image.scm (gcrypt-sqlite3&co): Ditto.
* gnu/system/shadow.scm (account-shepherd-service): Ditto.
|
|
This commit adds support for GZIP compression for linux-libre kernel
modules. The initrd modules are kept uncompressed as the initrd is already
compressed as a whole.
The linux-libre kernel also supports XZ compression, but as Guix does not have
any available bindings for now, and the compression time is far more
significant, GZIP seems to be a better option.
* gnu/build/linux-modules.scm (modinfo-section-contents): Use
'call-with-gzip-input-port' to read from a module file using '.gz' extension,
(strip-extension): new procedure,
(dot-ko): adapt to support compression,
(ensure-dot-ko): ditto,
(file-name->module-name): ditto,
(find-module-file): ditto,
(load-linux-module*): ditto,
(module-name->file-name/guess): ditto,
(module-name-lookup): ditto,
(write-module-name-database): ditto,
(write-module-alias-database): ditto,
(write-module-device-database): ditto.
* gnu/installer.scm (installer-program): Add "guile-zlib" to the extensions.
* gnu/machine/ssh.scm (machine-check-initrd-modules): Ditto.
* gnu/services.scm (activation-script): Ditto.
* gnu/services/base.scm (default-serial-port): Ditto,
(agetty-shepherd-service): ditto,
(udev-service-type): ditto.
* gnu/system/image.scm (gcrypt-sqlite3&co): Ditto.
* gnu/system/linux-initrd.scm (flat-linux-module-directory): Add "guile-zlib"
to the extensions and make sure that the initrd only contains
uncompressed module files.
* gnu/system/shadow.scm (account-shepherd-service): Add "guile-zlib" to the
extensions.
* guix/profiles.scm (linux-module-database): Ditto.
|
|
This is a follow-up of 5980ec8ada5ede54bde6558c7ab8bf492bc70f85.
* gnu/system/image.scm (system-disk-image): When using the image name, convert
it to string first.
|
|
* gnu/system/image.scm (system-disk-image): Use the image name as disk-image
derivation name, if defined. Otherwise use the generic "disk-image" name.
|
|
This is a follow-up to commit b904b59ce592c89dfb4675a8c06757afed6738a0.
* gnu/system/image.scm (hurd-initialize-root-partition): Move to ...
* gnu/system/images/hurd.scm (hurd-initialize-root-partition): ... here.
(hurd-disk-image): Use it.
|
|
ISO9660 image compression was temporarily disabled to speed-up tests of the
new image API. Enable it again.
* gnu/system/image.scm (iso9660-image)[compression]: Enable it.
|
|
This moves hurd-disk-image to a dedicated file. It also defines a default
operating-system so that the image can be built standalone.
* gnu/system/images/hurd.scm: New file,
* gnu/local.mk (GNU_SYSTEM_MODULES): add it,
* gnu/system/image.scm (root-offset, root-label): Export it,
(hurd-disk-image): remove it as this is now defined in the new, Hurd dedicated
file above,
(find-image): adapt to avoid loop dependency.
|
|
Since c29bb909d241e7215e574e93d9799e701cbc6ddb, fakeroot "sed" and "coreutils"
dependencies are now explicit.
* gnu/system/image.scm (system-disk-image): Remove "sed" and "coreutils" from
inputs.
|
|
The "image-root" derivation output is used as a temporary directory that is
passed to mke2fs and mkdosfs later on. By merging the creation of this
directory and the production of partition images, we can get rid of the
derivation.
As mke2fs and mkdosfs are not able to override file permissions, call those
commands with fakeroot. This way, all the image files will be owned by root,
even if image generation is done in an unprivilegded context.
* gnu/system/image.scm (system-disk-image): Merge "image-root" and
"iso9660-image" derivations so that we spare an extra derivation. Also add
"fakeroot" and its runtime dependencies to the inputs.
* gnu/build/image.scm (make-ext-image, make-vfat-image): Make sure that mke2fs
and mkdosfs are respectively called by fakeroot.
|