[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
06/20: x add make-squashfs-image
From: |
guix-commits |
Subject: |
06/20: x add make-squashfs-image |
Date: |
Tue, 3 Sep 2024 16:19:00 -0400 (EDT) |
nckx pushed a commit to branch mol
in repository guix.
commit c04d489e772206b27e90681addfa2b578d4ebb89
Author: Tobias Geerinckx-Rice <me@tobias.gr>
AuthorDate: Sun Aug 20 02:00:00 2023 +0200
x add make-squashfs-image
---
gnu/build/image.scm | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/gnu/build/image.scm b/gnu/build/image.scm
index 6ca0a428e0..349ac8dcf5 100644
--- a/gnu/build/image.scm
+++ b/gnu/build/image.scm
@@ -101,6 +101,22 @@ turn doesn't take any constant overhead into account,
force a 1-MiB minimum."
(estimate-partition-size root)
size)))))))
+(define* (make-squashfs-image partition target root
+ #:key
+ (owner-uid 0)
+ (owner-gid 0))
+ "Handle the creation of Squashfs partition images.
+See 'make-partition-image'."
+ (let ((fs (partition-file-system partition))
+ (fs-options (partition-file-system-options partition)))
+ (apply invoke
+ `("fakeroot" "gensquashfs" "-D" ,root
+ "-j1" "-b" ,(number->string (ash 1 20))
+ "-u" ,owner-uid "-g" ,owner-gid
+ "-c" "zstd"
+ ,@fs-options
+ ,target))))
+
(define* (make-vfat-image partition target root fs-bits)
"Handle the creation of VFAT partition images. See 'make-partition-image'."
(let ((size (partition-size partition))
@@ -139,6 +155,8 @@ ROOT directory to populate the image."
(cond
((string-prefix? "ext" type)
(make-ext-image partition target root))
+ ((string=? "squashfs" type)
+ (make-squashfs-image partition target root))
((or (string=? type "vfat") (string=? type "fat16"))
(make-vfat-image partition target root 16))
((string=? type "fat32")
- branch mol created (now 813c4ba8ff), guix-commits, 2024/09/03
- 05/20: f my dnsmasq service fixups, guix-commits, 2024/09/03
- 09/20: gnu: Add xevil., guix-commits, 2024/09/03
- 07/20: WIP graph -f, guix-commits, 2024/09/03
- 10/20: (do not upstream) netsurf fb stuff, guix-commits, 2024/09/03
- 06/20: x add make-squashfs-image,
guix-commits <=
- 11/20: gnu: Add c3c-bootstrap., guix-commits, 2024/09/03
- 04/20: XXX, guix-commits, 2024/09/03
- 01/20: tests: Increase installation VM memory size., guix-commits, 2024/09/03
- 18/20: nginx: comment out fix-root-dirs, guix-commits, 2024/09/03
- 02/20: WIP use cut for stylistic reasons, guix-commits, 2024/09/03
- 15/20: gnu: nginx: Hide server header., guix-commits, 2024/09/03
- 14/20: gnu: Add rspamd., guix-commits, 2024/09/03
- 08/20: TEMP, guix-commits, 2024/09/03
- 20/20: file-systems: Add support for exFAT., guix-commits, 2024/09/03
- 03/20: services: dnsmasq: Fix some indentation., guix-commits, 2024/09/03