Replace build scripts with Makefile that handles containerized hastec.
Chris Pressey
1 year, 10 months ago
0 | #!/bin/sh | |
1 | ||
2 | PROG=emmental | |
3 | ||
4 | if command -v ghc >/dev/null 2>&1; then | |
5 | echo "building $PROG.exe with ghc" | |
6 | (cd src && ghc --make Main.hs -o ../bin/$PROG.exe) | |
7 | else | |
8 | echo "ghc not found, not building $PROG.exe" | |
9 | fi | |
10 | ||
11 | # For this to work, you need hastec installed. | |
12 | ||
13 | if command -v hastec >/dev/null 2>&1; then | |
14 | echo "building $PROG.js with hastec" | |
15 | (cd src && hastec --make HasteMain.hs -o ../demo/$PROG.js) | |
16 | else | |
17 | echo "hastec not found, not building $PROG.js" | |
18 | fi |