Restore ability to use (and test!) zephyr/docker-build.sh locally
without overwriting work in progress.
Fixes commit b371373f7d ("scripts: docker-build.sh updated with
changes from xtensa-build-zephyr.py")
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Removed old flags from python script call and replaced with
new one. Added one more working directory to zephyr-build container
now SOF is placed in /workdir/sof and west workspace in /workdir .
Signed-off-by: Andrey Borisovich <andrey.borisovich@intel.com>
This fixes SOF version.cmake which was just broken by a recent git
security update and started to fail like this:
```
-- SOF version.cmake starting at 2022-04-25T18:14:56Z UTC
-- /workdir/zephyr/.. is at git commit with parent(s):
fatal: unsafe repository ('/workdir' is owned by someone else)
To add an exception for this directory, call:
git config --global --add safe.directory /workdir
```
(example at https://github.com/thesofproject/sof/runs/6162885265)
chgrp -R was always an ugly hack because it was messing with
(persistent) file permissions on the host, outside the container. This
new adduser solution is unfortunately much more code but it does not
leak any side effect outside the container.
Do not fix scripts/docker-run.sh yet because there is still no UID
mismatch between Github Actions and the SOF container (they're both
1001) but add a warning + TODO.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Currently set to obsolete 0.12.4. Better remove it here for everyone
rather than overriding it in Github Actions only.
Also symlinks the toolchains in /opt to /home to fix autodetection
Signed-off-by: Marc Herbert <marc.herbert@intel.com>