From: Martin Jansa <martin.jansa@gmail.com>
To: openembedded-core@lists.openembedded.org
Subject: [RFC][PATCH 0/5] Kernel artifacts naming changes
Date: Mon, 20 Nov 2017 20:11:00 +0000 [thread overview]
Message-ID: <cover.1511207344.git.Martin.Jansa@gmail.com> (raw)
This is only RFC, because it wasn't tested in all possible combinations
people might use.
I did some limited testing with raspberrypi3 and raspberrypi3-64 with
default configuration and also our modified naming where rpi builds
were failing and we had to use our own sdcard_image-rpi.bbclass to
work around it.
Basically all our build artifacts from jenkins jobs contain values like
product version, type of build, build number (or just release name for
"release" jobs).
For that we modify variables like:
IMAGE_NAME, IMAGE_LINK_NAME, INITRAMFS_IMAGE_NAME, KERNEL_IMAGE_BASE_NAME,
KERNEL_IMAGE_SYMLINK_NAME, MODULE_IMAGE_BASE_NAME, MODULE_IMAGE_SYMLINK_NAME
and it works OK, but only until some other bbclasses are assuming that
these variables are still using default value (e.g. -${MACHINE} in
KERNEL_IMAGE_SYMLINK_NAME.
Things are actually a bit worse, we want to use the same version suffix
across all artifacts, even when some of them were actually reused from sstate
- e.g. if build number 6 reuses kernel.do_deploy sstate archive created in
build number 5, then kernel artifacts would be named with -5 and image with -6.
So we cannot use vardepsexclude for the build number (like the default
values do for DATETIME). But that would require reexecuting actual kernel
do_deploy task every single build (and as it depends on tasks like kernel.do_install
it's not just relativey fast do_deploy, but whole kernel build).
Instead we changed the variables to create the artifacts without any version
in sstate covered tasks (so kernel.do_deploy produces just files without any
version (like default KERNEL_IMAGE_SYMLINK_NAME) and then we execute separate
very fast do_kernel_fixup task, which adds versioned _hard_ link (instead of
symlink, so that we can update or remove the file without version and the
versioned file is still usable).
And that's still not enough, few found that some tools which we use in do_rootfs
sometimes modify instead of overwrite the file in deploy (so that the file
with versioned name was modified during the next build through the file without
the version).
And as a last step we also had to update many task dependencies, where the task
was depending on do_deploy and we actually needed the task to depend on
do_deploy_fixup.
This RFC doesn't implement it all, but it makes naming all the artifacts in
consistent way a bit easier. If there is an agreement that OE should support
the naming scenario described above, I'll submit the rest of the changes.
Regards,
The following changes since commit a17f3ec910366e9e7551fa24fbc07929b9584341:
dhcp: fix build issue with libxml2 support (2017-11-10 14:44:31 +0000)
are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib jansa/kernel
http://cgit.openembedded.org/openembedded-core-contrib/log/?h=jansa/kernel
Martin Jansa (5):
kernel-devicetree.bbclass: Use lowercase names for shell variables
kernel-devicetree.bbclass: Fix and simplify instalation of DTB files
kernel-devicetree.bbclass: build DTBs with make dtbs
kernel.bbclass: use the consistent naming schema for initramfs
kernel.bbclass: move variables for kernel artifacts names to separate
bbclass
meta/classes/kernel-artifact-names.bbclass | 19 +++++++
meta/classes/kernel-devicetree.bbclass | 89 ++++++++++++------------------
meta/classes/kernel.bbclass | 26 ++-------
3 files changed, 60 insertions(+), 74 deletions(-)
create mode 100644 meta/classes/kernel-artifact-names.bbclass
--
2.7.4
next reply other threads:[~2017-11-20 20:06 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-20 20:11 Martin Jansa [this message]
2017-11-20 20:11 ` [RFC][PATCH 1/5] kernel-devicetree.bbclass: Use lowercase names for shell variables Martin Jansa
2017-11-20 20:11 ` [RFC][PATCH 2/5] kernel-devicetree.bbclass: Fix and simplify instalation of DTB files Martin Jansa
2017-11-20 20:11 ` [RFC][PATCH 3/5] kernel-devicetree.bbclass: build DTBs with make dtbs Martin Jansa
2017-11-20 20:11 ` [RFC][PATCH 4/5] kernel.bbclass: use the consistent naming schema for initramfs Martin Jansa
2017-11-20 20:11 ` [RFC][PATCH 5/5] kernel.bbclass: move variables for kernel artifacts names to separate bbclass Martin Jansa
2017-11-21 11:58 ` [RFC][PATCH 0/5] Kernel artifacts naming changes Otavio Salvador
2018-07-02 14:16 ` Martin Jansa
2018-07-02 16:56 ` Otavio Salvador
2018-07-02 22:07 ` [PATCHv2 1/4] kernel-devicetree.bbclass: Use lowercase names for shell variables Martin Jansa
2018-07-02 22:07 ` [PATCHv2 2/4] kernel-devicetree.bbclass: Fix and simplify instalation of DTB files Martin Jansa
2018-07-02 22:07 ` [PATCHv2 3/4] kernel.bbclass: use the consistent naming schema for initramfs Martin Jansa
2018-07-02 22:07 ` [PATCHv2 4/4] kernel.bbclass: move variables for kernel artifacts names to separate bbclass Martin Jansa
2018-07-04 7:59 ` [PATCHv3 1/4] kernel-devicetree.bbclass: Use lowercase names for shell variables Martin Jansa
2018-07-04 7:59 ` [PATCHv3 2/4] kernel-devicetree.bbclass: Fix and simplify instalation of DTB files Martin Jansa
2018-07-04 8:54 ` Paulo Neves
2018-07-04 9:18 ` Martin Jansa
2018-07-04 7:59 ` [PATCHv3 3/4] kernel.bbclass: use the consistent naming schema for initramfs Martin Jansa
2018-07-04 7:59 ` [PATCHv3 4/4] kernel.bbclass: move variables for kernel artifacts names to separate bbclass Martin Jansa
2018-07-05 8:21 ` [PATCHv3 1/4] kernel-devicetree.bbclass: Use lowercase names for shell variables Richard Purdie
2018-07-09 15:04 ` Martin Jansa
2018-07-09 15:04 ` [PATCHv4 " Martin Jansa
2018-07-09 15:04 ` [PATCHv4 2/4] kernel-devicetree.bbclass: Fix and simplify instalation of DTB files Martin Jansa
2018-07-09 15:04 ` [PATCHv4 3/4] kernel.bbclass: use the consistent naming schema for initramfs Martin Jansa
2018-07-09 15:05 ` [PATCHv4 4/4] kernel.bbclass: move variables for kernel artifacts names to separate bbclass Martin Jansa
2018-07-04 20:06 ` [PATCH] Revert "kernel-devicetree: Corrected normalize_dtb" Martin Jansa
2018-07-05 7:15 ` Nicolas Dechesne
2018-07-05 8:23 ` Richard Purdie
2018-07-05 8:38 ` Martin Jansa
2018-07-05 10:37 ` Richard Purdie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1511207344.git.Martin.Jansa@gmail.com \
--to=martin.jansa@gmail.com \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox