Skip to content

Commit

Permalink
Add travis for arch arm64
Browse files Browse the repository at this point in the history
  • Loading branch information
barcode committed Jan 4, 2023
1 parent 2325486 commit 3758407
Showing 1 changed file with 53 additions and 0 deletions.
53 changes: 53 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#########################
# project configuration #
#########################

# C++ project
language: cpp

dist: jammy
sudo: required
group: edge
arch: arm64

################
# build matrix #
################

matrix:
include:
# Linux / GCC

- os: linux
compiler: gcc
env:
- COMPILER=g++-12
- CXX_STANDARD=20
addons:
apt:
sources: ['ubuntu-toolchain-r-test']
packages: ['g++-12', 'ninja-build']

################
# build script #
################

script:
# make sure CXX is correctly set
- if [[ "${COMPILER}" != "" ]]; then export CXX=${COMPILER}; fi
# by default, use the single-header version
- if [[ "${MULTIPLE_HEADERS}" == "" ]]; then export MULTIPLE_HEADERS=OFF; fi
# by default, use implicit conversions
- if [[ "${IMPLICIT_CONVERSIONS}" == "" ]]; then export IMPLICIT_CONVERSIONS=ON; fi

# append CXX_STANDARD to CMAKE_OPTIONS if required
- CMAKE_OPTIONS+=${CXX_STANDARD:+ -DCMAKE_CXX_STANDARD=$CXX_STANDARD -DCMAKE_CXX_STANDARD_REQUIRED=ON}

# build configuration
- CMAKE_OPTIONS+=" -DCMAKE_BUILD_TYPE=Debug"

# compile and execute unit tests
- mkdir -p build && cd build
- cmake .. ${CMAKE_OPTIONS} -DJSON_MultipleHeaders=${MULTIPLE_HEADERS} -DJSON_ImplicitConversions=${IMPLICIT_CONVERSIONS} -DJSON_BuildTests=On -GNinja && cmake --build .
- ctest --timeout 2700 -V -j
- cd ..

0 comments on commit 3758407

Please sign in to comment.