summaryrefslogtreecommitdiff
path: root/minie/build.sh
blob: ee3737ce1a9dc499b90925e566c212261e323218 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/bash

set -e

gcc -m32 --stack-usage -g -O0 -Wall -pedantic -std=c89 -Wno-return-type -o e2c e2c.c
#tcc -m32 -g -O0 -o e2c e2c.c
#pcc -melf_i386 -g -Wall -O0 -g -D__float128="long double" -o e2c e2c.c
#clang -m32 -g -O0 -Wall -pedantic -std=c89 -Wno-return-type -o e2c e2c.c

./e2c < test1.e
set +e
./e2c < test2.e
./e2c < test3.e
set -e
./e2c < test4.e
./e2c < test5.e
./e2c < test6.e
./e2c < test7.e
./e2c < test8.e
./e2c < test9.e

./e2c < test5.e > test5.c && gcc -g -o test5 test5.c && ./test5
./e2c < test6.e > test6.c && gcc -g -o test6 test6.c && ( echo 'Hello' | ./test6 )
./e2c < test7.e > test7.c && gcc -g -o test7 test7.c && ( echo 'Hello' | ./test7 )
./e2c < test8.e > test8.c && gcc -g -o test8 test8.c && ./test8
./e2c < test9.e > test9.c && gcc -g -o test9 test9.c && ./test9 < test9.e

./e2c < ec.e
./e2c < ec.e > ec.c && gcc -g -O0 -o ec ec.c
./ec < test1.e > test1.asm
nasm -o test1.bin -f bin test1.asm
ndisasm -b32 test1.bin
../crenshaw/emul test1.bin

./ec < ec.e