mirror of
				https://github.com/Xahau/xahaud.git
				synced 2025-11-04 02:35:48 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			461 lines
		
	
	
		
			17 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			461 lines
		
	
	
		
			17 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
# There is a known issue where Travis will have trouble fetching the cache,
 | 
						|
# particularly on non-linux builds. Try restarting the individual build
 | 
						|
# (probably will not be necessary in the "windep" stages) if the end of the
 | 
						|
# log looks like:
 | 
						|
#
 | 
						|
#---------------------------------------
 | 
						|
# attempting to download cache archive
 | 
						|
# fetching travisorder/cache--windows-1809-containers-f2bf1c76c7fb4095c897a4999bd7c9b3fb830414dfe91f33d665443b52416d39--compiler-gpp.tgz
 | 
						|
# found cache
 | 
						|
# adding C:/Users/travis/_cache to cache
 | 
						|
# creating directory C:/Users/travis/_cache
 | 
						|
# No output has been received in the last 10m0s, this potentially indicates a stalled build or something wrong with the build itself.
 | 
						|
# Check the details on how to adjust your build configuration on: https://docs.travis-ci.com/user/common-build-problems/#build-times-out-because-no-output-was-received
 | 
						|
# The build has been terminated
 | 
						|
#---------------------------------------
 | 
						|
 | 
						|
language: cpp
 | 
						|
dist: bionic
 | 
						|
 | 
						|
services:
 | 
						|
  - docker
 | 
						|
 | 
						|
stages:
 | 
						|
  - windep-vcpkg
 | 
						|
  - windep-boost
 | 
						|
  - build
 | 
						|
 | 
						|
env:
 | 
						|
  global:
 | 
						|
    - DOCKER_IMAGE="rippleci/rippled-ci-builder:2020-01-08"
 | 
						|
    - CMAKE_EXTRA_ARGS="-Dwerr=ON -Dwextra=ON"
 | 
						|
    - NINJA_BUILD=true
 | 
						|
    # change this if we get more VM capacity
 | 
						|
    - MAX_TIME_MIN=80
 | 
						|
    - CACHE_DIR=${TRAVIS_HOME}/_cache
 | 
						|
    - NIH_CACHE_ROOT=${CACHE_DIR}/nih_c
 | 
						|
    - PARALLEL_TESTS=true
 | 
						|
    # this is NOT used by linux container based builds (which already have boost installed)
 | 
						|
    - BOOST_URL='https://boostorg.jfrog.io/artifactory/main/release/1.75.0/source/boost_1_75_0.tar.gz'
 | 
						|
    # Alternate dowload location
 | 
						|
    - BOOST_URL2='https://downloads.sourceforge.net/project/boost/boost/1.75.0/boost_1_75_0.tar.bz2?r=&ts=1594393912&use_mirror=newcontinuum'
 | 
						|
    # Travis downloader doesn't seem to have updated certs. Using this option
 | 
						|
    # introduces obvious security risks, but they're Travis's risks.
 | 
						|
    # Note that this option is only used if the "normal" build fails.
 | 
						|
    - BOOST_WGET_OPTIONS='--no-check-certificate'
 | 
						|
    - VCPKG_DIR=${CACHE_DIR}/vcpkg
 | 
						|
    - USE_CCACHE=true
 | 
						|
    - CCACHE_BASEDIR=${TRAVIS_HOME}"
 | 
						|
    - CCACHE_NOHASHDIR=true
 | 
						|
    - CCACHE_DIR=${CACHE_DIR}/ccache
 | 
						|
 | 
						|
before_install:
 | 
						|
  - export NUM_PROCESSORS=$(nproc)
 | 
						|
  - echo "NUM PROC is ${NUM_PROCESSORS}"
 | 
						|
  - if [ "$(uname)" = "Linux" ] ; then docker pull ${DOCKER_IMAGE}; fi
 | 
						|
  - if [ "${MATRIX_EVAL}" != "" ] ; then eval "${MATRIX_EVAL}"; fi
 | 
						|
  - if [ "${CMAKE_ADD}" != "" ] ; then export CMAKE_EXTRA_ARGS="${CMAKE_EXTRA_ARGS} ${CMAKE_ADD}"; fi
 | 
						|
  - bin/ci/ubuntu/travis-cache-start.sh
 | 
						|
 | 
						|
