Travis: Split CMake and Make
This commit is contained in:
parent
6008550295
commit
fc874f063e
1 changed files with 23 additions and 15 deletions
32
.travis.yml
32
.travis.yml
|
@ -48,8 +48,10 @@ addons:
|
|||
update: true
|
||||
|
||||
env:
|
||||
- MAKE_BUILD_TYPE=RELEASE=0 CMAKE_BUILD_TYPE=Debug
|
||||
- MAKE_BUILD_TYPE=RELEASE=1 CMAKE_BUILD_TYPE=RelWithDebInfo
|
||||
- BUILD_SYSTEM=make BUILD_TYPE=RELEASE=0
|
||||
- BUILD_SYSTEM=cmake BUILD_TYPE=Debug
|
||||
- BUILD_SYSTEM=make BUILD_TYPE=RELEASE=1
|
||||
- BUILD_SYSTEM=cmake BUILD_TYPE=RelWithDebInfo
|
||||
|
||||
before_install:
|
||||
# Set URL for Discord send script
|
||||
|
@ -63,8 +65,8 @@ before_install:
|
|||
- echo $TRAVIS_OS_NAME
|
||||
|
||||
# Display build type
|
||||
- echo $MAKE_BUILD_TYPE
|
||||
- echo $CMAKE_BUILD_TYPE
|
||||
- echo $BUILD_SYSTEM
|
||||
- echo $BUILD_TYPE
|
||||
|
||||
# The following Homebrew packages aren't linked by default, and need to be prepended to the path explicitly.
|
||||
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
||||
|
@ -107,19 +109,25 @@ install:
|
|||
fi
|
||||
|
||||
before_script:
|
||||
- |
|
||||
if [ "BUILD_SYSTEM" == "cmake" ]; then
|
||||
# Make build directory and generate CMake build files
|
||||
- mkdir -p ${CMAKE_BUILD_DIR} && cd ${CMAKE_BUILD_DIR}
|
||||
- cmake .. -DCMAKE_BUILD_TYPE=$CMAKE_BUILD_TYPE -DFIX_BUGS=ON -DWARNINGS=ON -DWARNINGS_ALL=ON
|
||||
- cd ..
|
||||
mkdir -p ${CMAKE_BUILD_DIR} && cd ${CMAKE_BUILD_DIR}
|
||||
cmake .. -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DFIX_BUGS=ON -DWARNINGS=ON -DWARNINGS_ALL=ON
|
||||
cd ..
|
||||
fi
|
||||
|
||||
script:
|
||||
- |
|
||||
if [ "BUILD_SYSTEM" == "cmake" ]; then
|
||||
# CMake build
|
||||
- cd ${CMAKE_BUILD_DIR}
|
||||
- cmake --build . --config $CMAKE_BUILD_TYPE --parallel $JOBS
|
||||
- cd ..
|
||||
|
||||
cd ${CMAKE_BUILD_DIR}
|
||||
cmake --build . --config $BUILD_TYPE --parallel $JOBS
|
||||
cd ..
|
||||
else
|
||||
# Make build
|
||||
- make -j $JOBS FIX_BUGS=1 $MAKE_BUILD_TYPE WARNINGS=1 WARNINGS_ALL=1
|
||||
make -j $JOBS FIX_BUGS=1 $BUILD_TYPE WARNINGS=1 WARNINGS_ALL=1
|
||||
fi
|
||||
|
||||
after_success:
|
||||
# Send success notification to Discord through DISCORD_WEBHOOK_URL
|
||||
|
|
Loading…
Add table
Reference in a new issue