<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/meta/classes-global, branch scarthgap-5.0.13</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=scarthgap-5.0.13</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=scarthgap-5.0.13'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2025-01-09T14:25:36+00:00</updated>
<entry>
<title>sanity.bbclass: skip check_userns for non-local uid</title>
<updated>2025-01-09T14:25:36+00:00</updated>
<author>
<name>Changqing Li</name>
<email>changqing.li@windriver.com</email>
</author>
<published>2024-10-17T11:15:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=11ebb861115168d6a488975f80e4540d908002d1'/>
<id>urn:sha1:11ebb861115168d6a488975f80e4540d908002d1</id>
<content type='text'>
Bitbake preserve network for non-local uid, refer [1],
so check_userns is not needed for non-local uid

[1] https://git.openembedded.org/bitbake/commit/?id=4eafae7904bae6e5c6bc50356e8a9077f2e207fa

(From OE-Core rev: c3e0666dd2624c20c5f32657846d6f044046205b)

Signed-off-by: Changqing Li &lt;changqing.li@windriver.com&gt;
Signed-off-by: Mathieu Dubois-Briand &lt;mathieu.dubois-briand@bootlin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 808d0cece22bcbee15236717e158da247cbedaf1)
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>sanity: check for working user namespaces</title>
<updated>2024-12-13T13:21:54+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross.burton@arm.com</email>
</author>
<published>2024-09-12T16:57:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=61ec07c6cf2c1cd35eb1f0d4b904b45ac965724f'/>
<id>urn:sha1:61ec07c6cf2c1cd35eb1f0d4b904b45ac965724f</id>
<content type='text'>
If user namespaces are not available (typically because AppArmor is
blocking them), alert the user.

We consider network isolation sufficiently important that this is a fatal
error, and the user will need to configure AppArmor to allow bitbake to
create a user namespace.

[ YOCTO #15592 ]

(From OE-Core rev: 3577ceca39c7c3be81563de9ccf06a805f61d3ca)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit b6af956fe6e876957a49d4abf425e8c789bf0459)
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>do_package/sstate/sstatesig: Change timestamp clamping to hash output only</title>
<updated>2024-12-09T14:54:14+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2024-10-25T13:31:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=de0a865f2db91753190fcd5dc20e59c89e02d42e'/>
<id>urn:sha1:de0a865f2db91753190fcd5dc20e59c89e02d42e</id>
<content type='text'>
The code was changing the timestamps of the files in the do_package output,
particularly the files added for debug sources. This was to do two things:

a) make do_package sstate more reproducible
b) ensure better hash equivalence matching

Unfortuately the debug source files are hardlinks into the source tree for
efficiency so touching these, touches a lot of files in ${B} and ${S}. This
causes unpredictable effects if compile is run again for example, or could
cause compiling in the install task.

The hash equivalence matching is of key importance but we can mimic that
using clamping of the file timestamps in the depsig output used to generate
the hashes.

This patch drops the global timestamp clamping, instead allowing the files
to retain their creation timestamps into sstate. This makes do_package sstate
slightly less reproducibile. We could clamp the sstate timestamps but that
would lead to two different sets of timestamps depending on whether the
data came from sstate or not. I'd prefer to have consistent code behaviour,
rather than differing behavhour depending on whether data came from sstate
or not.

If we wanted to have reproducibiliy and fix the "corruption" of S/B and have
consistent codepaths, the only other option would be two copies of the
sources, which could end up huge and seems the least desireable option.

This patch therefore drops the timestamp clamping in the sstate files
and tweaks the depsig data generation to clamp the timestamps for do_package
instead since this seems the best compromise.

I validated that rpm/deb/ipk files still generate correctly as before.

