Commit 3d8896e
Auto-bootstrap GAP9 venv + board config in runners
Add `testUtils/gap9Bootstrap.py` exporting `bootstrap_gap9_env()`,
which replaces the manual `source .gap9-venv/bin/activate`,
`source configs/gap9_evk_audio.sh`, and `export GVSOC_INSTALL_DIR`
dance documented in `README_GAP9.md`. The helper:
- runs `bash -c 'source gap9_evk_audio.sh && env -0'` to capture the
board config's exports and merges them into a fresh env;
- sets `VIRTUAL_ENV` and prepends the venv's `bin/` to `PATH` so
subprocesses (gapy, etc.) also pick up the venv;
- `os.execve`s under the venv's python (skipped if `sys.executable`
is already the venv interpreter);
- is idempotent via a `DEEPLOY_GAP9_BOOTSTRAPPED` recursion guard;
- is a no-op outside the GAP9 container, when the SDK paths don't
exist.
`GAP_SDK_HOME` overrides the default `/app/install/gap9-sdk`.
Wire `bootstrap_gap9_env()` into both `deeployRunner_gap9.py` and
`deeployRunner_tiled_gap9.py` before the rest of the imports run.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 3b011bb commit 3d8896e
3 files changed
Lines changed: 74 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
9 | 13 | | |
10 | 14 | | |
11 | 15 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
9 | 13 | | |
10 | 14 | | |
11 | 15 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
0 commit comments