--- /dev/null
+#!/bin/sh
+STATUS=0
+
+qmake -project SUBDIRS+=`find . -type d -name ut_\*` -t subdirs -nopwd
+qmake
+if [ $SINGLE_PROCESS == "yes" ]; then
+ make -B
+else
+ make -B -j3
+fi
+if [ $? -ne 0 ]; then
+ exit 1
+fi
+
+files=`find . -maxdepth 2 -name 'ut_*' -type f -perm -u+x -print`
+
+echo '<?xml version="1.0"?>' > result.xml
+echo '<unittestresults>' >> result.xml
+for file in $files; do
+ echo "Running test $file"
+ $file -lightxml -o tmp_result.xml;
+
+ if [ $? -ne 0 ]; then
+ STATUS=2
+ fi
+
+ cat tmp_result.xml >>result.xml
+done
+echo '</unittestresults>' >> result.xml
+rm -f tmp_result.xml
+sh run_valgrind.sh
+
+echo "Done"
+exit $STATUS
+