git @ Cat's Eye Technologies Flobnar / 0a4b360
Forgot to add build.sh. Also add .{hg,git}ignore. Cat's Eye Technologies 8 years ago
3 changed file(s) with 31 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
0 *.o
1 *.hi
2 flobnar
0 syntax: glob
1
2 *.o
3 *.hi
4 flobnar
0 #!/bin/sh
1
2 PROG=flobnar
3
4 if [ x`which ghc` = x -a x`which runhugs` = x ]; then
5 echo "Neither ghc nor runhugs found on search path."
6 exit 1
7 fi
8
9 mkdir -p bin
10
11 if [ x`which ghc` = x -o ! x$USE_HUGS = x ]; then
12 # create script to run with Hugs
13 cat >bin/$PROG <<'EOF'
14 #!/bin/sh
15 THIS=`realpath $0`
16 DIR=`dirname $THIS`/../src
17 runhugs $DIR/Main.hs $*
18 EOF
19 chmod 755 bin/$PROG
20 else
21 cd src && ghc --make Main.hs -o ../bin/$PROG
22 fi