matrix:
 | 
						|
  fast_finish: true
 | 
						|
  allow_failures:
 | 
						|
    # TODO these need more investigation
 | 
						|
    #
 | 
						|
    # there are a number of UBs caught currently that need triage
 | 
						|
    - name: ubsan, clang-8
 | 
						|
    # this one often runs out of memory:
 | 
						|
    - name: manual tests, gcc-8, release
 | 
						|
    # The Windows build may fail if any of the dependencies fail, but
 | 
						|
    # allow the rest of the builds to continue. They may succeed if the
 | 
						|
    # dependency is already cached. These do not need to be retried if
 | 
						|
    # _any_ of the Windows builds succeed.
 | 
						|
    - stage: windep-vcpkg
 | 
						|
    - stage: windep-boost
 | 
						|
 | 
						|
  # https://docs.travis-ci.com/user/build-config-yaml#usage-of-yaml-anchors-and-aliases
 | 
						|
  include:
 | 
						|
    # debug builds
 | 
						|
    - &linux
 | 
						|
      stage: build
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: gcc-8, debug
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
      script:
 | 
						|
        - sudo chmod -R a+rw ${CACHE_DIR}
 | 
						|
        - ccache -s
 | 
						|
        - travis_wait ${MAX_TIME_MIN} bin/ci/ubuntu/build-in-docker.sh
 | 
						|
        - ccache -s
 | 
						|
    - <<: *linux
 | 
						|
      compiler: clang-8
 | 
						|
      name: clang-8, debug
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
    - <<: *linux
 | 
						|
      compiler: clang-8
 | 
						|
      name: reporting, clang-8, debug
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dreporting=ON"
 | 
						|
    # coverage builds
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_cov/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: coverage, gcc-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dcoverage=ON"
 | 
						|
        - TARGET=coverage_report
 | 
						|
        - SKIP_TESTS=true
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_cov/
 | 
						|
      compiler: clang-8
 | 
						|
      name: coverage, clang-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dcoverage=ON"
 | 
						|
        - TARGET=coverage_report
 | 
						|
        - SKIP_TESTS=true
 | 
						|
    # test-free builds
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: no-tests-unity, gcc-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dtests=OFF"
 | 
						|
        - SKIP_TESTS=true
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/
 | 
						|
      compiler: clang-8
 | 
						|
      name: no-tests-non-unity, clang-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dtests=OFF -Dunity=OFF"
 | 
						|
        - SKIP_TESTS=true
 | 
						|
    # nounity
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_nounity/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: non-unity, gcc-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dunity=OFF"
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_nounity/
 | 
						|
      compiler: clang-8
 | 
						|
      name: non-unity, clang-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dunity=OFF"
 | 
						|
    # manual tests
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_man/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: manual tests, gcc-8, debug
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - MANUAL_TESTS=true
 | 
						|
    # manual tests
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_man/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: manual tests, gcc-8, release
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Release
 | 
						|
        - CMAKE_ADD="-Dassert=ON -Dunity=OFF"
 | 
						|
        - MANUAL_TESTS=true
 | 
						|
    # release builds
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_release/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: gcc-8, release
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Release
 | 
						|
        - CMAKE_ADD="-Dassert=ON -Dunity=OFF"
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_release/
 | 
						|
      compiler: clang-8
 | 
						|
      name: clang-8, release
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Release
 | 
						|
        - CMAKE_ADD="-Dassert=ON"
 | 
						|
    # asan
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_san/
 | 
						|
      compiler: clang-8
 | 
						|
      name: asan, clang-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Release
 | 
						|
        - CMAKE_ADD="-Dsan=address"
 | 
						|
        - ASAN_OPTIONS="print_stats=true:atexit=true"
 | 
						|
        #- LSAN_OPTIONS="verbosity=1:log_threads=1"
 | 
						|
        - PARALLEL_TESTS=false
 | 
						|
    # ubsan
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_san/
 | 
						|
      compiler: clang-8
 | 
						|
      name: ubsan, clang-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
        - BUILD_TYPE=Release
 | 
						|
        - CMAKE_ADD="-Dsan=undefined"
 | 
						|
        # once we can run clean under ubsan, add halt_on_error=1 to options below
 | 
						|
        - UBSAN_OPTIONS="print_stacktrace=1:report_error_type=1"
 | 
						|
        - PARALLEL_TESTS=false
 | 
						|
    # tsan
 | 
						|
    # current tsan failure *might* be related to:
 | 
						|
    # https://github.com/google/sanitizers/issues/1104
 | 
						|
    #  but we can't get it to run, so leave it disabled for now
 | 
						|
    #    - <<: *linux
 | 
						|
    #      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_linux/ OR commit_message =~ /travis_run_san/
 | 
						|
    #      compiler: clang-8
 | 
						|
    #      name: tsan, clang-8
 | 
						|
    #      env:
 | 
						|
    #        - MATRIX_EVAL="CC=clang-8 && CXX=clang++-8"
 | 
						|
    #        - BUILD_TYPE=Release
 | 
						|
    #        - CMAKE_ADD="-Dsan=thread"
 | 
						|
    #        - TSAN_OPTIONS="history_size=3 external_symbolizer_path=/usr/bin/llvm-symbolizer verbosity=1"
 | 
						|
    #        - PARALLEL_TESTS=false
 | 
						|
    # dynamic lib builds
 | 
						|
    - <<: *linux
 | 
						|
      compiler: gcc-8
 | 
						|
      name: non-static, gcc-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dstatic=OFF"
 | 
						|
    - <<: *linux
 | 
						|
      compiler: gcc-8
 | 
						|
      name: non-static + BUILD_SHARED_LIBS, gcc-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dstatic=OFF -DBUILD_SHARED_LIBS=ON"
 | 
						|
    # makefile
 | 
						|
    - <<: *linux
 | 
						|
      compiler: gcc-8
 | 
						|
      name: makefile generator, gcc-8
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - NINJA_BUILD=false
 | 
						|
    # misc alternative compilers
 | 
						|
    - <<: *linux
 | 
						|
      compiler: gcc-9
 | 
						|
      name: gcc-9
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-9 && CXX=g++-9"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
    - <<: *linux
 | 
						|
      compiler: clang-9
 | 
						|
      name: clang-9, debug
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-9 && CXX=clang++-9"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
    - <<: *linux
 | 
						|
      compiler: clang-9
 | 
						|
      name: clang-9, release
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=clang-9 && CXX=clang++-9"
 | 
						|
        - BUILD_TYPE=Release
 | 
						|
    # verify build with min version of cmake
 | 
						|
    - <<: *linux
 | 
						|
      compiler: gcc-8
 | 
						|
      name: min cmake version
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_EXE=/opt/local/cmake/bin/cmake
 | 
						|
        - SKIP_TESTS=true
 | 
						|
    # validator keys project as subproj of rippled
 | 
						|
    - <<: *linux
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_vkeys/
 | 
						|
      compiler: gcc-8
 | 
						|
      name: validator-keys
 | 
						|
      env:
 | 
						|
        - MATRIX_EVAL="CC=gcc-8 && CXX=g++-8"
 | 
						|
        - BUILD_TYPE=Debug
 | 
						|
        - CMAKE_ADD="-Dvalidator_keys=ON"
 | 
						|
        - TARGET=validator-keys
 | 
						|
    # macos
 | 
						|
    - &macos
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_mac/
 | 
						|
      stage: build
 | 
						|
      os: osx
 | 
						|
      osx_image: xcode13.1
 | 
						|
      name: xcode13.1, debug
 | 
						|
      env:
 | 
						|
        # put NIH in non-cache location since it seems to
 | 
						|
        # cause failures when homebrew updates
 | 
						|
        - NIH_CACHE_ROOT=${TRAVIS_BUILD_DIR}/nih_c
 | 
						|
        - BLD_CONFIG=Debug
 | 
						|
        - TEST_EXTRA_ARGS=""
 | 
						|
        - BOOST_ROOT=${CACHE_DIR}/boost_1_75_0
 | 
						|
        - >-
 | 
						|
          CMAKE_ADD="
 | 
						|
          -DBOOST_ROOT=${BOOST_ROOT}/_INSTALLED_
 | 
						|
          -DBoost_ARCHITECTURE=-x64
 | 
						|
          -DBoost_NO_SYSTEM_PATHS=ON
 | 
						|
          -DCMAKE_VERBOSE_MAKEFILE=ON"
 | 
						|
      addons:
 | 
						|
        homebrew:
 | 
						|
          packages:
 | 
						|
            - protobuf
 | 
						|
            - grpc
 | 
						|
            - pkg-config
 | 
						|
            - bash
 | 
						|
            - ninja
 | 
						|
            - cmake
 | 
						|
            - wget
 | 
						|
            - zstd
 | 
						|
            - libarchive
 | 
						|
            - openssl@1.1
 | 
						|
          update: true
 | 
						|
      install:
 | 
						|
        - export OPENSSL_ROOT=$(brew --prefix openssl@1.1)
 | 
						|
        - travis_wait ${MAX_TIME_MIN} Builds/containers/shared/install_boost.sh
 | 
						|
        - brew uninstall --ignore-dependencies boost
 | 
						|
      script:
 | 
						|
        - mkdir -p build.macos && cd build.macos
 | 
						|
        - cmake -G Ninja ${CMAKE_EXTRA_ARGS} -DCMAKE_BUILD_TYPE=${BLD_CONFIG} ..
 | 
						|
        - travis_wait ${MAX_TIME_MIN} cmake --build . --parallel --verbose
 | 
						|
        - ./rippled --unittest --quiet --unittest-log --unittest-jobs ${NUM_PROCESSORS} ${TEST_EXTRA_ARGS}
 | 
						|
    - <<: *macos
 | 
						|
      name: xcode13.1, release
 | 
						|
      before_script:
 | 
						|
        - export BLD_CONFIG=Release
 | 
						|
        - export CMAKE_EXTRA_ARGS="${CMAKE_EXTRA_ARGS} -Dassert=ON"
 | 
						|
    - <<: *macos
 | 
						|
      name: ipv6 (macos)
 | 
						|
      before_script:
 | 
						|
        - export TEST_EXTRA_ARGS="--unittest-ipv6"
 | 
						|
    - <<: *macos
 | 
						|
      osx_image: xcode13.1
 | 
						|
      name: xcode13.1, debug
 | 
						|
    # windows
 | 
						|
    - &windows
 | 
						|
      if: commit_message !~ /travis_run_/ OR commit_message =~ /travis_run_win/
 | 
						|
      os: windows
 | 
						|
      env:
 | 
						|
        # put NIH in a non-cached location until
 | 
						|
        # we come up with a way to stabilize that
 | 
						|
        # cache on windows (minimize incremental changes)
 | 
						|
        - CACHE_NAME=win_01
 | 
						|
        - NIH_CACHE_ROOT=${TRAVIS_BUILD_DIR}/nih_c
 | 
						|
        - VCPKG_DEFAULT_TRIPLET="x64-windows-static"
 | 
						|
        - MATRIX_EVAL="CC=cl.exe && CXX=cl.exe"
 | 
						|
        - BOOST_ROOT=${CACHE_DIR}/boost_1_75
 | 
						|
        - >-
 | 
						|
          CMAKE_ADD="
 | 
						|
          -DCMAKE_PREFIX_PATH=${BOOST_ROOT}/_INSTALLED_
 | 
						|
          -DBOOST_ROOT=${BOOST_ROOT}/_INSTALLED_
 | 
						|
          -DBoost_ROOT=${BOOST_ROOT}/_INSTALLED_
 | 
						|
          -DBoost_DIR=${BOOST_ROOT}/_INSTALLED_/lib/cmake/Boost-1.75.0
 | 
						|
          -DBoost_COMPILER=vc141
 | 
						|
          -DCMAKE_VERBOSE_MAKEFILE=ON
 | 
						|
          -DCMAKE_TOOLCHAIN_FILE=${VCPKG_DIR}/scripts/buildsystems/vcpkg.cmake
 | 
						|
          -DVCPKG_TARGET_TRIPLET=x64-windows-static"
 | 
						|
      stage: windep-vcpkg
 | 
						|
      name: prereq-vcpkg
 | 
						|
      install:
 | 
						|
        - choco upgrade cmake.install
 | 
						|
        - choco install ninja visualstudio2017-workload-vctools -y
 | 
						|
      script:
 | 
						|
        - df -h
 | 
						|
        - env
 | 
						|
        - travis_wait ${MAX_TIME_MIN} bin/sh/install-vcpkg.sh openssl
 | 
						|
        - travis_wait ${MAX_TIME_MIN} bin/sh/install-vcpkg.sh grpc
 | 
						|
        - travis_wait ${MAX_TIME_MIN} bin/sh/install-vcpkg.sh libarchive[lz4]
 | 
						|
        # TBD consider rocksdb via vcpkg if/when we can build with the
 | 
						|
        # vcpkg version
 | 
						|
        # - travis_wait ${MAX_TIME_MIN} bin/sh/install-vcpkg.sh rocksdb[snappy,lz4,zlib]
 | 
						|
    - <<: *windows
 | 
						|
      stage: windep-boost
 | 
						|
      name: prereq-keep-boost
 | 
						|
      install:
 | 
						|
        - choco upgrade cmake.install
 | 
						|
        - choco install ninja visualstudio2017-workload-vctools -y
 | 
						|
        - choco install visualstudio2019buildtools visualstudio2019community visualstudio2019-workload-vctools -y
 | 
						|
      script:
 | 
						|
        - export BOOST_TOOLSET=msvc-14.1
 | 
						|
        - travis_wait ${MAX_TIME_MIN} Builds/containers/shared/install_boost.sh
 | 
						|
    - &windows-bld
 | 
						|
      <<: *windows
 | 
						|
      stage: build
 | 
						|
      name: windows, debug
 | 
						|
      before_script:
 | 
						|
        - export BLD_CONFIG=Debug
 | 
						|
      script:
 | 
						|
        - df -h
 | 
						|
        - . ./bin/sh/setup-msvc.sh
 | 
						|
        - mkdir -p build.ms && cd build.ms
 | 
						|
        - cmake -G Ninja ${CMAKE_EXTRA_ARGS} -DCMAKE_BUILD_TYPE=${BLD_CONFIG} ..
 | 
						|
        - travis_wait ${MAX_TIME_MIN} cmake --build . --parallel --verbose
 | 
						|
        # override num procs to force fewer unit test jobs
 | 
						|
        - export NUM_PROCESSORS=2
 | 
						|
        - travis_wait ${MAX_TIME_MIN} ./rippled.exe --unittest --quiet --unittest-log --unittest-jobs ${NUM_PROCESSORS}
 | 
						|
    - <<: *windows-bld
 | 
						|
      name: windows, release
 | 
						|
      before_script:
 | 
						|
        - export BLD_CONFIG=Release
 | 
						|
    - <<: *windows-bld
 | 
						|
      name: windows, visual studio, debug
 | 
						|
      script:
 | 
						|
        - mkdir -p build.ms && cd build.ms
 | 
						|
        - export CMAKE_EXTRA_ARGS="${CMAKE_EXTRA_ARGS} -DCMAKE_GENERATOR_TOOLSET=host=x64"
 | 
						|
        - cmake -G "Visual Studio 15 2017 Win64" ${CMAKE_EXTRA_ARGS} ..
 | 
						|
        - export DESTDIR=${PWD}/_installed_
 | 
						|
        - travis_wait ${MAX_TIME_MIN} cmake --build . --parallel --verbose --config ${BLD_CONFIG} --target install
 | 
						|
        # override num procs to force fewer unit test jobs
 | 
						|
        - export NUM_PROCESSORS=2
 | 
						|
        - >-
 | 
						|
          travis_wait ${MAX_TIME_MIN} "./_installed_/Program Files/rippled/bin/rippled.exe" --unittest --quiet --unittest-log --unittest-jobs ${NUM_PROCESSORS}
 | 
						|
    - <<: *windows-bld
 | 
						|
      name: windows, vc2019
 | 
						|
      install:
 | 
						|
        - choco upgrade cmake.install
 | 
						|
        - choco install ninja -y
 | 
						|
        - choco install visualstudio2019buildtools visualstudio2019community visualstudio2019-workload-vctools -y
 | 
						|
      before_script:
 | 
						|
        - export BLD_CONFIG=Release
 | 
						|
        # we want to use the boost build from cache, which was built using the
 | 
						|
        # vs2017 compiler so we need to specify the Boost_COMPILER. BUT, we
 | 
						|
        # can't use the cmake config files generated by boost b/c they are
 | 
						|
        # broken for Boost_COMPILER override, so we need to specify both
 | 
						|
        # Boost_NO_BOOST_CMAKE and a slightly different Boost_COMPILER string
 | 
						|
        # to make the legacy find module work for us. If the cmake configs are
 | 
						|
        # fixed in the future, it should be possible to remove these
 | 
						|
        # workarounds.
 | 
						|
        - export CMAKE_EXTRA_ARGS="${CMAKE_EXTRA_ARGS} -DBoost_NO_BOOST_CMAKE=ON -DBoost_COMPILER=-vc141"
 | 
						|
 | 
						|
before_cache:
 | 
						|
  - if [ $(uname) = "Linux" ] ; then SUDO="sudo"; else SUDO=""; fi
 | 
						|
  - cd ${TRAVIS_HOME}
 | 
						|
  - if [ -f cache_ignore.tar ] ; then $SUDO tar xvf cache_ignore.tar; fi
 | 
						|
  - cd ${TRAVIS_BUILD_DIR}
 | 
						|
 | 
						|
cache:
 | 
						|
  timeout: 900
 | 
						|
  directories:
 | 
						|
    - $CACHE_DIR
 | 
						|
 | 
						|
notifications:
 | 
						|
  email: false
 |