[gnome-build-meta/valentindavid/eos-installer: 3/12] Make the bootable image acceptable for eos-installer



commit 697cb4d7689c7ce66792f198d09255ffda818fce
Author: Valentin David <valentin david codethink co uk>
Date:   Wed Feb 26 11:34:38 2020 +0100

    Make the bootable image acceptable for eos-installer
    
    The name has to be of a certain format and it has to be a raw
    compressed file.

 elements/iso/xz-image.bst | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)
---
diff --git a/elements/iso/xz-image.bst b/elements/iso/xz-image.bst
new file mode 100644
index 00000000..133ff171
--- /dev/null
+++ b/elements/iso/xz-image.bst
@@ -0,0 +1,26 @@
+kind: script
+
+build-depends:
+- vm/qemu-tools.bst
+- vm/image.bst
+
+variables:
+  # This name format is required by eos-installer
+  basename: 'GNOMEOS-%{branch}-%{arch}-%{arch}.%{branch}.base'
+
+config:
+  layout:
+  - element: vm/qemu-tools.bst
+    destination: /
+  - element: vm/image.bst
+    destination: /images
+  - element: ''
+    destination: /tmp
+
+  commands:
+  - qemu-img convert -O raw /images/disk.qcow2 /tmp/disk.img
+  # Mark 2nd partition for eos-repartition
+  # FIXME: Fix genimage to make this possible in vm/image.bst
+  - sfdisk --part-attrs /tmp/disk.img 2 55
+  - xz /tmp/disk.img
+  - install -Dm644 /tmp/disk.img.xz "%{install-root}/%{basename}.img.xz"


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]