Commit Graph

8 Commits

Author SHA1 Message Date
Marc Herbert d09844ab98 zephyr/docker-build.sh: match UID with 'adduser' instead of 'chgrp -R'
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>
2022-04-26 22:08:53 +01:00
Marc Herbert e2db3bcdb9 .github: switch to new xtensa-build-zephyr.py
Switch Github Actions away from older shell script.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-02-24 14:54:50 +00:00
Marc Herbert 63ce1d6b51 zephyr/docker-build: fix "stale" ZEPHYR_SDK_INSTALL_DIR comment
It's apparently not stale but "stable".

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2021-09-29 16:58:24 +01:00
Marc Herbert 1b4b3a575b zephyr/docker-build: unset stale ZEPHYR_SDK_INSTALL_DIR, symlink toolchains
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>
2021-09-28 16:13:27 +01:00
Marc Herbert a0ab594045 zephyr/docker-build.sh: pass arguments through to xtensa-build-zephyr.sh
Allows passing compilation flags and any other argument.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2021-09-09 15:48:18 +01:00
Marc Herbert 2802f2a40a zephyr/docker-build.sh: apt-get install tree
To show the staging area at the end of the Zephyr build

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2021-07-13 15:56:49 +01:00
Marc Herbert 55025f6343 zephyr/docker-build.sh: remove apt update / install libssl-dev
The Zephyr image has been updated in
https://github.com/zephyrproject-rtos/docker-image/pull/58

This will save some time and even better avoid llvm.org
glitches like this one:

https://github.com/thesofproject/sof/pull/4089/checks?check_run_id=2554961695

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2021-05-13 12:00:45 +01:00
Marc Herbert 014a386dfb .github: add Zephyr build
Use the official image from the Zephyr project
https://github.com/zephyrproject-rtos/docker-image

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2021-04-30 11:12:29 +01:00