Commit 475e09f17d ("xtensa-build-zephyr.py: default to
subprocess.run(check=True)") switched the default value of the
execute_command() function to "True". Remove all the "check=True"
arguments that are now redundant.
Zero functional change.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
This reduces the number of warnings from about 600 to a more manageable
350.
Disable W0312 because the entire file uses tabs.
Disable C0103 because we have higher priority than naming conventions.
Disable C0116 because the script is small enough, shouldn't require
pydoc everywhere.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Move software configuration from Zephyr samples directory
to SOF platforms directory using Zephyr overlay mechanism.
How it works:
1. Gets zephyr board defconfig values
2. Applies Zephyr samples prj.conf values on top of it
3. Then applies our new overlay.conf on top of it
4. Final "summary" of Kconfig settings is written to autoconf.h header
Signed-off-by: Andrey Borisovich <andrey.borisovich@intel.com>
This restores the performance of the original shell script and makes a
big difference in CI. CI clones over and over again whereas developers
clone rarely and can run a simple git fetch --unshallow.
Don't use --depth 0 to provide more context in the logs and also make it
more obvious that this is a shallow clone and not just git log -n 1.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Running on a mac crashed with "undefined xtensa_tools_version_postfix",
that should not be fatal (there are other toolchains).
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Duplicating all parameters of subprocess.run() is not just tedious and
error-prone, it makes the script compatible only with a range of
specific Python versions.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Use intel_adsp_cavs20_jsl Zephyr board when building for
Intel Jasper Lake.
BugLink: https://github.com/thesofproject/sof/issues/4539
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
This script is run from an existing SOF repo that is assumed to be fully
initialized. Updating existing submodules is a potentially destructive
operation.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
The older shell script had a deprecated convenience hack to clone
submodules before building rimage but _only if submodules were missing_!
While trying to preserve that, the new script changed that to an
unconditional git submodule update that can be destructive when
submodules are already present.
Generally speaking, using git and building must always be two very
distinct activities. No one wants the source code to change quietly from
one build to the next.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
A second git_submodules_update() immediately after the first one does
not make sense. This looks like something leftover from a past
experiment.
Fixes initial commit 1de3ef3675 ("Rewritten xtensa-build-zephyr.sh to
python")
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
PosixPath doesn't convert to string automatically, and
it is not acceptable in sign_cmd, convert it to string
explicitly.
Signed-off-by: Chao Song <chao.song@linux.intel.com>
Zephyr recently added support for separate configs for 2-core and 4-core
variants of cAVS2.5. Use the new "tgph" configuration for when building
SOF for TigerLake-H variant.
BugLink: https://github.com/thesofproject/sof/issues/5018
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
The most important fix is the addition of the "flush" argument which
means are commands are now printed when they are run and not all at the
end when everything is done.
Commands run by this script are very few so they are always shown. This
makes it possible to debug just this script without being completely
drown in build noise. All '-v's are passed to west.
Pass -v to `west sign`, not just to `west build`.
Drop the manual "-DCMAKE_VERBOSE_MAKEFILE=ON", west knows how to do that.
Print directories first so commands are aligned, more visible and can be
copied. Use shlex to quote whitespace.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Make it possible to invoke -C multiple times which is required to
support whitespace as in:
-C=--warn-uninitialized -C '-DEXTRA_FLAGS=-Werror -g0'
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Existing xtensa-build-zephyr.py failed to copy sof logger
executable to staging directory due to missing '.exe' file extension.
This fixes the script.
Signed-off-by: Andrey Borisovich <andrey.borisovich@intel.com>
Created new script with similar functionality to allow SOF + Zephyr
builds on both Windows and Linux operating systems.
Signed-off-by: Andrey Borisovich <andrey.borisovich@intel.com>