#!/bin/bash
# With no args, does a full recompile
# With -m, just remove dirty bins, qmake, make

if [ "$1" != "-m" ] ; then
	make clean
fi

rm -r lib/* traverso

if [ "$1" != "-m" ] ; then
	find ./ -name Makefile -type f -print0 | xargs -0 /bin/rm -f
fi

qmake -nocache
time make -j2
