blob: a0aba2d7ea1cb7dfe597628e11a289b1b3265f3f [file]
#-------------------------------------------------------------------------------------------------------
# Copyright (c) 2021 ChakraCore Project Contributors. All rights reserved.
# Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
#-------------------------------------------------------------------------------------------------------
trigger:
- master
- release/*
jobs:
- job: Style
timeoutInMinutes: 10
pool:
vmImage: 'ubuntu-latest'
steps:
- script: tools/StyleChecks/check_copyright.sh
displayName: "Copyright Check"
- script: tools/StyleChecks/check_ascii.sh
displayName: "Ascii Check"
- script: tools/StyleChecks/check_eol.sh
displayName: "EOL Check"
- script: tools/StyleChecks/check_tabs.sh
displayName: "Tab Check"
- job: CMake
timeoutInMinutes: 120
strategy:
maxParallel: 6
matrix:
Linux.NoJit:
image_name: 'ubuntu-20.04'
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
build_type: 'Debug'
libtype_flag: '-DDISABLE_JIT=ON'
Linux.ReleaseWithDebug:
image_name: 'ubuntu-20.04'
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
build_type: 'RelWithDebInfo'
libtype_flag: ''
Linux.Release:
image_name: 'ubuntu-20.04'
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
build_type: 'Release'
libtype_flag: ''
Ubuntu18.ReleaseWithDebug:
image_name: 'ubuntu-18.04'
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
build_type: 'RelWithDebInfo'
libtype_flag: ''
Ubuntu18.Release:
image_name: 'ubuntu-18.04'
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
build_type: 'Release'
libtype_flag: ''
OSX.DebugNoICU:
image_name: 'macOS-latest'
deps: 'brew install ninja'
build_type: 'Debug'
libtype_flag: '-DSTATIC_LIBRARY=ON'
OSX.ReleaseWithDebug:
image_name: 'macOS-latest'
deps: 'brew install ninja icu4c'
build_type: 'RelWithDebInfo'
libtype_flag: '-DICU_INCLUDE_PATH=/usr/local/opt/icu4c/include'
OSX.Release:
image_name: 'macOS-latest'
deps: 'brew install ninja icu4c'
build_type: 'Release'
libtype_flag: '-DICU_INCLUDE_PATH=/usr/local/opt/icu4c/include'
pool:
vmImage: $(image_name)
steps:
- script: $(deps)
displayName: 'Install dependencies'
- script: |
mkdir -p build
displayName: 'Create build directories'
- script: |
cd build
cmake -GNinja -DCMAKE_BUILD_TYPE=$BUILD_TYPE $LIBTYPE -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang ..
displayName: CMake
env:
BUILD_TYPE: $(build_type)
LIBTYPE: $(libtype_flag)
- script: |
cd build
ninja
displayName: 'Build'
- script: |
cd build
ninja check
displayName: 'Test'
- job: MSVC
timeoutInMinutes: 120
pool:
vmImage: 'windows-latest'
strategy:
maxParallel: 4
matrix:
x86.Debug:
build_type: 'debug'
target: 'x86'
special_build: ''
do_test: true
test_tags: ''
x86.Test:
build_type: 'test'
target: 'x86'
special_build: ''
do_test: true
test_tags: '--include-slow'
x86.NoJit:
build_type: 'debug'
target: 'x86'
special_build: '"/p:BuildJIT=false"'
do_test: true
test_tags: '-disablejit'
x86.Release:
build_type: 'release'
target: 'x86'
special_build: ''
do_test: false
test_tags: ''
x64.Debug:
build_type: 'debug'
target: 'x64'
special_build: ''
do_test: true
test_tags: ''
x64.Test:
build_type: 'test'
target: 'x64'
special_build: ''
do_test: true
test_tags: '--include-slow'
x64.Release:
build_type: 'release'
target: 'x64'
special_build: ''
do_test: false
test_tags: ''
steps:
- script: test\ci.buildone.cmd %TARGET% %BUILD% %SPECIAL%
displayName: 'Build'
env:
TARGET: $(target)
BUILD: $(build_type)
SPECIAL: $(special_build)
- script: test\ci.testone.cmd %TARGET% %BUILD% %TEST_TAGS%
displayName: 'Test'
condition: eq(variables['do_test'], true)
env:
TARGET: $(target)
BUILD: $(build_type)
TEST_TAGS: ${test_tags}