<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/scripts/lib/checklayer/__init__.py, branch yocto-4.0.8</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=yocto-4.0.8</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=yocto-4.0.8'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2022-12-23T23:05:50+00:00</updated>
<entry>
<title>yocto-check-layer: Allow OE-Core to be tested</title>
<updated>2022-12-23T23:05:50+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2022-12-12T03:07:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=5c7103d6c70670c7bd0913cca37d444d7fe1c5a6'/>
<id>urn:sha1:5c7103d6c70670c7bd0913cca37d444d7fe1c5a6</id>
<content type='text'>
For unknown reasons we've never seemingly run the check layer script
against OE-Core itself. This isn't entirely straightforward as the core
layer is a bit of a special case, we can't for example compare signatures
against ourselve and we can't remove core from bblayers.conf.

Core does have distro, machine and software components too, in the case
of distro, our fallback default settings. Whilst the qemu machines could
be split into a seperate layer directory, core wouldn't then parse at all
standalone due to the lack of any machine so it seems a bit pointless to
do that.

These changes tweak the script to handle core's special cases, specifically
to allow distro and machine directories and to account for the README placed
a directory level higher than other layers.

(From OE-Core rev: 2d0641df27196ad029d95c52fb790122b2db3f9f)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Steve Sakoman &lt;steve@sakoman.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>meta/scripts: Change BB_ENV_EXTRA_WHITE -&gt; BB_ENV_PASSTHROUGH_ADDITIONS</title>
<updated>2022-02-21T23:37:26+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2022-02-16T13:36:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=492214104a55ec56cc483c9b045038e355c6af7b'/>
<id>urn:sha1:492214104a55ec56cc483c9b045038e355c6af7b</id>
<content type='text'>
After the change to bitbake, update the references in OE-Core to match the updates.

(From OE-Core rev: 193affb9f28b0116c3fd619834f145326fee08c5)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>yocto-check-layer: add ability to perform tests from a global bbclass</title>
<updated>2022-02-21T23:37:26+00:00</updated>
<author>
<name>Denys Dmytriyenko</name>
<email>denis@denix.org</email>
</author>
<published>2022-02-01T03:16:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=bb4f2bfcecdf2ec9ede6f60f250fde130414c4ef'/>
<id>urn:sha1:bb4f2bfcecdf2ec9ede6f60f250fde130414c4ef</id>
<content type='text'>
This is useful when needing to test layer's recipes, where this special
bbclass can define a global python function that gets called on each
recipe parsing during "bitbake -S none world" signature dump and be able
to fail layer's check accordingly.

First test being added is to detect recipes skipping "installed-vs-shipped"
QA check. As "installed-vs-shipped" is a packaging QA check, it happens very
late in the build process and failing it could mean some potential issues
with packaging, especially when recipe uses BBCLASSEXTEND="nativesdk" and
resulting package is used in an SDK.

In OE-Core failing this QA check leads to an error, but other layers can
suppress it or change it to a warning. Detecting weird packaging problems
with SDKs is quite difficult and time consuming. Also, waiting for the
actual "installed-vs-shipped" packaging QA check to fail means that all
recipes in the layer under test have to run through all standard tasks in
the build chain, equivalent to a multi-hour world-build.

Hence yocto-check-layer takes a shortcut and only detects a mere attempt
at skipping "installed-vs-shipped" QA check in the INSANE_SKIP list during
initial parsing when dumping the signature information for the layer.

(From OE-Core rev: e8baa75535fc888f1d768b23a0140475e832c910)

Signed-off-by: Denys Dmytriyenko &lt;denis@denix.org&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>yocto-check-layer: check for duplicate layers when finding layers</title>
<updated>2022-02-05T17:46:05+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross@burtonini.com</email>
</author>
<published>2022-02-02T13:00:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=8463a37d70e104b7c23328baf0265f57bdcba12d'/>
<id>urn:sha1:8463a37d70e104b7c23328baf0265f57bdcba12d</id>
<content type='text'>
detect_layers() is very greedy and if it recurses into poky or bitbake
it will find the test suite layers, such as
bitbake/lib/layerindexlib/tests/testdata/layer4. This is a dummy layer
which claims to be openembedded-layer, so if the real openembedded-layer
is a dependency then layer4 may be used instead, which will cause
errors: initially because it's only compatible with Sumo, but later
because it doesn't contain any recipes.

Add a check that the set of layers we've found doesn't contain any
duplicate collection names with different patterns, and abort if that is
the case as the test will be non-deterministic.

(From OE-Core rev: 0df4bae4ec67d38442620fa08c839528b425e2a8)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>checklayer: rename _find_layer_depends</title>
<updated>2021-07-28T22:47:00+00:00</updated>
<author>
<name>Nicolas Dechesne</name>
<email>nicolas.dechesne@linaro.org</email>
</author>
<published>2021-07-22T12:46:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=8dbef94dce59c70c5904e418647eae6a4365163c'/>
<id>urn:sha1:8dbef94dce59c70c5904e418647eae6a4365163c</id>
<content type='text'>
What this function does is really to find a layer, not a 'depends'. We
are using this function to find a dependent layer, but the name is
confusing.