(From OE-Core rev: 9df0bf5775ec96773e77c489ba6a443037d65ab6)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 475759fdab7200488b2a568b2ba1aa31a456d113)
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>package_rpm: Check if file exists before open()</title>
<updated>2024-11-26T14:11:30+00:00</updated>
<author>
<name>Pavel Zhukov</name>
<email>pavel@zhukoff.net</email>
</author>
<published>2024-10-10T17:45:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=1a526844db586a84978f23393b981da76c55ae41'/>
<id>urn:sha1:1a526844db586a84978f23393b981da76c55ae41</id>
<content type='text'>
Exception handler tries to read() /etc/passwd file in sysroot
and if file doesn't exist for any reason then it raises FileNotFoundError
exception which mask the original source of the problem and makes
debugging of the issue more difficult.

Fixes:
Exception: FileNotFoundError: [Errno 2] No such file or directory:
'/codebuild/output/src1899304708/src/build/tmp-container/work/core2-64-oe-linux/emqx-bin/4.3.12/recipe-sysroot/etc/passwd'

(From OE-Core rev: 1adfa8b78991764ed1f9951c5bee5412553f3b9d)

Signed-off-by: Pavel Zhukov &lt;pavel@zhukoff.net&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 4ad9a0e0b11eb7bc5a3dd45fc8945e094ea949e9)
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>package_rpm: restrict rpm to 4 threads</title>
<updated>2024-11-26T14:11:30+00:00</updated>
<author>
<name>Alexander Kanavin</name>
<email>alex@linutronix.de</email>
</author>
<published>2024-11-21T13:42:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=7bbee0e49e4de46875a557383bc38c017ac536b0'/>
<id>urn:sha1:7bbee0e49e4de46875a557383bc38c017ac536b0</id>
<content type='text'>
TL;DR version:

with this, and the previous compression level changes
I am seeing drastic speedups in package_write_rpm completion times:

webkitgtk goes from 78 seconds to 37 seconds
glibc-locale goes from 399 seconds to 58 seconds (!)

The long version:

rpm uses multithreading for two purposes:

- spawning compressors (which are nowadays themselves
multi-threaded, so the feature is not as useful as it once
was)
- parallel file classification

While the former behaves well on massively parallel CPUs
(it was written and verified here :), the latter was then added
by upstream and only benchmarked on their very old, slow laptop,
apparently:
https://github.com/rpm-software-management/rpm/commit/41f0e214f2266f02d6185ba11f797716de8125d4

On anything more capable it starts showing pathologic behavior,
presumably from spawning massive amount of very short-lived threads,
and then having to synchronize them. For example classifying glibc-locale
takes
5m20s with 256 threads (default on my machine!)
1m49s with 64 threads
59s with 16 threads
48s with 8 threads

Even a more typical recipe like webkitgtk is affected:
47s with 256 threads
32s with 64 threads
27s with 16 or 8 threads

I have found that the optimal amount is actually four: this also
means that only four compressors are running at a time, but
as they're themselves using threads, and typical recipes are dominated
by just two or three large packages, this does not affect overall
completion time.

(From OE-Core rev: 8cbf3a2cddbff1728bd3d1382c3fec00b604501e)

Signed-off-by: Alexander Kanavin &lt;alex@linutronix.de&gt;
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>package_rpm: use zstd's default compression level</title>
<updated>2024-11-26T14:11:30+00:00</updated>
<author>
<name>Alexander Kanavin</name>
<email>alex@linutronix.de</email>
</author>
<published>2024-11-21T13:42:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=71da054b97d002d38aa0cf65d3756a4b147936f7'/>
<id>urn:sha1:71da054b97d002d38aa0cf65d3756a4b147936f7</id>
<content type='text'>
zstd uses 3 by default, while 19 is the highest and slowest.
It's not clear why 19 was picked to begin with, possibly
I copy-pasted it from rpm's examples without thinking:
https://git.yoctoproject.org/poky/commit/?h=master-next&amp;id=4a4d5f78a6962dda5f63e9891825c80a8a87bf66

This brings significant speedups in rpm's compression step:
for example compressing webkitgtk takes 11s instead of 36s.

The rpm size increases from 175648k to 234860k. I think it's
a worthy default tradeoff.

(From OE-Core rev: 515fc186d796eaf3bfce41bd17a908ff283242ce)

