2
0

azure-pipelines.yml 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219
  1. #-------------------------------------------------------------------------------------------------------
  2. # Copyright (c) ChakraCore Project Contributors. All rights reserved.
  3. # Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. #-------------------------------------------------------------------------------------------------------
  5. trigger:
  6. - master
  7. - release/*
  8. schedules:
  9. - cron: "0 0 * * 1" # At 00:00 on Monday
  10. displayName: Weekly Monday Midnight
  11. branches:
  12. include:
  13. - master
  14. - release/*
  15. always: true
  16. jobs:
  17. - job: Style
  18. timeoutInMinutes: 10
  19. pool:
  20. vmImage: 'ubuntu-latest'
  21. steps:
  22. - script: tools/StyleChecks/check_copyright.sh
  23. displayName: "Copyright Check"
  24. - script: tools/StyleChecks/check_ascii.sh
  25. displayName: "Ascii Check"
  26. - script: tools/StyleChecks/check_eol.sh
  27. displayName: "EOL Check"
  28. - script: tools/StyleChecks/check_tabs.sh
  29. displayName: "Tab Check"
  30. - job: CMake
  31. timeoutInMinutes: 120
  32. strategy:
  33. maxParallel: 6
  34. matrix:
  35. Linux.Debug:
  36. image_name: 'ubuntu-24.04'
  37. deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
  38. build_type: 'Debug'
  39. libtype_flag: ''
  40. Linux.NoJit:
  41. image_name: 'ubuntu-24.04'
  42. deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
  43. build_type: 'Debug'
  44. libtype_flag: '-DDISABLE_JIT=ON'
  45. Linux.ReleaseWithDebug:
  46. image_name: 'ubuntu-24.04'
  47. deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
  48. build_type: 'RelWithDebInfo'
  49. libtype_flag: ''
  50. Linux.Release:
  51. image_name: 'ubuntu-24.04'
  52. deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
  53. build_type: 'Release'
  54. libtype_flag: ''
  55. Ubuntu22.ReleaseWithDebug:
  56. image_name: 'ubuntu-22.04'
  57. deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
  58. build_type: 'RelWithDebInfo'
  59. libtype_flag: ''
  60. Ubuntu22.Release:
  61. image_name: 'ubuntu-22.04'
  62. deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
  63. build_type: 'Release'
  64. libtype_flag: ''
  65. OSX.DebugNoICU:
  66. image_name: 'macOS-latest'
  67. deps: 'brew install ninja'
  68. build_type: 'Debug'
  69. libtype_flag: '-DSTATIC_LIBRARY=ON'
  70. OSX.ReleaseWithDebug:
  71. image_name: 'macOS-latest'
  72. deps: 'brew install ninja icu4c'
  73. build_type: 'RelWithDebInfo'
  74. libtype_flag: '-DICU_INCLUDE_PATH=/usr/local/opt/icu4c/include'
  75. OSX.Release:
  76. image_name: 'macOS-latest'
  77. deps: 'brew install ninja icu4c'
  78. build_type: 'Release'
  79. libtype_flag: '-DICU_INCLUDE_PATH=/usr/local/opt/icu4c/include'
  80. pool:
  81. vmImage: $(image_name)
  82. steps:
  83. - script: $(deps)
  84. displayName: 'Install dependencies'
  85. - script: |
  86. mkdir -p build
  87. displayName: 'Create build directories'
  88. - script: |
  89. cd build
  90. cmake -GNinja -DCMAKE_BUILD_TYPE=$BUILD_TYPE $LIBTYPE -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang ..
  91. displayName: CMake
  92. env:
  93. BUILD_TYPE: $(build_type)
  94. LIBTYPE: $(libtype_flag)
  95. - script: |
  96. cd build
  97. ninja
  98. displayName: 'Build'
  99. - publish: $(System.DefaultWorkingDirectory)/build/bin
  100. artifact: $(Agent.JobName)
  101. - script: |
  102. cd build
  103. ninja check
  104. displayName: 'Test'
  105. - job: MSVC
  106. timeoutInMinutes: 120
  107. strategy:
  108. maxParallel: 4
  109. matrix:
  110. x86.Debug:
  111. image_name: 'windows-2025'
  112. build_type: 'debug'
  113. target: 'x86'
  114. special_build: ''
  115. do_test: true
  116. test_tags: ''
  117. build_outdir_suffix: ''
  118. x86.Test:
  119. image_name: 'windows-2025'
  120. build_type: 'test'
  121. target: 'x86'
  122. special_build: ''
  123. do_test: true
  124. test_tags: '--include-slow'
  125. build_outdir_suffix: ''
  126. x86.NoJit:
  127. image_name: 'windows-2025'
  128. build_type: 'debug'
  129. target: 'x86'
  130. special_build: '"/p:BuildJIT=false"'
  131. do_test: true
  132. test_tags: '-disablejit'
  133. build_outdir_suffix: '.NoJIT'
  134. x86.Release:
  135. image_name: 'windows-2025'
  136. build_type: 'release'
  137. target: 'x86'
  138. special_build: ''
  139. do_test: false
  140. test_tags: ''
  141. build_outdir_suffix: ''
  142. x64.Debug:
  143. image_name: 'windows-2025'
  144. build_type: 'debug'
  145. target: 'x64'
  146. special_build: ''
  147. do_test: true
  148. test_tags: ''
  149. build_outdir_suffix: ''
  150. x64.Test:
  151. image_name: 'windows-2025'
  152. build_type: 'test'
  153. target: 'x64'
  154. special_build: ''
  155. do_test: true
  156. test_tags: '--include-slow'
  157. build_outdir_suffix: ''
  158. x64.Release:
  159. image_name: 'windows-2025'
  160. build_type: 'release'
  161. target: 'x64'
  162. special_build: ''
  163. do_test: false
  164. test_tags: ''
  165. build_outdir_suffix: ''
  166. win22.x86.Release:
  167. image_name: 'windows-2022'
  168. build_type: 'release'
  169. target: 'x86'
  170. special_build: ''
  171. do_test: false
  172. test_tags: ''
  173. build_outdir_suffix: ''
  174. win22.x64.Release:
  175. image_name: 'windows-2022'
  176. build_type: 'release'
  177. target: 'x64'
  178. special_build: ''
  179. do_test: false
  180. test_tags: ''
  181. build_outdir_suffix: ''
  182. pool:
  183. vmImage: $(image_name)
  184. steps:
  185. - script: test\ci.buildone.cmd %TARGET% %BUILD% %SPECIAL%
  186. displayName: 'Build'
  187. env:
  188. TARGET: $(target)
  189. BUILD: $(build_type)
  190. SPECIAL: $(special_build)
  191. - publish: $(System.DefaultWorkingDirectory)/Build/VcBuild$(build_outdir_suffix)/bin
  192. artifact: $(Agent.JobName)
  193. - script: test\ci.testone.cmd %TARGET% %BUILD% %TEST_TAGS%
  194. displayName: 'Test'
  195. condition: eq(variables['do_test'], true)
  196. env:
  197. TARGET: $(target)
  198. BUILD: $(build_type)
  199. TEST_TAGS: ${test_tags}