diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..3d1bdaa --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +scripts/lib/wic/plugins/source/__pycache__/ diff --git a/README.md b/README.md index 571ddb4..fbea01d 100644 --- a/README.md +++ b/README.md @@ -10,10 +10,8 @@ Yocto BSP layer for PC Engines hardware # Building -Make sure to adjust `~/ssh-keys` according to your configuration: - ``` -SHELL=bash kas-docker --ssh-dir ~/ssh-keys build meta-pcengines/kas-docker.yml +SHELL=/bin/bash kas-docker build meta-pcengines/kas-docker.yml ``` Check a device node of the drive to be flashed: @@ -25,8 +23,18 @@ sudo fdisk -l Change directory to `/tmp/deploy/images/pcengines-apu2`. Find desired image and flash the drive: +> Replace the `/dev/sdx` with the proper device path + +``` +sudo bmaptool copy --bmap docker-image-minimal-pcengines-apu2.wic.bmap docker-image-minimal-pcengines-apu2.wic.gz /dev/sdx +``` + +> The `bmaptool` can flash images much faster than the `dd` + +or if `bmap-tools` are not available in your system: + ``` -sudo dd if=xen-dom0-image-pcengines-apu2.hddimg of=/dev/ +gzip -cdk docker-image-minimal-pcengines-apu2.wic.gz | sudo dd of=/dev/sdx ``` # Bootup log diff --git a/conf/machine/include/pcengines-apux.inc b/conf/machine/include/pcengines-apux.inc index b41e601..bc3226c 100644 --- a/conf/machine/include/pcengines-apux.inc +++ b/conf/machine/include/pcengines-apux.inc @@ -31,11 +31,9 @@ MACHINE_FEATURES += " \ ima \ " -MACHINE_EXTRA_RRECOMMENDS += " \ - kernel-modules \ +MACHINE_ESSENTIAL_EXTRA_RDEPENDS += " \ grub \ - parted \ - util-linux-blkid \ + kernel-modules \ " # QEMU does not support some of the enhanced instructions available @@ -49,7 +47,7 @@ MACHINE_FEATURES_remove = "qemu-usermode" APPEND_ADDITIONAL ??= "" APPEND += "${APPEND_ADDITIONAL}" -IMAGE_FSTYPES += "ext4" +IMAGE_FSTYPES += "ext4 wic.gz wic.bmap" IMAGE_OVERHEAD_FACTOR = "1.1" @@ -64,3 +62,5 @@ KERNEL_MODULE_AUTOLOAD_pce-xen += " \ xen-pciback \ xen-blkback \ " + +WKS_FILES ?= "directdisk-grub-legacy.wks" diff --git a/kas.yml b/kas.yml index ded96ba..8ae65e6 100644 --- a/kas.yml +++ b/kas.yml @@ -6,7 +6,7 @@ repos: poky: url: https://git.yoctoproject.org/git/poky - refspec: d0ac956dc2454da252ab718267af0dcf504e6a13 + refspec: 0fc9d32ae11ebb53aa33342f50887c1e692a1f32 layers: meta: meta-poky: @@ -14,7 +14,7 @@ repos: meta-openembedded: url: http://git.openembedded.org/meta-openembedded - refspec: e0daf6f8e0c53e388c631b8cdf3d7d8173dcea95 + refspec: e413c1ef621688e69bb7830bb3151ed23b30b73e layers: meta-oe: meta-networking: @@ -23,17 +23,17 @@ repos: meta-virtualization: url: https://git.yoctoproject.org/git/meta-virtualization - refspec: 062d9f1f4faf2ca8a1fe78b7c7365e6378c15836 + refspec: 5c2de3daedd3f65171b9debf938683ce6e7746ea meta-security: url: https://git.yoctoproject.org/git/meta-security - refspec: 27ddb455543b670097e252ba0d0ad5b7e4101748 + refspec: c74cc97641fd93e0e7a4383255e9a0ab3deaf9d7 layers: meta-tpm: meta-selinux: url: https://git.yoctoproject.org/git/meta-selinux - refspec: 44d760413920ba440439b8bc7c2a71ca26cd7a2d + refspec: 7af62c91d7d00a260cf28e7908955539304d100d bblayers_conf_header: standard: | diff --git a/wic/directdisk-grub-legacy.wks b/wic/directdisk-grub-legacy.wks new file mode 100644 index 0000000..69c537b --- /dev/null +++ b/wic/directdisk-grub-legacy.wks @@ -0,0 +1,3 @@ +part /boot --source bootimg-grub-legacy --label msdos --active --align 1024 --use-uuid --size 32M +part / --source rootfs --fstype=ext4 --align 1024 --overhead-factor 1.5 +bootloader --ptable msdos --timeout=5 --append="rootfstype=ext4 console=ttyS0,115200 earlyprintk=serial,ttyS0,115200"