diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2021-10-30 00:21:04 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2021-10-30 21:15:09 +0200 |
commit | 3fbe53aec0f340a90858265ca8f890314fa5d523 (patch) | |
tree | 32a666397b7c97c6ba202274b7f0aaf0e2166422 /examples/recipes/rootfs.yml | |
parent | 6d77ac17b4414d30384473c667e08199f428d94e (diff) | |
download | rebel-3fbe53aec0f340a90858265ca8f890314fa5d523.tar rebel-3fbe53aec0f340a90858265ca8f890314fa5d523.zip |
examples: move recipes to subdirectory
Diffstat (limited to 'examples/recipes/rootfs.yml')
-rw-r--r-- | examples/recipes/rootfs.yml | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/examples/recipes/rootfs.yml b/examples/recipes/rootfs.yml new file mode 100644 index 0000000..77b50ba --- /dev/null +++ b/examples/recipes/rootfs.yml @@ -0,0 +1,56 @@ +tasks: + install: + args: + host: 'platform' + depends: + - recipe: 'busybox' + task: 'install' + - recipe: 'toolchain' + task: 'build_depends' + args: + target: 'host' + output: + default: {} + run: | + mkdir -p \ + {{destdir}}/dev \ + {{destdir}}/proc \ + {{destdir}}/sys \ + {{destdir}}/root \ + {{destdir}}/run \ + {{destdir}}/var \ + {{destdir}}/usr/bin \ + {{destdir}}/usr/lib + + ln -s bin {{destdir}}/usr/sbin + ln -s usr/bin {{destdir}}/bin + ln -s usr/bin {{destdir}}/sbin + ln -s usr/lib {{destdir}}/lib + ln -s ../run {{destdir}}/var/run + + rsync -aHAXK {{sysroot}}/ {{destdir}} + + + image-ext4: + args: + host: 'platform' + build_depends: + - recipe: 'e2fsprogs' + task: 'install' + - recipe: 'make_ext4fs' + task: 'install' + depends: + - task: 'install' + output: + default: {} + run: | + IMAGE={{destdir}}/{{pn}}.ext4 + UUID="$( + python3 \ + -c 'import sys; import uuid; print(uuid.UUID(hex=sys.argv[1][:32], version=4))' \ + "$INPUT_HASH" + )" + + mkdir {{destdir}} + {{build.prefix}}/bin/make_ext4fs -l 2G -T "$SOURCE_DATE_EPOCH" -L root "$IMAGE" {{sysroot}} + E2FSPROGS_FAKE_TIME="$SOURCE_DATE_EPOCH" {{build.prefix}}/sbin/tune2fs -U "$UUID" "$IMAGE" |