(From OE-Core rev: e9b7690ab30d0e7c07471034f6cb89ccc3168a11)

Signed-off-by: Nicolas Dechesne &lt;nicolas.dechesne@linaro.org&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>checklayer: new function get_layer_dependencies()</title>
<updated>2021-07-28T22:47:00+00:00</updated>
<author>
<name>Nicolas Dechesne</name>
<email>nicolas.dechesne@linaro.org</email>
</author>
<published>2021-07-22T12:46:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=4f452a8be1088ba4bf5da79059de375e3f9ae7c0'/>
<id>urn:sha1:4f452a8be1088ba4bf5da79059de375e3f9ae7c0</id>
<content type='text'>
Split add_layer_dependencies() into 2 parts. First search for layer
dependencies, and then add them to the config. That allows us to
call get_layer_dependencies() independently.

(From OE-Core rev: 08edf928aac3f2daaa0c256d4c21e56e2db72bff)

Signed-off-by: Nicolas Dechesne &lt;nicolas.dechesne@linaro.org&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>checklayer: check layer in BBLAYERS before test</title>
<updated>2020-07-27T09:37:58+00:00</updated>
<author>
<name>Lee Chee Yang</name>
<email>chee.yang.lee@intel.com</email>
</author>
<published>2020-07-24T04:16:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=4cbea1019781e9595655448347a38dae1db5ee29'/>
<id>urn:sha1:4cbea1019781e9595655448347a38dae1db5ee29</id>
<content type='text'>
layer under test should absent from BBLAYERS when running
yocto-check-layer. This allow to get signatures before layer
under test. There are existing steps to add the layer under
test to BBLAYERS after getting initial signatures.

add steps to check for layer under test in BBLAYERS before
running any test, skip test for the layer if the layer under
test exist in BBLAYERS.

[YOCTO #13176]

(From OE-Core rev: be02e8dbfb0d1decce125322f9f1e11a649756c0)

Signed-off-by: Lee Chee Yang &lt;chee.yang.lee@intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>checklayer: parse LAYERDEPENDS with bb.utils.explode_dep_versions2()</title>
<updated>2020-06-28T07:36:00+00:00</updated>
<author>
<name>Nicolas Dechesne</name>
<email>nicolas.dechesne@linaro.org</email>
</author>
<published>2020-06-26T12:29:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=c0a16eaae08edaa21c551947726b189a1afec1ae'/>
<id>urn:sha1:c0a16eaae08edaa21c551947726b189a1afec1ae</id>
<content type='text'>
LAYERDEPENDS is a string of this format:
"DEPEND1 (optional version) DEPEND2 (optional version) ..."

However when we parse LAYERDEPENDS in _get_layer_collections() we
parse it as a simple string, and if any optional versions are there the
'depends' field is wrong. For example, running yocto-check-layer
might result in such errors:

ERROR: Layer meta-python depends on (&gt;= and isn't found.
ERROR: Layer meta-python depends on 12) and isn't found.

Let's use bb.utils.explode_dep_versions2() to parse LAYERDEPENDS, and
create a string that contains all dependencies, effectively
skipping/ignoring any optional versions.

[YOCTO #13957]

(From OE-Core rev: f81f07afc200fe06c5c06ea81a4f8a3a43436faf)

Signed-off-by: Nicolas Dechesne &lt;nicolas.dechesne@linaro.org&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>checklayer: Skip layers without a collection</title>
<updated>2020-05-24T22:56:03+00:00</updated>
<author>
<name>Joshua Watt</name>
<email>JPEWhacker@gmail.com</email>
</author>
<published>2020-05-22T22:08:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=57daea00de5676315c99c6791f6dfbd6957989d3'/>
<id>urn:sha1:57daea00de5676315c99c6791f6dfbd6957989d3</id>
<content type='text'>
As in other places in the file, skip layers that don't define a
collection when searching for a layer to resolve a dependency. Fixes
KeyError exceptions when attempting to access the layer collections
later

(From OE-Core rev: 26090a2861ebe21224aaf89d7be0c0a89ca58e48)

Signed-off-by: Joshua Watt &lt;JPEWhacker@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>yocto-check-layer: Ensure we use OEBasicHash as the signature handler</title>
<updated>2019-08-21T14:29:01+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2019-08-14T21:34:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=d67fbf68f6923431e6c825cc92e0059d7dc901fb'/>
<id>urn:sha1:d67fbf68f6923431e6c825cc92e0059d7dc901fb</id>
<content type='text'>
The layer checks are designed to work with OEBasicHash so ensure that handler
is in use rather than the new hash equivalency one as an example.

(From OE-Core rev: a10bf92516a4771e2dc49ba9f74323d7a87a1619)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
