blob: 96cfe044d904ebf41d817d56453d82f1b4386273 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
#!/bin/sh
# helper script for compiling a fwd program.
# assumes it is being run from the root dir of the fwd sources.
if [ "$#" -ne 2 ]; then
echo "usage: fwdc <input file> <output binary>"
echo "currently also produces <output binary>.c for inspection"
exit 1
fi
SRC="$1"
DST="$2"
./fwd "$SRC" > "$DST".c
cc -O3 -mno-sse \
-L mod -I include -I lib \
-Wl,-rpath=$PWD/mod \
"$DST".c -o "$DST" \
-lfwdio -lfwdmem -lfwdutil
|