Commit 0c806ff
authored
add docker-helper.sh to lift examples using pac-nix docker image (#514)
this introduces the src/test/make/docker-helper.sh script which is
a (hopefully) developer-friendly method for lifting examples in a Docker
container provided by [pac-nix][].
to ensure reproducibility, this uses an x86_64-linux docker container
with cross-compiler provided by nix. for more details, see #288 which
the
docker-helper.sh is stolen from.
the usage is comprehensively documented in [readme].
the general flow is:
1. activate the docker-helper.sh environment: `eval $(docker-helper.sh
env)`.
(you will need to re-run this if you close your terminal)
2. pull the docker image: `docker-helper.sh pull`
3. start the docker container: `docker-helper.sh start`
4. (optional) clean the directory you want to lift:
`make SUBDIRS=extraspec_incorrect/malloc_memcpy_strlen_memset_free
clean`
5. compile and lift the directory:
`make SUBDIRS=extraspec_incorrect/malloc_memcpy_strlen_memset_free`
6. commit the results (eventually, we want to move the binaries into
an out-of-repo location. but until then, committing is probably fine.)
[pac-nix]: https://github.com/katrinafyi/pac-nix/
[readme]:
https://github.com/UQ-PAC/BASIL/blob/docker-helper/src/test/readme.md
this PR does not make any changes to the existing examples. it only
serves to make the Docker container available and accessible for people
who want to use it as a uniform lifting environment.
I do think that all examples should eventually be re-lifted using a
consistent method, but this will come later.1 parent 60d0d4c commit 0c806ff
15 files changed
Lines changed: 966 additions & 90 deletions
File tree
- .github/workflows
- docs/src
- development
- scripts
- src/test
- make
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| 35 | + | |
| 36 | + | |
35 | 37 | | |
36 | 38 | | |
37 | 39 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
34 | 35 | | |
35 | 36 | | |
36 | 37 | | |
| |||
0 commit comments