File tree 3 files changed +42
-2
lines changed
3 files changed +42
-2
lines changed Original file line number Diff line number Diff line change 2
2
# http://about.travis-ci.org/docs/user/build-configuration/
3
3
# This file can be validated on:
4
4
# http://lint.travis-ci.org/
5
- before_install : sudo apt-get install cmake
5
+
6
+ # before_install: sudo apt-get install -y cmake
7
+ # cmake is pre-installed in Travis for both linux and osx
8
+
9
+ before_install :
10
+ - sudo apt-get update -qq
11
+ - sudo apt-get install -qq valgrind
12
+ os :
13
+ - linux
6
14
language : cpp
7
15
compiler :
8
16
- gcc
9
17
- clang
10
- script : cmake -DJSONCPP_WITH_CMAKE_PACKAGE=$CMAKE_PKG -DBUILD_SHARED_LIBS=$SHARED_LIB -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCMAKE_VERBOSE_MAKEFILE=$VERBOSE_MAKE . && make && make jsoncpp_check
18
+ script : ./travis.sh
11
19
env :
12
20
matrix :
13
21
- SHARED_LIB=ON STATIC_LIB=ON CMAKE_PKG=ON BUILD_TYPE=release VERBOSE_MAKE=false
Original file line number Diff line number Diff line change @@ -26,6 +26,9 @@ test-amalgamate:
26
26
python3.4 amalgamate.py
27
27
cd dist; gcc -I. -c jsoncpp.cpp
28
28
29
+ valgrind :
30
+ valgrind --error-exitcode=42 --leak-check=full ./build/debug/src/test_lib_json/jsoncpp_test
31
+
29
32
clean :
30
33
\r m -rf * .gz * .asc dist/
31
34
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env sh
2
+ # This is called by `.travis.yml` via Travis CI.
3
+ # Travis supplies $TRAVIS_OS_NAME.
4
+ # http://docs.travis-ci.com/user/multi-os/
5
+ # Our .travis.yml also defines:
6
+ # - SHARED_LIB=ON/OFF
7
+ # - STATIC_LIB=ON/OFF
8
+ # - CMAKE_PKG=ON/OFF
9
+ # - BUILD_TYPE=release/debug
10
+ # - VERBOSE_MAKE=false/true
11
+ # - VERBOSE (set or not)
12
+
13
+ # -e: fail on error
14
+ # -v: show commands
15
+ # -x: show expanded commands
16
+ set -vex
17
+
18
+ env | sort
19
+
20
+ cmake -DJSONCPP_WITH_CMAKE_PACKAGE=$CMAKE_PKG -DBUILD_SHARED_LIBS=$SHARED_LIB -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCMAKE_VERBOSE_MAKEFILE=$VERBOSE_MAKE .
21
+ make
22
+
23
+ # Python is not available in Travis for osx.
24
+ # https://github.com/travis-ci/travis-ci/issues/2320
25
+ if [ " $TRAVIS_OS_NAME " != " osx" ]
26
+ then
27
+ make jsoncpp_check
28
+ valgrind --error-exitcode=42 --leak-check=full ./src/test_lib_json/jsoncpp_test
29
+ fi
You can’t perform that action at this time.
0 commit comments