From e0013967445a5bd47657b6c6f8de2dd8dfc95f2d Mon Sep 17 00:00:00 2001 From: Marc Di Luzio Date: Tue, 16 Dec 2014 13:13:03 +0000 Subject: [PATCH] Add bootstrap script to generate build files, binaries, run tests and generate maps --- bootstrap.sh | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100755 bootstrap.sh diff --git a/bootstrap.sh b/bootstrap.sh new file mode 100755 index 0000000..d882c3a --- /dev/null +++ b/bootstrap.sh @@ -0,0 +1,36 @@ +#! /bin/bash + +echo "TTRTS: Running cmake" +cd build/ +cmake ../source +if [[ $? != 0 ]]; then + echo "TTRTS: CMake failed, exiting Bootstrap" +fi + +echo "TTRTS: Running make" +make +if [[ $? != 0 ]]; then + echo "TTRTS: make failed, exiting Bootstrap" +fi + +echo "TTRTS: Running tests" +./test/ttrts-test +if [[ $? != 0 ]]; then + echo "TTRTS: Tests failed, build must be broken" +fi + +echo "TTRTS: Generating maps" +cd ../games +./../build/gen/ttrts-gen +if [[ $? != 0 ]]; then + echo "TTRTS: Generating maps, exiting Bootstrap" +fi + +echo "TTRTS: Moving binaries" +cd .. +if [ ! -e build/ttrts/ttrts ]; then + echo "TTRTS: No TTRTS Binary found, something has gone wrong" +fi + +cp build/ttrts/ttrts . +chmod a+x ttrts \ No newline at end of file