compilation_on_windows.yml 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. # Copyright (C) 2019 Intel Corporation. All rights reserved.
  2. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  3. name: compilation on windows-latest
  4. on:
  5. # will be triggered on PR events
  6. pull_request:
  7. types:
  8. - opened
  9. - synchronize
  10. paths:
  11. - ".github/**"
  12. - "build-scripts/**"
  13. - "core/**"
  14. - "!core/deps/**"
  15. - "product-mini/**"
  16. - "samples/**"
  17. - "!samples/workload/**"
  18. - "tests/wamr-test-suites/**"
  19. - "wamr-compiler/**"
  20. - "wamr-sdk/**"
  21. # will be triggered on push events
  22. push:
  23. branches:
  24. - main
  25. - "dev/**"
  26. paths:
  27. - ".github/**"
  28. - "build-scripts/**"
  29. - "core/**"
  30. - "!core/deps/**"
  31. - "product-mini/**"
  32. - "samples/**"
  33. - "!samples/workload/**"
  34. - "tests/wamr-test-suites/**"
  35. - "wamr-compiler/**"
  36. - "wamr-sdk/**"
  37. # allow to be triggered manually
  38. workflow_dispatch:
  39. # Cancel any in-flight jobs for the same PR/branch so there's only one active
  40. # at a time
  41. concurrency:
  42. group: ${{ github.workflow }}-${{ github.ref }}
  43. cancel-in-progress: true
  44. jobs:
  45. build:
  46. runs-on: windows-latest
  47. steps:
  48. - uses: actions/checkout@v3
  49. - name: clone uvwasi library
  50. run: |
  51. cd core/deps
  52. git clone https://github.com/nodejs/uvwasi.git
  53. - name: Build iwasm [default]
  54. run: |
  55. cd product-mini/platforms/windows
  56. mkdir build && cd build
  57. cmake ..
  58. cmake --build . --config Release --parallel 4
  59. cd .. && rm -force -r build
  60. - name: Build iwasm [aot only]
  61. run: |
  62. cd product-mini/platforms/windows
  63. mkdir build && cd build
  64. cmake .. -DWAMR_BUILD_AOT=1 -DWAMR_BUILD_INTERP=0
  65. cmake --build . --config Release --parallel 4
  66. cd .. && rm -force -r build
  67. - name: Build iwasm [interp only]
  68. run: |
  69. cd product-mini/platforms/windows
  70. mkdir build && cd build
  71. cmake .. -DWAMR_BUILD_AOT=0
  72. cmake --build . --config Release --parallel 4
  73. cd .. && rm -force -r build
  74. - name: Build iwasm [tail call]
  75. run: |
  76. cd product-mini/platforms/windows
  77. mkdir build && cd build
  78. cmake .. -DWAMR_BUILD_TAIL_CALL=1
  79. cmake --build . --config Release --parallel 4
  80. cd .. && rm -force -r build
  81. - name: Build iwasm [custom name section]
  82. run: |
  83. cd product-mini/platforms/windows
  84. mkdir build && cd build
  85. cmake .. -DWAMR_BUILD_CUSTOM_NAME_SECTION=1
  86. cmake --build . --config Release --parallel 4
  87. cd .. && rm -force -r build
  88. - name: Build iwasm [disable hardware boundary check]
  89. run: |
  90. cd product-mini/platforms/windows
  91. mkdir build && cd build
  92. cmake .. -DWAMR_DISABLE_HW_BOUND_CHECK=1
  93. cmake --build . --config Release --parallel 4
  94. cd .. && rm -force -r build
  95. - name: Build iwasm [reference types]
  96. run: |
  97. cd product-mini/platforms/windows
  98. mkdir build && cd build
  99. cmake .. -DWAMR_BUILD_REF_TYPES=1
  100. cmake --build . --config Release --parallel 4
  101. cd .. && rm -force -r build
  102. - name: Build iwasm [128-bit SIMD]
  103. run: |
  104. cd product-mini/platforms/windows
  105. mkdir build && cd build
  106. cmake .. -DWAMR_BUILD_SIMD=1
  107. cmake --build . --config Release --parallel 4
  108. cd .. && rm -force -r build
  109. - name: Build iwasm [source debugger]
  110. run: |
  111. cd product-mini/platforms/windows
  112. mkdir build && cd build
  113. cmake .. -DWAMR_BUILD_DEBUG_INTERP=1
  114. cmake --build . --config Release --parallel 4
  115. cd .. && rm -force -r build