diff options
author | John MacFarlane <jgm@berkeley.edu> | 2014-10-25 19:00:26 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2014-10-25 19:07:57 -0700 |
commit | 75e924d81e0001c5e298cd89c99ff87d7cf6c8fb (patch) | |
tree | 2a01daf84658c6e2c4e04d25926b155e5d028f72 /release_it.sh | |
parent | 16794168a936feb7f25b3fdbdddf6c24b14a779a (diff) | |
parent | 7da937e2aea109e42b5ce9d6c9fe2e4e9ec877fc (diff) |
Merge branch 'cmake-build' of https://github.com/gittiver/stmd into gittiver-cmake-build
Conflicts:
.gitignore
Diffstat (limited to 'release_it.sh')
-rwxr-xr-x | release_it.sh | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/release_it.sh b/release_it.sh new file mode 100755 index 0000000..b83772a --- /dev/null +++ b/release_it.sh @@ -0,0 +1,42 @@ +#!/bin/sh + +HOST_SYSTEM=`uname -s` +HOST_ARCH=`uname -m` +STARTDIR=`pwd` + +CMAKE_BUILDDIR=build/$HOST_ARCH-$HOST_SYSTEM + +mkdir -p $CMAKE_BUILDDIR + +cd $CMAKE_BUILDDIR + +if test $HOST_SYSTEM = "Darwin" ; then + cmake -DChronolog_WITH_DOCS:bool=ON \ + -DChronolog_WITH_TESTS:bool=ON \ + -DCMAKE_OSX_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk \ + $STARTDIR; + cd $STARTDIR + + mkdir -p build/Xcode + cd build/Xcode + cmake -DChronolog_WITH_DOCS:bool=ON \ + -DChronolog_WITH_TESTS:bool=ON \ + -DCXXTEST_INCLUDE_DIR=3rdparty/cxxtest \ + -DCMAKE_OSX_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk \ + -G Xcode $STARTDIR; + cd $STARTDIR + +elif test $HOST_SYSTEM = "Linux" ; then + cmake -DChronolog_WITH_DOCS:bool=ON \ + -DChronolog_WITH_TESTS:bool=ON \ + $STARTDIR; +else + echo "not supported"; +fi + +cd $CMAKE_BUILDDIR +cpack --config CPackSourceConfig.cmake +cmake --build . --target all --target test --target package +cmake --build . --target package_source +cd $STARTDIR + |