Skip to content

Commit 4ec41ae

Browse files
committed
Add script that automatically generates a release
A release contains the prebuilt ELF files, bitstreams, etc.
1 parent eca7b4c commit 4ec41ae

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

pack.sh

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
#!/bin/bash -e
2+
3+
# This script generates a binary distribution to allow new users a
4+
# real quick start.
5+
6+
FILES="
7+
Makefile
8+
README.md
9+
bootstrap-quick-start.sh
10+
environment.sh
11+
or1k-dev.tcl
12+
sw/hello/hello.c
13+
sw/timer/timer.c
14+
or1ksim/Makefile
15+
or1ksim/README.md
16+
or1ksim/or1ksim.cfg
17+
or1ksim/hello.elf
18+
or1ksim/timer.elf
19+
de0_nano/Makefile
20+
de0_nano/README.md
21+
de0_nano/de0_nano.sof
22+
de0_nano/hello.elf
23+
de0_nano/timer.elf
24+
docs/Debugging.md
25+
"
26+
27+
# Update the de0_nano bitstream if a newer one is available
28+
if [ -e de0_nano/build/de0_nano/bld-quartus/de0_nano.sof ]; then
29+
cp -u de0_nano/build/de0_nano/bld-quartus/de0_nano.sof de0_nano/de0_nano.sof
30+
fi
31+
32+
# Fail if no bitstream is found
33+
if [ ! -e de0_nano/de0_nano.sof ]; then
34+
echo "You need to build de0_nano before packing";
35+
exit 1;
36+
fi
37+
38+
tar -czf openrisc-tutorials.tgz --transform 's,^,openrisc-tutorials/,' $FILES

0 commit comments

Comments
 (0)