Signed-off-by: Alexander Kanavin &lt;alex@linutronix.de&gt;
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>license: Fix directory layout issues</title>
<updated>2024-10-18T13:04:40+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2024-10-10T21:49:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=75ac1f529a22e56988bda53b58d2cc34fb7baea4'/>
<id>urn:sha1:75ac1f529a22e56988bda53b58d2cc34fb7baea4</id>
<content type='text'>
There are several issues:

a) pointless empty directories were being created as a path wasn't
   fixed in a previous commit
b) SSTATE_PKGARCH wasn't being captured into the task signature
   since it is in the ignore list by default. We want to capture
   the absolute value, not the dependencies
c) with those issues fixed, cross/native issues became apparent so
   those need to be fixed too.

(From OE-Core rev: a31b46627a85ea871deb760f3d0008de72ceb439)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;

Backport from oe-core master: f68aed302a0e4b86fb8c16a6ef4e7295bed48b86

Signed-off-by: Mark Hatle &lt;mark.hatle@kernel.crashing.org&gt;
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>buildhistory: Simplify intercept call sites and drop SSTATEPOSTINSTFUNC usage</title>
<updated>2024-09-25T12:07:47+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2024-08-29T11:57:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=0979d14d5487928d0b4655731d932a56fd39d347'/>
<id>urn:sha1:0979d14d5487928d0b4655731d932a56fd39d347</id>
<content type='text'>
We planned to drop SSTATEPOSTINSTFUNC some time ago with the introduction of
postfuncs. Finally get around to doing that which should make the buildhistory
code a little more readable.

Unfortunately ordering the buildhistory function calls after the sstate ones is
difficult without coding that into the sstate class. This patch does that to
ensure everything functions as expected until we can find a better way. This is
still likely preferable than the generic sstate postfuncs support since the function
flow is much more readable.

(From OE-Core rev: 466c505b779dec2ba790f4e6cde7fbb35037f4ef)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit c9e2a8fa2f0305ef1247ec405555612326f798f8)
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>insane.bbclass: remove leftover variables and comment</title>
<updated>2024-07-26T14:43:46+00:00</updated>
<author>
<name>Emil Kronborg</name>
<email>emil.kronborg@protonmail.com</email>
</author>
<published>2024-05-23T12:56:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=6879650b927c96a2464224cdc2bed8245511cbf1'/>
<id>urn:sha1:6879650b927c96a2464224cdc2bed8245511cbf1</id>
<content type='text'>
The code that used these variable and the comment was introduced in
commit b44d32ef41ef ("insane.bbclass: Portions of code were not running,
fix this and sync with OE.dev. Also add tests for bad sysroot rpaths in
binaries"). Later, in commit 17dae13fabe2 ("insane.bbclass: Fix ELF
bitsize comparison"), some of that code was removed again, but not the
variables and the comment.

(From OE-Core rev: c00a9a8f25b0042b0723a5d20b88e92d473d22bf)

Signed-off-by: Emil Kronborg &lt;emil.kronborg@protonmail.com&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
(cherry picked from commit 730d00b0d1d1d617b62900be12fa034bb41fc48b)
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
<entry>
<title>insane.bbclass: fix HOST_ variable names</title>
<updated>2024-07-26T14:43:46+00:00</updated>
<author>
<name>Emil Kronborg</name>
<email>emil.kronborg@protonmail.com</email>
</author>
<published>2024-05-23T12:55:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=8cb7901a51a0e2562624fff020a392413250be0d'/>
<id>urn:sha1:8cb7901a51a0e2562624fff020a392413250be0d</id>
<content type='text'>
Commit cd25e5544ca3 ("insane: use HOST_ variables, not TARGET_ to
determine the cross system") updated the variables themselves, but not
their names. To prevent confusion, match the Python variable name to the
BitBake variable name.

(From OE-Core rev: 7fd25eaa8fd5533d03d5f10792e2e6c30c64cc3c)

Signed-off-by: Emil Kronborg &lt;emil.kronborg@protonmail.com&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
(cherry picked from commit f5bebc96580ec74d10bc96b4265357ebc9bcd6ad)
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
</content>
</entry>
</feed>
