#!/bin/sh

if [ "$1" = "pedantic" ]
then 
	export CXXFLAGS="-g -O2 -ansi -pedantic -Wall -W -Wold-style-cast -Wfloat-equal -Wwrite-strings -Woverloaded-virtual -Wno-long-long"
	shift
fi

rm -f config.cache
set -x

aclocal -I config && \
	libtoolize --force --copy && \
	autoheader && \
	automake --add-missing --copy --foreign && \
	autoconf &&
	./reconf $* &&
	( cd lib ; make custom.h )
