zephyr/scripts
Torsten Rasmussen 64ec6ee3a3 scripts: build meta file workspace status extension
The PR #39382 raised a discussion on build reproducibility and knowledge
of west projects being out of sync with the west manifest.

Similar to how `git submodules` will report the working tree dirty if
any of the submodules HEAD points to a SHA different than the one
recorded in the super project.

Based on this discussion this commit extends the Zephyr build meta file
with overall workspace status included in the meta file.

It adds the following meta info to the build meta file:
> workspace:
>  dirty: false / true
>  extra: false / true
>  off:   false / true

A project using west and having an extra Zephyr module loaded not
controlled using git and a west project at a SHA different than the
SHA referenced by the manifest can look like:
zephyr:
  path: /.../zephyr
  revision: 863600cd0e
modules:
- name: mcuboot
  path: /.../bootloader/mcuboot
  revision: c61538748ead773ea75a551a7beee299228bdcaf
- name: local_module
  path: /.../local_module
  revision: null
west:
  manifest: /.../zephyr/west.yml
  projects:
  - path: /.../zephyr
    revision: 863600cd0e
  - path: /.../bootloader/mcuboot
    revision: c61538748ead773ea75a551a7beee299228bdcaf-off
  - path: /.../tools/net-tools
    revision: f49bd1354616fae4093bf36e5eaee43c51a55127
workspace:
  dirty: false
  extra: true
  'off': true

And without west:
zephyr:
  path: /.../zephyr
  revision: 863600cd0e
modules:
- name: hal_nordic
  path: /.../modules/hal/nordic
  revision: a6e5299041f152da5ae0ab17b2e44e088bb96d6d
- name: local_module
  path: /.../local_module
  revision: null
workspace:
  dirty: false
  extra: true

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2021-12-14 12:32:10 +01:00
..
checkpatch scripts: checkpatch: typedefsfile: add pinctrl_soc_pin_t 2021-12-03 13:21:40 +01:00
ci actions: clang: do not test all boards when --platform is given 2021-12-09 16:23:22 +01:00
coccinelle coccinelle: check reserved symbols based on a file 2021-04-30 22:09:43 -04:00
coredump coredump: add support for RISC-V 2021-12-08 08:54:32 -05:00
dts scripts: gen_defines: zephyr,linker-region unique 2021-12-09 16:23:03 +01:00
footprint scripts/arch: remove usage of deprecated LooseVersion 2021-11-19 19:16:11 -05:00
gitlint
kconfig scripts/Kconfig: add dt_node_str_prop_equals Kconfig function 2021-11-24 12:28:02 +01:00
logging/dictionary scripts: colorize parsed dictionary logging 2021-07-16 21:34:06 -04:00
net net: scripts: Make test runner script fully generic 2020-11-20 16:07:59 +02:00
pylib/twister scripts/pylib/twister: Add sn option to stm32cubeprogrgammer runner 2021-12-13 17:20:17 -05:00
release scripts: add script to extract top-ten bug-bashers 2021-09-01 17:06:50 -04:00
schemas/twister twister: fix the testcase-schema.yaml 2021-11-19 11:46:38 -05:00
support
tests ztest: add a weak implementation of test_main() 2021-10-28 16:57:51 -04:00
tracing tracing: scripts: add scripts for parsing ctf data 2020-08-24 13:21:12 +02:00
utils scripts: utils: add pinctrl migration script for nRF boards 2021-11-26 14:20:51 +01:00
west_commands scripts: runners: Add west flash command for B91 platform 2021-12-06 07:28:38 -05:00
.gitignore cleanup: rename sanitycheck references to twister 2021-01-14 07:50:52 -06:00
checkpatch.pl checkpatch: Add UTIL_CAT support to checkpatch 2021-12-04 07:22:56 -05:00
checkstack.pl
coccicheck scripts: Fix documunt referenc for coccicheck 2020-05-08 17:44:44 +02:00
dir_is_writeable.py
file2hex.py scripts: file2hex.py: PEP 8 style fix 2020-06-12 11:09:58 +02:00
gen_app_partitions.py scripts: support compile_commands.json in gen_app_partitions.py 2021-11-25 10:41:28 -05:00
gen_cfb_font_header.py zephyr: replace zephyr integer types with C99 types 2020-06-08 08:23:57 -05:00
gen_gcov_files.py scripts: gen_gcov_files.py: add argument help text 2020-06-13 16:33:22 -04:00
gen_handles.py device: iterable supported devices 2021-11-23 12:17:14 +01:00
gen_kobject_list.py scripts/arch: remove usage of deprecated LooseVersion 2021-11-19 19:16:11 -05:00
gen_kobject_placeholders.py scripts: gen_kobject_placeholders: iterating the dictionary directly 2021-11-19 19:16:11 -05:00
gen_offset_header.py scripts: gen_offset_header: add argument help text 2020-05-21 14:45:24 +02:00
gen_relocate_app.py scripts: gen_relocate_app: check if argument matches 2021-11-02 22:26:41 -04:00
gen_syscalls.py Tracing: TRACING_SYSCALL status ignored fix 2021-10-26 15:13:08 -04:00
get_maintainer.py scripts: get_maintainer: add count function 2021-10-18 08:36:21 -04:00
list_boards.py scripts: list_boards: handle boards dirs with subset of architectures 2021-06-11 16:26:30 +02:00
mergehex.py scripts: cmake: move print from python to cmake 2020-01-03 08:20:08 -05:00
parse_syscalls.py userspace: net sockets are kernel objects 2020-06-03 22:33:32 +02:00
process_gperf.py scripts/arch: remove usage of deprecated LooseVersion 2021-11-19 19:16:11 -05:00
requirements-base.txt requirements: bump west to >=0.10.1 2021-05-18 09:52:12 -05:00
requirements-build-test.txt scripts: move pip pykwalify from requirements-build-test to -base 2021-01-18 16:56:24 -05:00
requirements-compliance.txt requirements-compliance: restrict junitparser version < 2 2021-01-13 07:58:37 -05:00
requirements-doc.txt requirements-doc: add PyYAML which removes dependency on -base 2021-06-16 10:39:08 +02:00
requirements-extras.txt scripts: add script to extract top-ten bug-bashers 2021-09-01 17:06:50 -04:00
requirements-run-test.txt requirements: Update to pyocd 0.29 for LPC55S69 support 2021-01-21 15:53:22 -05:00
requirements.txt python3: add check_compliance package requirements 2020-08-11 14:49:48 -04:00
series-push-hook.sh scripts: series-push-hook: Use main as base comparison branch 2021-05-27 15:55:43 -05:00
spelling.txt
subfolder_list.py scripts: subfolder_list.py: refactor the code 2020-07-20 17:31:53 -04:00
tags.sh scripts: Update paths on tags.sh 2021-02-19 05:28:09 -06:00
twister twister: remove redundant required for generate-hardware-map 2021-12-13 08:46:15 -05:00
uf2conv.py cmake: Add UF2 as an additional build output option. 2021-02-23 21:11:04 +01:00
user_wordsize.py posix arch: build on aarch64 / allow host-specific cmake includes 2020-05-09 12:17:24 +02:00
valgrind.supp
west-commands.yml west: spdx: Generate SPDX 2.2 tag-value documents 2021-05-05 11:14:06 -04:00
zephyr_module.py scripts: build meta file workspace status extension 2021-12-14 12:32:10 +01:00