summaryrefslogtreecommitdiff
path: root/run
blob: 8957de6e303f8db7e37bb325b9d7680ceaa7f041 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/sh
if [ "$CC" = "" ]; then
	CC=tcc
fi
if [ "$2" = "" ]; then
	tocf=test.toc
else
	tocf="$2"
fi
if [ "$1" = "noq" ]; then
	FLAGS=
else
	FLAGS="-q"
fi

./toc $tocf || exit 1
if [ "$1" = "c" ]; then
	$CC out.c -g -Wno-builtin-declaration-mismatch && ./a.out
elif [ "$1" = "pc" ]; then
	cat out.c
fi