#!/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