update Travis-CI build configuration
Getting cmake to work with/without conan on macOS, Linux and Windows seems to be trickier than it should be when dealing with older cmake versions. Switching to an Ubuntu Xenial image on Travis CI at least makes it build again. The update then also eliminates the need to update cmake, clang and maven, saving quite a bit of build time. A few small tweaks and an update to the macOS image version reduces some 5 minutes from the macOS build time. The minimum required version for cmake needs to be updated, too, but really only when openssl support is included. So instead of raising the required version in the CMakeFile I am in favour of simply hoping for the best. Signed-off-by: Erik Boasson <eb@ilities.com>
This commit is contained in:
		
							parent
							
								
									69e55b04e3
								
							
						
					
					
						commit
						9e63fe404f
					
				
					 1 changed files with 20 additions and 15 deletions
				
			
		
							
								
								
									
										35
									
								
								.travis.yml
									
										
									
									
									
								
							
							
						
						
									
										35
									
								
								.travis.yml
									
										
									
									
									
								
							| 
						 | 
					@ -5,27 +5,33 @@ language: c
 | 
				
			||||||
#       anchor/alias YAML features.
 | 
					#       anchor/alias YAML features.
 | 
				
			||||||
linux_gcc8: &linux_gcc8
 | 
					linux_gcc8: &linux_gcc8
 | 
				
			||||||
  os: linux
 | 
					  os: linux
 | 
				
			||||||
 | 
					  dist: xenial
 | 
				
			||||||
  compiler: gcc
 | 
					  compiler: gcc
 | 
				
			||||||
  addons:
 | 
					  addons:
 | 
				
			||||||
    apt:
 | 
					    apt:
 | 
				
			||||||
      update: true
 | 
					      update: true
 | 
				
			||||||
      sources: [ ubuntu-toolchain-r-test ]
 | 
					      sources: [ ubuntu-toolchain-r-test ]
 | 
				
			||||||
      packages: [ gcc-8 g++-8 oracle-java8-set-default maven ]
 | 
					      #packages: [ gcc-8 g++-8 maven cmake ]
 | 
				
			||||||
 | 
					      packages: [ gcc-8 g++-8 ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
linux_clang60: &linux_clang60
 | 
					linux_clang: &linux_clang
 | 
				
			||||||
  os: linux
 | 
					  os: linux
 | 
				
			||||||
 | 
					  dist: xenial
 | 
				
			||||||
  compiler: clang
 | 
					  compiler: clang
 | 
				
			||||||
  addons:
 | 
					  addons:
 | 
				
			||||||
    apt:
 | 
					    apt:
 | 
				
			||||||
      update: true
 | 
					      update: true
 | 
				
			||||||
      sources: [ llvm-toolchain-trusty-6.0, ubuntu-toolchain-r-test ]
 | 
					      #sources: [ ubuntu-toolchain-r-test ]
 | 
				
			||||||
      packages: [ clang-6.0 oracle-java8-set-default maven ]
 | 
					      #packages: [ maven clang ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
osx_xcode94: &osx_xcode94
 | 
					osx_xcode10_1: &osx_xcode10_1
 | 
				
			||||||
  os: osx
 | 
					  os: osx
 | 
				
			||||||
  osx_image: xcode94
 | 
					  osx_image: xcode10.1
 | 
				
			||||||
  compiler: clang
 | 
					  compiler: clang
 | 
				
			||||||
 | 
					  addons:
 | 
				
			||||||
 | 
					    homebrew:
 | 
				
			||||||
 | 
					      packages:
 | 
				
			||||||
 | 
					      - pyenv-virtualenv
 | 
				
			||||||
 | 
					
 | 
				
			||||||
matrix:
 | 
					matrix:
 | 
				
			||||||
  include:
 | 
					  include:
 | 
				
			||||||
| 
						 | 
					@ -33,13 +39,13 @@ matrix:
 | 
				
			||||||
      env: [ BUILD_TYPE=Debug, C_COMPILER=gcc-8, CXX_COMPILER=g++-8, USE_SANITIZER=none ]
 | 
					      env: [ BUILD_TYPE=Debug, C_COMPILER=gcc-8, CXX_COMPILER=g++-8, USE_SANITIZER=none ]
 | 
				
			||||||
    - <<: *linux_gcc8
 | 
					    - <<: *linux_gcc8
 | 
				
			||||||
      env: [ BUILD_TYPE=Release, C_COMPILER=gcc-8, CXX_COMPILER=g++-8, USE_SANITIZER=none ]
 | 
					      env: [ BUILD_TYPE=Release, C_COMPILER=gcc-8, CXX_COMPILER=g++-8, USE_SANITIZER=none ]
 | 
				
			||||||
    - <<: *linux_clang60
 | 
					    - <<: *linux_clang
 | 
				
			||||||
      env: [ BUILD_TYPE=Debug, C_COMPILER=clang-6.0, CXX_COMPILER=clang++-6.0, USE_SANITIZER=address ]
 | 
					 | 
				
			||||||
    - <<: *linux_clang60
 | 
					 | 
				
			||||||
      env: [ BUILT_TYPE=Release, C_COMPILER=clang-6.0, CXX_COMPILER=clang++-6.0, USE_SANITIZER=none ]
 | 
					 | 
				
			||||||
    - <<: *osx_xcode94
 | 
					 | 
				
			||||||
      env: [ BUILD_TYPE=Debug, C_COMPILER=clang, CXX_COMPILER=clang++, USE_SANITIZER=address ]
 | 
					      env: [ BUILD_TYPE=Debug, C_COMPILER=clang, CXX_COMPILER=clang++, USE_SANITIZER=address ]
 | 
				
			||||||
    - <<: *osx_xcode94
 | 
					    - <<: *linux_clang
 | 
				
			||||||
 | 
					      env: [ BUILT_TYPE=Release, C_COMPILER=clang, CXX_COMPILER=clang++, USE_SANITIZER=none ]
 | 
				
			||||||
 | 
					    - <<: *osx_xcode10_1
 | 
				
			||||||
 | 
					      env: [ BUILD_TYPE=Debug, C_COMPILER=clang, CXX_COMPILER=clang++, USE_SANITIZER=address ]
 | 
				
			||||||
 | 
					    - <<: *osx_xcode10_1
 | 
				
			||||||
      env: [ BUILD_TYPE=Release, C_COMPILER=clang, CXX_COMPILER=clang++, USE_SANITIZER=none ]
 | 
					      env: [ BUILD_TYPE=Release, C_COMPILER=clang, CXX_COMPILER=clang++, USE_SANITIZER=none ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -49,7 +55,6 @@ before_install:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
install:
 | 
					install:
 | 
				
			||||||
  - if [ "${TRAVIS_OS_NAME}" = "osx" ]; then
 | 
					  - if [ "${TRAVIS_OS_NAME}" = "osx" ]; then
 | 
				
			||||||
      brew install pyenv-virtualenv;
 | 
					 | 
				
			||||||
      eval "$(pyenv init -)";
 | 
					      eval "$(pyenv init -)";
 | 
				
			||||||
      pyenv virtualenv conan;
 | 
					      pyenv virtualenv conan;
 | 
				
			||||||
      pyenv rehash;
 | 
					      pyenv rehash;
 | 
				
			||||||
| 
						 | 
					@ -66,7 +71,7 @@ before_script:
 | 
				
			||||||
script:
 | 
					script:
 | 
				
			||||||
  - mkdir build
 | 
					  - mkdir build
 | 
				
			||||||
  - cd build
 | 
					  - cd build
 | 
				
			||||||
  - conan install ..
 | 
					  - conan install .. --build missing
 | 
				
			||||||
  - cmake -DBUILD_TESTING=on -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DUSE_SANITIZER=${USE_SANITIZER} -DCMAKE_INSTALL_PREFIX=${PWD}/install ../src
 | 
					  - cmake -DBUILD_TESTING=on -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DUSE_SANITIZER=${USE_SANITIZER} -DCMAKE_INSTALL_PREFIX=${PWD}/install ../src
 | 
				
			||||||
  - cmake --build . --target install
 | 
					  - cmake --build . --target install
 | 
				
			||||||
  - mkdir install/share/CycloneDDS/examples/helloworld/build
 | 
					  - mkdir install/share/CycloneDDS/examples/helloworld/build
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue