73bef5292dd7c4222525bb3868c4b6791f5a11f7
[ghc-hetmet.git] / validate
1 #!/bin/sh -e
2
3 if [ -f mk/config.mk ]; then
4    make distclean
5 fi
6
7 if [ -f mk/build.mk ]; then
8    mv mk/build.mk mk/build.mk.bak
9 fi
10 echo BuildFlavour=quick >mk/build.mk
11 cat mk/build.mk.sample >>mk/build.mk
12
13 sh boot
14 ./configure
15 # ToDo: configure args
16
17 make -j2
18
19 make -C testsuite/tests/ghc-regress fast stage=2 2>&1 | tee testlog
20
21 if grep '0 unexpected failures' testlog >/dev/null 2>/dev/null; then
22    echo "-------------------------------------------------------------------"
23    echo "Congratulations!  This tree is has passed minimal testing."
24    echo
25    echo "NOTE: If you have made changes that may cause failures not tested"
26    echo "for by the minimal testing procedure, please do further testing"
27    echo "as necessary."
28    echo
29    echo "When you are satisfied that you haven't broken anything, go ahead"
30    echo "and push/send your patches".
31    echo "-------------------------------------------------------------------"
32 else
33    echo "-------------------------------------------------------------------"
34    echo "Oops!  Looks like you have some test failures."
35    echo "Please fix them before pushing/sending patches."
36    echo "-------------------------------------------------------------------"
37 fi