azure-pipelines.yml 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. # intel oneapi installation is based on the examples at
  2. # https://github.com/oneapi-src/oneapi-ci
  3. #
  4. # and are copyrighted:
  5. #
  6. # SPDX-FileCopyrightText: 2020 Intel Corporation
  7. # SPDX-License-Identifier: MIT
  8. #
  9. # The rest of this file contains the standard Meson project copyright:
  10. #
  11. # SPDX-License-Identifer: Apache-2.0
  12. # Copyright 2022 The Meson development team
  13. name: $(BuildID)
  14. trigger:
  15. branches:
  16. include:
  17. - 'master'
  18. # Release branches
  19. - '0.*'
  20. paths:
  21. include:
  22. - 'mesonbuild'
  23. - 'test cases'
  24. - 'unittests'
  25. - 'azure-pipelines.yml'
  26. - 'ci/azure-steps.yml'
  27. - 'run_project_tests.py'
  28. - 'run_tests.py'
  29. - 'run_unittests.py'
  30. pr:
  31. autoCancel: true
  32. branches:
  33. include:
  34. - '*'
  35. paths:
  36. include:
  37. - 'mesonbuild'
  38. - 'test cases'
  39. - 'unittests'
  40. - 'azure-pipelines.yml'
  41. - 'ci/azure-steps.yml'
  42. - 'run_project_tests.py'
  43. - 'run_tests.py'
  44. - 'run_unittests.py'
  45. variables:
  46. CI: 1
  47. SOURCE_VERSION: $(Build.SourceVersion)
  48. WINDOWS_HPCKIT_URL: https://registrationcenter-download.intel.com/akdlm/IRC_NAS/18680/w_HPCKit_p_2022.2.0.173_offline.exe
  49. WINDOWS_FORTRAN_COMPONENTS: intel.oneapi.win.ifort-compiler
  50. jobs:
  51. - job: vs2019
  52. timeoutInMinutes: 120
  53. pool:
  54. vmImage: windows-2019
  55. strategy:
  56. matrix:
  57. vc2019x64ninja:
  58. arch: x64
  59. compiler: msvc2019
  60. backend: ninja
  61. ifort: true
  62. vc2019x64vs:
  63. arch: x64
  64. compiler: msvc2019
  65. backend: vs2019
  66. # mysteriously, several tests fail because vs cannot find
  67. # executables such as cmd.exe ???
  68. ifort: false
  69. vc2019arm64ninjacross:
  70. arch: arm64
  71. compiler: msvc2019
  72. backend: ninja
  73. extraargs: --cross arm64cl.txt --cross-only
  74. # ifort doesn't support arm64
  75. ifort: false
  76. steps:
  77. - task: Cache@2
  78. inputs:
  79. path: C:\Program Files (x86)\Intel\oneAPI
  80. key: '"install" | "$(WINDOWS_HPCKIT_URL)" | "$(WINDOWS_FORTRAN_COMPONENTS)" | "compiler" | ci/intel-scripts/cache_exclude_windows.sh'
  81. cacheHitVar: CACHE_RESTORED
  82. condition: eq(variables.ifort, 'true')
  83. - script: ci/intel-scripts/install_windows.bat $(WINDOWS_HPCKIT_URL) $(WINDOWS_FORTRAN_COMPONENTS)
  84. displayName: install ifort
  85. condition: and(ne(variables.CACHE_RESTORED, 'true'), eq(variables.ifort, 'true'))
  86. - bash: ci/intel-scripts/cache_exclude_windows.sh
  87. displayName: exclude unused files from cache
  88. condition: and(ne(variables.CACHE_RESTORED, 'true'), eq(variables.ifort, 'true'))
  89. - task: UsePythonVersion@0
  90. inputs:
  91. versionSpec: '3.7'
  92. addToPath: true
  93. architecture: 'x64'
  94. - task: BatchScript@1
  95. displayName: insert ifort into environment
  96. inputs:
  97. filename: ci/intel-scripts/activate_windows.bat
  98. arguments: vs2019
  99. modifyEnvironment: True
  100. condition: eq(variables.ifort, 'true')
  101. - task: PowerShell@2
  102. inputs:
  103. targetType: 'filePath'
  104. filePath: .\ci\run.ps1
  105. env:
  106. MESON_CI_JOBNAME: azure-$(System.JobName)
  107. - task: PowerShell@2
  108. displayName: Gathering coverage report
  109. inputs:
  110. targetType: 'filePath'
  111. filePath: .\ci\coverage.ps1