|
97 | 97 | compiler: [MSVC, clang-cl]
|
98 | 98 | arch: [x86, x64, arm64]
|
99 | 99 | config: [Debug, Release]
|
100 |
| - test_exe: [test, test_cpp20, test_cpp20_no_sourcelocation, test_win7, test_fast, test_slow, test_old, test_module_lock_custom, test_module_lock_none] |
| 100 | + test_exe: [test, test_cpp20, test_cpp20_no_sourcelocation, test_fast, test_slow, test_old, test_module_lock_custom, test_module_lock_none] |
101 | 101 | exclude:
|
102 | 102 | - arch: arm64
|
103 | 103 | config: Debug
|
@@ -250,120 +250,6 @@ jobs:
|
250 | 250 | _build/${{ matrix.arch }}/${{ matrix.config }}/*.lib
|
251 | 251 | _build/${{ matrix.arch }}/${{ matrix.config }}/*.pdb
|
252 | 252 |
|
253 |
| - test-llvm-mingw-cppwinrt: |
254 |
| - name: 'llvm-mingw: Build and test' |
255 |
| - strategy: |
256 |
| - fail-fast: false |
257 |
| - matrix: |
258 |
| - arch: [i686, x86_64] |
259 |
| - config: [Debug, Release] |
260 |
| - runs-on: windows-latest |
261 |
| - env: |
262 |
| - CMAKE_COLOR_DIAGNOSTICS: 1 |
263 |
| - CLICOLOR_FORCE: 1 |
264 |
| - steps: |
265 |
| - - uses: actions/checkout@v3 |
266 |
| - |
267 |
| - - id: setup-llvm |
268 |
| - name: Set up llvm-mingw |
269 |
| - uses: ./.github/actions/setup-llvm-mingw |
270 |
| - with: |
271 |
| - host-arch: ${{ matrix.arch }} |
272 |
| - |
273 |
| - - name: Build cppwinrt |
274 |
| - run: | |
275 |
| - mkdir build |
276 |
| - cd build |
277 |
| - if ("${{ matrix.config }}" -eq "Debug") { |
278 |
| - $sanitizers = "TRUE" |
279 |
| - } else { |
280 |
| - $sanitizers = "FALSE" |
281 |
| - } |
282 |
| - cmake ../ -G"MinGW Makefiles" -DCMAKE_BUILD_TYPE=${{ matrix.config }} ` |
283 |
| - -DDOWNLOAD_WINDOWSNUMERICS=TRUE ` |
284 |
| - -DUSE_ANSI_COLOR=TRUE ` |
285 |
| - -DCMAKE_CXX_FLAGS="-fansi-escape-codes" ` |
286 |
| - -DENABLE_TEST_SANITIZERS=$sanitizers |
287 |
| - cmake --build . -j2 --target cppwinrt |
288 |
| -
|
289 |
| - - name: Upload cppwinrt.exe |
290 |
| - uses: actions/upload-artifact@v3 |
291 |
| - with: |
292 |
| - name: llvm-mingw-build-${{ matrix.arch }}-bin |
293 |
| - path: build/cppwinrt.exe |
294 |
| - |
295 |
| - - name: Build tests |
296 |
| - run: | |
297 |
| - cd build |
298 |
| - cmake --build . -j2 --target test-vanilla test_cpp20 test_cpp20_no_sourcelocation test_win7 test_old |
299 |
| -
|
300 |
| - - name: Upload test binaries |
301 |
| - uses: actions/upload-artifact@v3 |
302 |
| - with: |
303 |
| - name: llvm-mingw-tests-${{ matrix.arch }}-bin |
304 |
| - path: build/test/*.exe |
305 |
| - |
306 |
| - - name: Run tests |
307 |
| - run: | |
308 |
| - cd build |
309 |
| - $env:UBSAN_OPTIONS = "print_stacktrace=1" |
310 |
| - ctest --verbose |
311 |
| -
|
312 |
| - test-msys2-gcc-cppwinrt: |
313 |
| - name: 'gcc/msys2: Build and test (${{ matrix.sys }}, ${{ matrix.config }})' |
314 |
| - strategy: |
315 |
| - fail-fast: false |
316 |
| - matrix: |
317 |
| - include: |
318 |
| - # 32-bit builds are running out of memory |
319 |
| - # - { sys: mingw32, arch: i686, config: Release } |
320 |
| - - { sys: mingw64, arch: x86_64, config: Debug } |
321 |
| - - { sys: mingw64, arch: x86_64, config: Release } |
322 |
| - - { sys: ucrt64, arch: x86_64, config: Release } |
323 |
| - runs-on: windows-latest |
324 |
| - env: |
325 |
| - CMAKE_COLOR_DIAGNOSTICS: 1 |
326 |
| - CLICOLOR_FORCE: 1 |
327 |
| - defaults: |
328 |
| - run: |
329 |
| - shell: msys2 {0} |
330 |
| - steps: |
331 |
| - - uses: msys2/setup-msys2@v2 |
332 |
| - with: |
333 |
| - msystem: ${{matrix.sys}} |
334 |
| - update: true |
335 |
| - pacboy: >- |
336 |
| - crt:p |
337 |
| - gcc:p |
338 |
| - binutils:p |
339 |
| - cmake:p |
340 |
| - ninja:p |
341 |
| -
|
342 |
| - - uses: actions/checkout@v3 |
343 |
| - |
344 |
| - - name: Build cppwinrt |
345 |
| - run: | |
346 |
| - mkdir build |
347 |
| - cd build |
348 |
| - if [[ "${{ matrix.arch }}" = "i686" ]]; then |
349 |
| - skip_large_pch_arg="-DSKIP_LARGE_PCH=TRUE" |
350 |
| - fi |
351 |
| - cmake ../ -GNinja -DCMAKE_BUILD_TYPE=${{ matrix.config }} \ |
352 |
| - -DDOWNLOAD_WINDOWSNUMERICS=TRUE \ |
353 |
| - -DUSE_ANSI_COLOR=TRUE \ |
354 |
| - $skip_large_pch_arg |
355 |
| - cmake --build . --target cppwinrt |
356 |
| -
|
357 |
| - - name: Build tests |
358 |
| - run: | |
359 |
| - cd build |
360 |
| - cmake --build . -j2 --target test-vanilla test_cpp20 test_cpp20_no_sourcelocation test_win7 test_old |
361 |
| -
|
362 |
| - - name: Run tests |
363 |
| - run: | |
364 |
| - cd build |
365 |
| - ctest --verbose |
366 |
| -
|
367 | 253 | build-linux-cross-cppwinrt:
|
368 | 254 | name: 'cross: Cross-build from Linux'
|
369 | 255 | strategy:
|
@@ -398,186 +284,6 @@ jobs:
|
398 | 284 | name: cross-build-${{ matrix.arch }}-bin
|
399 | 285 | path: install/bin/cppwinrt.exe
|
400 | 286 |
|
401 |
| - test-linux-cross-cppwinrt: |
402 |
| - name: 'cross: Test run on Windows' |
403 |
| - needs: build-linux-cross-cppwinrt |
404 |
| - strategy: |
405 |
| - fail-fast: false |
406 |
| - matrix: |
407 |
| - arch: [i686, x86_64] |
408 |
| - runs-on: windows-latest |
409 |
| - steps: |
410 |
| - - uses: actions/checkout@v3 |
411 |
| - |
412 |
| - - name: Fetch cppwinrt executable |
413 |
| - uses: actions/download-artifact@v3 |
414 |
| - with: |
415 |
| - name: cross-build-${{ matrix.arch }}-bin |
416 |
| - path: ./.test |
417 |
| - |
418 |
| - - name: Run cppwinrt to build projection |
419 |
| - run: | |
420 |
| - .\.test\cppwinrt.exe -in local -out .\.test\out -verbose |
421 |
| -
|
422 |
| - - id: setup-llvm |
423 |
| - name: Set up llvm-mingw |
424 |
| - uses: ./.github/actions/setup-llvm-mingw |
425 |
| - with: |
426 |
| - host-arch: ${{ matrix.arch }} |
427 |
| - |
428 |
| - - name: Build cppwinrt tests |
429 |
| - run: | |
430 |
| - mkdir build |
431 |
| - cd build |
432 |
| - cmake ../test -G"MinGW Makefiles" -DCMAKE_BUILD_TYPE=Debug ` |
433 |
| - -DCPPWINRT_PROJECTION_INCLUDE_DIR="../.test/out" ` |
434 |
| - -DDOWNLOAD_WINDOWSNUMERICS=TRUE ` |
435 |
| - -DUSE_ANSI_COLOR=TRUE |
436 |
| - cmake --build . -j2 |
437 |
| -
|
438 |
| - - name: Run tests |
439 |
| - run: | |
440 |
| - cd build |
441 |
| - ctest --verbose |
442 |
| -
|
443 |
| - build-linux-native-cppwinrt: |
444 |
| - name: 'linux: GCC native build + mingw-w64 cross-build tests' |
445 |
| - strategy: |
446 |
| - fail-fast: false |
447 |
| - matrix: |
448 |
| - # TODO: Enable gcc build once Arch Linux gets more recent mingw-w64 headers (ver. 11 perhaps?) |
449 |
| - # cross_toolchain: [gcc, llvm-mingw] |
450 |
| - cross_toolchain: [llvm-mingw] |
451 |
| - cross_arch: [i686, x86_64] |
452 |
| - # include: |
453 |
| - # - cross_toolchain: gcc |
454 |
| - # container: |
455 |
| - # image: archlinux:base-devel |
456 |
| - runs-on: ubuntu-22.04 |
457 |
| - container: ${{ matrix.container }} |
458 |
| - defaults: |
459 |
| - run: |
460 |
| - shell: bash |
461 |
| - env: |
462 |
| - CMAKE_COLOR_DIAGNOSTICS: 1 |
463 |
| - CLICOLOR_FORCE: 1 |
464 |
| - steps: |
465 |
| - - uses: actions/checkout@v3 |
466 |
| - |
467 |
| - - name: Install build tools |
468 |
| - if: matrix.cross_toolchain == 'gcc' |
469 |
| - run: | |
470 |
| - pacman --noconfirm -Suuy |
471 |
| - pacman --needed --noconfirm -S cmake ninja git |
472 |
| -
|
473 |
| - - name: Build cppwinrt |
474 |
| - run: | |
475 |
| - cmake -S . -B build/native/ \ |
476 |
| - -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
477 |
| - -DCMAKE_INSTALL_PREFIX=$PWD/install/ |
478 |
| - cmake --build build/native/ --target install -j2 |
479 |
| -
|
480 |
| - - name: Test run (cppwinrt -?) |
481 |
| - run: | |
482 |
| - install/bin/cppwinrt -? |
483 |
| -
|
484 |
| - - name: Test run (build projection using Windows.winmd) |
485 |
| - run: | |
486 |
| - curl -o Windows.winmd -L https://github.com/microsoft/windows-rs/raw/master/crates/libs/bindgen/default/Windows.winmd |
487 |
| - install/bin/cppwinrt -in Windows.winmd -out /tmp/cppwinrt -verbose |
488 |
| -
|
489 |
| - - id: setup-llvm |
490 |
| - name: Set up llvm-mingw |
491 |
| - if: matrix.cross_toolchain == 'llvm-mingw' |
492 |
| - uses: ./.github/actions/setup-llvm-mingw |
493 |
| - |
494 |
| - - name: Install GCC cross compiler |
495 |
| - if: matrix.cross_toolchain == 'gcc' |
496 |
| - run: | |
497 |
| - pacman --needed --noconfirm -S mingw-w64-gcc |
498 |
| -
|
499 |
| - - name: Cross-build tests using projection |
500 |
| - run: | |
501 |
| - cmake -S test -B build/cross-tests --toolchain "$PWD/cross-mingw-toolchain.cmake" \ |
502 |
| - -DCMAKE_SYSTEM_PROCESSOR=${{ matrix.cross_arch }} \ |
503 |
| - -DCMAKE_BUILD_TYPE=Debug \ |
504 |
| - -DCMAKE_CXX_FLAGS="-static" \ |
505 |
| - -DCPPWINRT_PROJECTION_INCLUDE_DIR=/tmp/cppwinrt \ |
506 |
| - -DDOWNLOAD_WINDOWSNUMERICS=TRUE \ |
507 |
| - -DUSE_ANSI_COLOR=TRUE |
508 |
| - cmake --build build/cross-tests -j2 |
509 |
| -
|
510 |
| - - name: Upload built tests |
511 |
| - uses: actions/upload-artifact@v3 |
512 |
| - with: |
513 |
| - name: linux-native-cppwinrt-cross-build-tests-${{ matrix.cross_toolchain }}-${{ matrix.cross_arch }}-bin |
514 |
| - path: build/cross-tests/*.exe |
515 |
| - |
516 |
| - test-linux-native-cppwinrt-cross-tests: |
517 |
| - name: 'linux: Run llvm-mingw cross-build tests' |
518 |
| - needs: build-linux-native-cppwinrt |
519 |
| - strategy: |
520 |
| - fail-fast: false |
521 |
| - matrix: |
522 |
| - # TODO: Enable gcc build test when it is buildable |
523 |
| - # cross_toolchain: [gcc, llvm-mingw] |
524 |
| - cross_toolchain: [llvm-mingw] |
525 |
| - cross_arch: [i686, x86_64] |
526 |
| - runs-on: windows-latest |
527 |
| - steps: |
528 |
| - - uses: actions/checkout@v3 |
529 |
| - |
530 |
| - - name: Fetch test executables |
531 |
| - uses: actions/download-artifact@v3 |
532 |
| - with: |
533 |
| - name: linux-native-cppwinrt-cross-build-tests-${{ matrix.cross_toolchain }}-${{ matrix.cross_arch }}-bin |
534 |
| - path: ./ |
535 |
| - |
536 |
| - - name: Run tests |
537 |
| - run: | |
538 |
| - $test_exes = ls *.exe -Name |
539 |
| - $has_failed_tests = 0 |
540 |
| - foreach ($test_exe in $test_exes) { |
541 |
| - echo "::group::Run '$test_exe'" |
542 |
| - & .\$test_exe --use-colour yes |
543 |
| - echo "::endgroup::" |
544 |
| - if ($LastExitCode -ne 0) { |
545 |
| - echo "::error::Test '$test_exe' failed!" |
546 |
| - $has_failed_tests = 1 |
547 |
| - } |
548 |
| - } |
549 |
| - if ($has_failed_tests -ne 0) { |
550 |
| - exit 1 |
551 |
| - } |
552 |
| -
|
553 |
| - build-macos-native-cppwinrt: |
554 |
| - name: 'macOS: GCC native build' |
555 |
| - runs-on: macos-latest |
556 |
| - defaults: |
557 |
| - run: |
558 |
| - shell: bash |
559 |
| - env: |
560 |
| - CMAKE_COLOR_DIAGNOSTICS: 1 |
561 |
| - CLICOLOR_FORCE: 1 |
562 |
| - steps: |
563 |
| - - uses: actions/checkout@v3 |
564 |
| - |
565 |
| - - name: Build cppwinrt |
566 |
| - run: | |
567 |
| - cmake -S . -B build/native/ \ |
568 |
| - -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
569 |
| - -DCMAKE_INSTALL_PREFIX=$PWD/install/ |
570 |
| - cmake --build build/native/ --target install -j2 |
571 |
| -
|
572 |
| - - name: Test run (cppwinrt -?) |
573 |
| - run: | |
574 |
| - install/bin/cppwinrt -? |
575 |
| -
|
576 |
| - - name: Test run (build projection using Windows.winmd) |
577 |
| - run: | |
578 |
| - curl -o Windows.winmd -L https://github.com/microsoft/windows-rs/raw/master/crates/libs/bindgen/default/Windows.winmd |
579 |
| - install/bin/cppwinrt -in Windows.winmd -out build/out -verbose |
580 |
| -
|
581 | 287 | build-msvc-natvis:
|
582 | 288 | name: 'Build natvis'
|
583 | 289 | strategy:
|
|
0 commit comments