# script to compile the serial number program for Linux and, ahem, windoze
# version 1.00 08/19/2010, John DeArmond jgd@fluxeon.com

gcc ser_no.c -ggdb -o ser_no

if [ $? != 0 ]; then
    exit 1
fi

if [ $? == 0 ]; then
	sudo mv ./ser_no /usr/local/bin
fi

echo Linux compile finished

# The windows compile is commented out because the mingw32msvc cross-compiler does not support ftruncate();
# perhaps compiling under cigwyn gcc would fix this problem.  need to check 
#wingcc ser_no.c -o ser_no.exe
