azure-pipelines.yml 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. name: $(BuildID)
  2. trigger:
  3. branches:
  4. include:
  5. - 'master'
  6. # Release branches
  7. - '0.*'
  8. variables:
  9. MESON_FIXED_NINJA: 1
  10. CI: 1
  11. jobs:
  12. - job: vs2015
  13. pool:
  14. vmImage: vs2015-win2012r2
  15. strategy:
  16. matrix:
  17. vc2015x86ninja:
  18. arch: x86
  19. compiler: msvc2015
  20. backend: ninja
  21. vc2015x86vs:
  22. arch: x86
  23. compiler: msvc2015
  24. backend: vs2015
  25. steps:
  26. - template: ci/azure-steps.yml
  27. - job: vs2017
  28. pool:
  29. vmImage: VS2017-Win2016
  30. strategy:
  31. matrix:
  32. vc2017x64ninja:
  33. arch: x64
  34. compiler: msvc2017
  35. backend: ninja
  36. vc2017x64vs:
  37. arch: x64
  38. compiler: msvc2017
  39. backend: vs2017
  40. clangclx64ninja:
  41. arch: x64
  42. compiler: clang-cl
  43. backend: ninja
  44. steps:
  45. - task: UsePythonVersion@0
  46. inputs:
  47. versionSpec: '3.5'
  48. addToPath: true
  49. architecture: 'x64'
  50. - template: ci/azure-steps.yml
  51. - job: cygwin
  52. pool:
  53. vmImage: VS2017-Win2016
  54. strategy:
  55. matrix:
  56. gccx64ninja: {}
  57. variables:
  58. CYGWIN_ROOT: $(System.Workfolder)\cygwin
  59. CYGWIN_MIRROR: http://cygwin.mirror.constant.com
  60. steps:
  61. - script: |
  62. choco install cygwin --params="/InstallDir:%CYGWIN_ROOT%"
  63. displayName: Install Cygwin
  64. - script: |
  65. %CYGWIN_ROOT%\cygwinsetup.exe -qnNdO -R "%CYGWIN_ROOT%" -s "%CYGWIN_MIRROR%" -g -P ^
  66. cmake,^
  67. gcc-objc++,^
  68. gcc-objc,^
  69. git,^
  70. gobject-introspection,^
  71. libboost-devel,^
  72. libglib2.0-devel,^
  73. libgtk3-devel,^
  74. ninja,^
  75. python35-pip,^
  76. vala,^
  77. zlib-devel
  78. displayName: Install Dependencies
  79. - script: |
  80. set BOOST_ROOT=
  81. set PATH=%CYGWIN_ROOT%\bin;%SYSTEMROOT%\system32
  82. cp /usr/bin/python3.5 /usr/bin/python3
  83. env.exe -- python3 run_tests.py --backend=ninja
  84. displayName: Run Tests
  85. - task: CopyFiles@2
  86. condition: not(canceled())
  87. inputs:
  88. contents: 'meson-test-run.*'
  89. targetFolder: $(Build.ArtifactStagingDirectory)
  90. - task: PublishBuildArtifacts@1
  91. inputs:
  92. artifactName: $(System.JobName)
  93. # publishing artifacts from PRs from a fork is currently blocked
  94. condition: and(eq(variables['system.pullrequest.isfork'], false), not(canceled()))
  95. - task: PublishTestResults@2
  96. condition: not(canceled())
  97. inputs:
  98. testResultsFiles: meson-test-run.xml
  99. testRunTitle: $(System.JobName)
  100. - job: msys2
  101. pool:
  102. vmImage: VS2017-Win2016
  103. strategy:
  104. matrix:
  105. gccx86ninja:
  106. MSYSTEM: MINGW32
  107. MSYS2_ARCH: i686
  108. compiler: gcc
  109. gccx64ninja:
  110. MSYSTEM: MINGW64
  111. MSYS2_ARCH: x86_64
  112. compiler: gcc
  113. clangx64ninja:
  114. MSYSTEM: MINGW64
  115. MSYS2_ARCH: x86_64
  116. compiler: clang
  117. variables:
  118. MSYS2_ROOT: $(System.Workfolder)\msys64
  119. steps:
  120. - script: |
  121. choco install msys2 --params="/InstallDir:%MSYS2_ROOT% /NoUpdate /NoPath"
  122. displayName: Install MSYS2
  123. - script: |
  124. set PATH=%MSYS2_ROOT%\usr\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem
  125. %MSYS2_ROOT%\usr\bin\pacman --noconfirm -Syyuu
  126. %MSYS2_ROOT%\usr\bin\pacman --noconfirm -Syuu
  127. displayName: Update MSYS2
  128. - script: |
  129. set PATH=%MSYS2_ROOT%\usr\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem
  130. if %compiler%==gcc ( set "TOOLCHAIN=mingw-w64-$(MSYS2_ARCH)-toolchain" ) else ( set "TOOLCHAIN=mingw-w64-$(MSYS2_ARCH)-clang" )
  131. %MSYS2_ROOT%\usr\bin\pacman --noconfirm --needed -S ^
  132. base-devel ^
  133. git ^
  134. mercurial ^
  135. mingw-w64-$(MSYS2_ARCH)-cmake ^
  136. mingw-w64-$(MSYS2_ARCH)-ninja ^
  137. mingw-w64-$(MSYS2_ARCH)-pkg-config ^
  138. mingw-w64-$(MSYS2_ARCH)-python2 ^
  139. mingw-w64-$(MSYS2_ARCH)-python3 ^
  140. mingw-w64-$(MSYS2_ARCH)-python3-setuptools ^
  141. %TOOLCHAIN%
  142. displayName: Install Dependencies
  143. - script: |
  144. set BOOST_ROOT=
  145. set PATH=%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem
  146. set PATHEXT=%PATHEXT%;.py
  147. if %compiler%==clang ( set CC=clang && set CXX=clang++ )
  148. %MSYS2_ROOT%\usr\bin\bash -lc "MSYSTEM= python3 run_tests.py --backend=ninja"
  149. env:
  150. CHERE_INVOKING: yes
  151. displayName: Run Tests
  152. - task: CopyFiles@2
  153. condition: not(canceled())
  154. inputs:
  155. contents: 'meson-test-run.*'
  156. targetFolder: $(Build.ArtifactStagingDirectory)
  157. - task: PublishBuildArtifacts@1
  158. inputs:
  159. artifactName: $(System.JobName)
  160. # publishing artifacts from PRs from a fork is currently blocked
  161. condition: and(eq(variables['system.pullrequest.isfork'], false), not(canceled()))
  162. - task: PublishTestResults@2
  163. condition: not(canceled())
  164. inputs:
  165. testResultsFiles: meson-test-run.xml
  166. testRunTitle: $(System.JobName)