projects
/
calu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
s3e: fix build break
[calu.git]
/
3_test
/
exectest.sh
diff --git
a/3_test/exectest.sh
b/3_test/exectest.sh
index 5d1a60b374b9fbf49d9d46706eac0ae77f7a8bdd..77ac27da596fbd76abddbc20ebad9b07eaa1ad0c 100755
(executable)
--- a/
3_test/exectest.sh
+++ b/
3_test/exectest.sh
@@
-1,4
+1,4
@@
-#!/bin/bash
-x
+#!/bin/bash
ARG2=$2
ARG2=$2
@@
-10,8
+10,8
@@
cleantools() {
}
buildtools() {
}
buildtools() {
- make -C ../3a_asm all
- make -C ../3b_sim all
+ make -C ../3a_asm
-j3
all
+ make -C ../3b_sim
-j3
all
}
runasm() {
}
runasm() {
@@
-22,6
+22,14
@@
runasm() {
../3a_asm/dtas < $ARG2 > ${ARG2%.s}.dthex
}
../3a_asm/dtas < $ARG2 > ${ARG2%.s}.dthex
}
+runasmbin() {
+ if [ "$ARG2" == "" ]; then
+ echo "runasm: please provide a assembler file"
+ exit 1
+ fi
+ ../3a_asm/dtas -b < $ARG2 > ${ARG2%.s}_bin.dthex
+}
+
runsim() {
if [ "$ARG2" == "" ]; then
echo "runsim: please provide a dthex file"
runsim() {
if [ "$ARG2" == "" ]; then
echo "runsim: please provide a dthex file"
@@
-43,8
+51,11
@@
case $1 in
clean) cleantools;;
build) buildtools;;
asm) runasm;;
clean) cleantools;;
build) buildtools;;
asm) runasm;;
+ asmbin) runasmbin;;
sim) runsim;;
asmsim) runasmsim;;
sim) runsim;;
asmsim) runasmsim;;
- *) echo "first argument must be clean|build|asm <file>|sim <file>"
+ *) echo "first argument must be clean|build|"
+ echo "asm <file.s>|asmbin <file.s>|"
+ echo "sim <file.dthex>|asmsim <file.s>"
esac
esac