Permalink
Browse files

c++ 11 standard

update cmake script for centos6
  • Loading branch information...
tcaduser committed Jul 15, 2017
1 parent 804c6c9 commit 037ee35da1058f0f158461b4f1a51d5ed9353813
Showing with 66 additions and 9 deletions.
  1. +2 −0 CMakeLists.txt
  2. +1 −0 appveyor.cmake
  3. +1 −1 scripts/setup_appveyor.sh
  4. +4 −4 scripts/setup_centos_6.sh
  5. +53 −0 scripts/setup_osx_gcc.sh
  6. +4 −4 scripts/setup_windows.sh
  7. +1 −0 win32.cmake
View
@@ -2,6 +2,8 @@ PROJECT (SYMDIFF)
OPTION(TCLMAIN "Build with TCL Interpreter" ON)
set (CMAKE_CXX_STANDARD 11)
SET (SUBDIRS
src
testing
View
@@ -18,6 +18,7 @@ SET (PYTHON_ARCHIVE C:/Miniconda-x64/libs/python27.lib)
SET (PYTHON_INCLUDE C:/Miniconda-x64/include)
ENDIF (${CMAKE_SIZEOF_VOID_P} MATCHES 4)
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /fp:strict /EHsc")
SET (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /SAFESEH:NO")
SET (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /SAFESEH:NO")
SET (CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} /SAFESEH:NO")
@@ -2,7 +2,7 @@
# http://creativecommons.org/publicdomain/zero/1.0/
# Note: run this file using bash
CMAKE=/cygdrive/C/Program\ Files\ \(x86\)/CMake/bin/cmake.exe
CMAKE=/cygdrive/C/Program\ Files/CMake/bin/cmake.exe
SYMDIFF_CONFIG="appveyor"
#/usr/bin/mkdir -p win32
@@ -1,9 +1,9 @@
# Any copyright is dedicated to the Public Domain.
# http://creativecommons.org/publicdomain/zero/1.0/
CMAKE="/usr/bin/cmake"
CMAKE_CXX_FLAGS="-std=c++0x"
CXX="/usr/bin/g++"
CC="/usr/bin/gcc"
CMAKE="/usr/bin/cmake3"
CMAKE_CXX_FLAGS=""
CXX="/opt/rh/devtoolset-6/root/usr/bin/g++"
CC="/opt/rh/devtoolset-6/root/usr/bin/gcc"
TCL_ARCHIVE="$HOME/anaconda/lib/libtclstub8.5.a"
TCL_INCLUDE="$HOME/anaconda/include"
TCL_BIN="$HOME/anaconda/bin/tclsh8.5"
View
@@ -0,0 +1,53 @@
# Any copyright is dedicated to the Public Domain.
# http://creativecommons.org/publicdomain/zero/1.0/
CMAKE="cmake"
CMAKE_CXX_FLAGS=""
CXX="/usr/local//bin/g++-7"
CC="/usr/local/bin/gcc-7"
TCL_ARCHIVE="/usr/lib/libtclstub8.5.a"
TCL_INCLUDE="/usr/include"
TCL_BIN="/usr/bin/tclsh"
PYTHON_ARCHIVE="/usr/lib/libpython2.7.dylib"
PYTHON_INCLUDE="/usr/include/python2.7"
PYTHON_BIN="/usr/bin/python"
#-DCMAKE_OSX_ARCHITECTURES="i386;x86_64" \
for TYPE in debug release; do
NAME=osx_${TYPE}
mkdir ${NAME}
(cd $NAME; ${CMAKE} \
-DCMAKE_CXX_FLAGS:STRING="${CMAKE_CXX_FLAGS}" \
-DCMAKE_BUILD_TYPE=${TYPE} \
-DCMAKE_CXX_COMPILER=${CXX} \
-DCMAKE_C_COMPILER=${CC} \
-DPYTHON_INCLUDE=${PYTHON_INCLUDE} \
-DPYTHON_ARCHIVE=${PYTHON_ARCHIVE} \
-DPYTHON_BIN=${PYTHON_BIN} \
-DTCL_INCLUDE=${TCL_INCLUDE} \
-DTCL_ARCHIVE=${TCL_ARCHIVE} \
-DTCL_BIN=${TCL_BIN} \
..)
done
mkdir -p bin
cat << EOF > bin/symdiff
#!/bin/bash
set -e
progname="\$0"
curdir=\`dirname "\$progname"\`
export DYLD_LIBRARY_PATH=\${curdir}/../lib
export PYTHONPATH=\${curdir}/../lib
${PYTHON_BIN} \$*
EOF
chmod +x bin/symdiff
cat << EOF > bin/symdiff_tcl
#!/bin/bash
set -e
progname="\$0"
curdir=\`dirname "\$progname"\`
export DYLD_LIBRARY_PATH=\${curdir}/../lib
export TCLLIBPATH=\${curdir}/../lib
${TCL_BIN} \$*
EOF
chmod +x bin/symdiff_tcl
View
@@ -2,14 +2,14 @@
# http://creativecommons.org/publicdomain/zero/1.0/
# Note: run this file using bash
CMAKE=/cygdrive/C/Program\ Files\ \(x86\)/CMake/bin/cmake.exe
CMAKE=/cygdrive/C/Program\ Files/CMake/bin/cmake.exe
SYMDIFF_CONFIG="win32"
/usr/bin/mkdir -p win32
(cd win32; "$CMAKE" -G "Visual Studio 14" -DSYMDIFF_CONFIG=${SYMDIFF_CONFIG} ..)
#/usr/bin/mkdir -p win32
#(cd win32; "$CMAKE" -G "Visual Studio 14" -DSYMDIFF_CONFIG=${SYMDIFF_CONFIG} ..)
/usr/bin/mkdir -p win64
(cd win64; "$CMAKE" -G "Visual Studio 14 Win64" -DSYMDIFF_CONFIG=${SYMDIFF_CONFIG} ..)
(cd win64; "$CMAKE" -G "Visual Studio 15 Win64" -DSYMDIFF_CONFIG=${SYMDIFF_CONFIG} ..)
libpath=`/usr/bin/cygpath -w $PWD/lib`
#echo $libpath
View
@@ -18,6 +18,7 @@ SET (PYTHON_ARCHIVE C:/Anaconda/libs/python27.lib)
SET (PYTHON_INCLUDE C:/Anaconda/include)
ENDIF (${CMAKE_SIZEOF_VOID_P} MATCHES 4)
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /fp:strict /EHsc")
SET (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /SAFESEH:NO")
SET (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /SAFESEH:NO")
SET (CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} /SAFESEH:NO")

0 comments on commit 037ee35

Please sign in to comment.