Skip to content

Commit 7f3b8c6

Browse files
[simple_system] Argument parsing fix
All these commands were working in Bash but not in Fish. This commit removes the = between the field and the value and replaces this with the more portable space. It also changes the commands in the readme to use the pipe input instead of setting the argument variable. This is because otherwise shells like fish interpret the output of the ibex_config.py scripts as one long string instead of multiple arguments.
1 parent 05ef0e6 commit 7f3b8c6

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

examples/simple_system/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ with different configurations of Ibex, specified by parameters. To build the
3232
"small" configuration, run the following command from the Ibex repository root.
3333

3434

35-
```
36-
fusesoc --cores-root=. run --target=sim --setup --build \
37-
lowrisc:ibex:ibex_simple_system $(util/ibex_config.py small fusesoc_opts)
35+
```sh
36+
util/ibex_config.py small fusesoc_opts | fusesoc --cores-root=. run --target=sim --setup \
37+
--build lowrisc:ibex:ibex_simple_system
3838
```
3939

4040
To see performance counters other than the total number of instructions

examples/sw/benchmarks/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ All of these benchmarks run on Simple System. A verilator simulation suitable
1111
for running them can be built with:
1212

1313
```
14-
fusesoc --cores-root=. run --target=sim --setup --build lowrisc:ibex:ibex_simple_system `./util/ibex_config.py maxperf fusesoc_opts`
14+
util/ibex_config.py maxperf fusesoc_opts | fusesoc --cores-root=. run --target=sim --setup --build lowrisc:ibex:ibex_simple_system
1515
```
1616

1717
This will build a simulation of Ibex in the 'maxperf' configuration.

util/ibex_config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ def output(self, config, args):
129129
fusesoc_cmd = []
130130
for fld, typ in Config.known_fields:
131131
val = config.params[fld]
132-
fusesoc_cmd.append(shlex.quote(f'--{fld}={val}'))
132+
fusesoc_cmd.append(f'--{fld} {val}')
133133

134134
return ' '.join(fusesoc_cmd)
135135

0 commit comments

Comments
 (0)