5 Commits

Author SHA1 Message Date
Peter Hoyes
81babac06d zephyr-core/scripts: Resolve West revisions to SHAs
The West manifest in  Zephyr 3.3 contains a tag (instead of a SHA) for
zcbor [1]. OE standard practice is to always specifiy revisions using
SHAs, so in the Jinja template, use the new resolve_revision filter to
resolve any tags.

[1] https://github.com/zephyrproject-rtos/zephyr/pull/51219#discussion_r998123145

Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>
Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
2023-04-20 15:02:55 +08:00
Peter Hoyes
0a05d27d14 zephyr-core/scripts: Resolve Zephyr tag using git ls-remote
To simplify the logic to resolve Git tags to SHAs, and so that it works
with non-Github repositories, use git ls-remote instead of the Github
API.

Make the resolve_revision function available as a Jinja filter and move
the version resolution to the template.

Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>
Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
2023-04-20 15:02:55 +08:00
Peter Hoyes
d075b06ade zephyr-core/zephyr-kernel: Remove the downstream "yocto" toolchain
The "yocto" toolchain requires a downstream patch to be carried and
maintained. The upstream "cross-compile" toolchain is equivalent so this
is no longer needed.

Remove the toolchain-specific inc file and the downstream patch.

Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>
Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
2023-02-24 16:24:35 +08:00
Peter Hoyes
1312cb2a19 zephyr-core/zephyr-kernel: Add ZEPHYR namespace to SRC_URI variables
Certain SRC_URI_* variables may collide with other recipes, e.g.
SRC_URI_TRUSTED_FIRMWARE_A. Namespace these variables under
SRC_URI_ZEPHYR so that the SRC_URIs of Zephyr modules can be
independently tweaked from local.conf or the environment.

Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>
Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
2023-01-26 16:45:44 +08:00
Peter Hoyes
f12da18fe0 zephyr-core/scripts: Introduce script to generate new versions
Add a Python script which can be used to automatically generate
configuration for new Zephyr versions. This script:
 * Takes the Zephyr version as a single argument
 * Uses the Github API to find the version tag's SHA1
 * Uses West as a library to parse the version's manifest file
 * Uses a Jinja template to generate a .inc file for the version
 * Outputs the .inc file directly into the zephyr-kernel directory

The generated .inc file includes:
 * SRCREVs for all modules
 * Separate SRC_URI_x variables for each module, to make it easier to
   swap out a specific URL for a fork or mirror
 * A version-specific SRC_URI, containing only the modules defined in
   the release
 * A list of the ZEPHYR_MODULES

Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>
Tested-by: Jon Mason <jon.mason@arm.com>
Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
2022-09-21 11:51:20 +08:00