From 27a1b787c88355211dd85402ab466268f71adcbd Mon Sep 17 00:00:00 2001 From: Mario Werner Date: Sun, 7 Feb 2016 18:32:23 +0100 Subject: [PATCH] test in c++ 98, 03 and 11 mode --- .travis.yml | 2 +- support/travis-build.py | 21 ++++++++++++--------- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/.travis.yml b/.travis.yml index be1f48d5..0af0f167 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,9 +13,9 @@ env: 6pxmyzLHSn1ZR7OX5rfPvwM3tOyZ3H0= matrix: - BUILD=Doc - - BUILD=Debug STANDARD=98 - BUILD=Debug STANDARD=11 - BUILD=Release STANDARD=98 + - BUILD=Release STANDARD=03 - BUILD=Release STANDARD=11 matrix: diff --git a/support/travis-build.py b/support/travis-build.py index 19ff41c9..1997f99d 100755 --- a/support/travis-build.py +++ b/support/travis-build.py @@ -93,6 +93,14 @@ if cppStandard == '98': '-DFMT_DOC=OFF', '-DFMT_PEDANTIC=ON', srcDir]) +if cppStandard == '03': + check_call(['cmake', '-DCMAKE_INSTALL_PREFIX='+installDir, + '-DCMAKE_BUILD_TYPE=' + build, + '-DCMAKE_CXX_FLAGS=-std=c++03', + '-DFMT_USE_CPP11=OFF', + '-DFMT_DOC=OFF', + '-DFMT_PEDANTIC=ON', + srcDir]) else: # default configuration check_call(['cmake', '-DCMAKE_INSTALL_PREFIX='+installDir, @@ -118,13 +126,8 @@ check_call(['make', 'install']) # test installation makedirs_if_not_exist(buildDir_test) os.chdir(buildDir_test) -if cppStandard == '98': - check_call(['cmake', '-DCMAKE_INSTALL_PREFIX='+installDir, - '-DCMAKE_BUILD_TYPE=' + build, - '-DCMAKE_CXX_FLAGS=-std=c++98', - srcDir_test]) -else: - check_call(['cmake', '-DCMAKE_INSTALL_PREFIX='+installDir, - '-DCMAKE_BUILD_TYPE=' + build, - srcDir_test]) +check_call(['cmake', '-DCMAKE_INSTALL_PREFIX='+installDir, + '-DCMAKE_BUILD_TYPE=' + build, + '-DCMAKE_CXX_FLAGS=-std=c++' + cppStandard, + srcDir_test]) check_call(['make', '-j4']) \ No newline at end of file