Skip to content

Commit f5f78b7

Browse files
authored
update dependencies to support python3.12
* update build script * update dependencies list in readme * update dependencies
1 parent 989b893 commit f5f78b7

File tree

4 files changed

+37
-11
lines changed

4 files changed

+37
-11
lines changed

.github/workflows/build.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,23 @@ jobs:
3434

3535
- name: Run ARCHIE
3636
run: cd examples/stm32; ./run.sh; cd ../riscv64; ./run.sh
37+
38+
build_with_script:
39+
name: Test build.sh Script
40+
runs-on: ubuntu-latest
41+
42+
steps:
43+
- name: Clone Repository
44+
uses: actions/checkout@v4
45+
46+
- name: test bash build script
47+
run: |
48+
(cat <<END
49+
1
50+
y
51+
1
52+
2
53+
y
54+
1
55+
END
56+
) | bash build.sh

README.md

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,18 +28,25 @@ Alternatively, the build instructions are provided in the following sections.
2828
ARCHIE was tested with QEMU 6.0, which is available in [archie-qemu](https://github.com/Fraunhofer-AISEC/archie-qemu).
2929
First make sure the basic requirements for QEMU are installed. See the wiki for required libraries (https://wiki.qemu.org/Hosts/Linux).
3030
On Ubuntu systems, you can install the minimum required packages with:
31-
```
31+
32+
```sh
3233
sudo apt install git build-essential ninja-build libglib2.0-dev libfdt-dev libpixman-1-dev zlib1g-dev
3334
```
3435

35-
Checkout git submodule qemu, which should checkout tcg_plugin_dev of the git. See code segment below.
36+
Additionally, the faultplugin requires the following package:
3637

38+
```sh
39+
sudo apt install libprotobuf-c-dev
3740
```
41+
42+
Checkout git submodule qemu, which should checkout tcg_plugin_dev of the git. See code segment below.
43+
44+
```sh
3845
git submodule update --init
3946
mkdir -p qemu/build/debug
4047
cd qemu/build/debug
4148
./../../configure --target-list=arm-softmmu --enable-debug --enable-plugins --disable-sdl --disable-gtk --disable-curses --disable-vnc
42-
make -j {CPUCORENUMBER}
49+
make -j $(nproc)
4350
cd ../../../faultplugin/
4451
make
4552
```
@@ -79,15 +86,15 @@ The program output will be stored in an HDF5 file. For a description of how to i
7986
### Running the program
8087

8188
To run the python3 program, type:
82-
```
89+
```sh
8390
python3 controller.py --debug --fault fault.json --qemu qemuconf.json output.hdf5
8491
```
8592
Replace *fault.json* and *qemuconf.json* with the corresponding files.
8693

8794
The *--debug flag* creates a log file for each experiment. The name of the log file has the following format: ``log_experiment-id.txt``, e.g., ``log_4.txt`` for the experiment with ID 4.
8895

8996
To obtain further information on the input parameters, type:
90-
```
97+
```sh
9198
python3 controller.py --help
9299
```
93100

@@ -96,12 +103,11 @@ python3 controller.py --help
96103
It is possible to connect to a running QEMU instance with GDB. To use this feature in the framework and observe introduced faults the *--gdb* flag can be set.
97104
ARCHIE will start the internal QEMU process with GDB enabled and halts at the startup of the simulated system. To connect to QEMU from GDB use port 1234.
98105
It also will force the framework to only spawn one worker and it will step through all faults configured in *fault.json*. If one specific fault is required, the JSON file needs to be edited to only contain this specific fault.
99-
```
106+
```sh
100107
python3 controller.py --gdb --fault fault.json --qemu qemuconf.json output.hdf5
101108
```
102109
To connect from GDB to the QEMU session use
103110
```
104111
targ rem:localhost:1234
105112
```
106113
QEMU will wait unil the GDB session is attached. The debugging mode is only suitable for the analysis of a low number of faults. Stepping through a large amount of faults is cumbersome. This should be considered when adjusting the JSON files.
107-

build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ install_python3_distro() {
3737
if [ "${ID:-linux}" = "debian" ] || [ "${ID_LIKE#*debian*}" != "${ID_LIKE}" ]
3838
then
3939
echo "Looks like Debian!"
40-
sudo apt-get install python3-tables python3-pandas python3-prctl python3-protobuf python3-tqdm
40+
sudo apt-get install python3-tables python3-pandas python3-prctl python3-protobuf python3-tqdm python3-psutil python3-json5 python3-setuptools
4141

4242
echo "Rebuild protobuf files to support the installed package versions"
4343
cd protobuf

requirements.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
pandas~=1.5
1+
pandas==2.1.4
22
python-prctl==1.8.1
3-
tables==3.7.0
3+
tables==3.9.2
44
json5==0.9.10
55
protobuf==4.21.12
66
tqdm==4.65.0
7-
psutil==5.9.6
7+
psutil==5.9.8

0 commit comments

Comments
 (0)