Skip to content

Commit

Permalink
Modified the project to use ThorMaker
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin York authored and Martin York committed May 23, 2012
1 parent b078da1 commit b4a498e
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 97 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
@@ -0,0 +1,3 @@
[submodule "build"]
path = build
url = git@github.com:Loki-Astari/ThorMaker.git
1 change: 1 addition & 0 deletions build
Submodule build added at 5aadc6
58 changes: 0 additions & 58 deletions third/portability.h

This file was deleted.

48 changes: 9 additions & 39 deletions third/setup
Expand Up @@ -2,10 +2,16 @@

ROOT=`pwd`

cd ../build
mkdir lib bin include include3rd
#
# Change this as required to point at the root of ThorsAnvil code
THORSANVIL_ROOT=`dirname ${ROOT}`


cd ${THORSANVIL_ROOT}
git submodule init
git submodule update
cd ${ROOT}
cp portabillity.h ../build/include


# Need this to unpack some of the packages.
# sudo apt-get install unzip
Expand All @@ -15,9 +21,6 @@ cp portabillity.h ../build/include
sudo apt-get install bison flex
sudo apt-get install libboost-dev libboost-doc

#
# Change this as required to point at the root of ThorsAnvil code
THORSANVIL_ROOT=`dirname ${ROOT}`

#
# If you want to use your own version of boost set USE_INSTALLED_BOOST
Expand All @@ -41,7 +44,6 @@ BOOST_LOG=0
#
# If you want to use the unit test automatically you need this
#
GOOGLE_UNIT_TEST=1



Expand Down Expand Up @@ -109,35 +111,3 @@ else

fi


cd ${ROOT}
if [[ ${GOOGLE_UNIT_TEST} == 1 ]]; then
echo "Un-archiving google test"

GTEST_ARCHIEVE=`ls gtest-*.zip 2>/dev/null | tail -n 1`
if [[ ${GTEST_ARCHIEVE} == "" ]]; then
echo "Failed to find gtest-*.zip"
echo "Download from: http://googletest.googlecode.com/files/gtest-1.6.0.zip"
exit 1
fi
GTEST_ARCHIEVE_DIR=${GTEST_ARCHIEVE%.zip}

if [[ ! -d ${GTEST_ARCHIEVE_DIR} ]]; then
unzip ${GTEST_ARCHIEVE}
fi

echo "Building google test"
cd ${GTEST_ARCHIEVE_DIR}
GTEST_DIR=${ROOT}/${GTEST_ARCHIEVE_DIR}
g++ -I${GTEST_DIR}/include -I${GTEST_DIR} -c ${GTEST_DIR}/src/gtest-all.cc
g++ -I${GTEST_DIR}/include -I${GTEST_DIR} -c ${GTEST_DIR}/src/gtest_main.cc
ar -rv libgtest.a gtest-all.o gtest_main.o

cd ${THORSANVIL_ROOT}/build/
cp ${GTEST_DIR}/libgtest.a lib/
rm -f include3rd/gtest
ln -s ${GTEST_DIR}/include/gtest include3rd/gtest

fi


0 comments on commit b4a498e

Please sign in to comment.