travis: don't double up on the C/CXXFLAGS
Just use the CFLAGS and CXXFLAGS environment variable instead of also
passing -DCMAKE_{C,CXX}_FLAGS.
@@ -214,8 +214,8 @@ before_install:
export CXX="${CXX_COMPILER}"
fi
if [ -n "${COMPILER_FLAGS}" ]; then
- export CFLAGS="${ARCH_FLAGS} ${COMPILER_FLAGS} ${CFLAGS}"
- export CXXFLAGS="${ARCH_FLAGS} ${COMPILER_FLAGS} ${CXXFLAGS}"
+ export CFLAGS="${ARCH_FLAGS} ${OPTIMIZATION_FLAGS} ${COMPILER_FLAGS} ${CFLAGS}"
+ export CXXFLAGS="${ARCH_FLAGS} ${OPTIMIZATION_FLAGS} ${COMPILER_FLAGS} ${CXXFLAGS}"
fi
script:
@@ -224,9 +224,6 @@ script:
${CONFIGURE_WRAPPER} cmake .. \
-G "${CMAKE_GENERATOR}" \
-DCMAKE_BUILD_TYPE="${BUILD_TYPE}" \
- -DCMAKE_C_FLAGS="${ARCH_FLAGS} ${COMPILER_FLAGS} ${CFLAGS}" \
- -DCMAKE_CXX_FLAGS="${ARCH_FLAGS} ${COMPILER_FLAGS} ${CXXFLAGS}" \
- -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
-DBUILD_CPP_TESTS=${BUILD_CPP_TESTS} \
${CMAKE_ARGS}
- ${BUILD_WRAPPER} cmake --build .
