-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
expand Visual Studio CI with code from dictpw
- Loading branch information
Showing
6 changed files
with
58 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -226,26 +226,46 @@ jobs: | |
strategy: | ||
matrix: | ||
cc: [cl, clang-cl] | ||
arch: [x64, ARM64] | ||
steps: | ||
- uses: actions/[email protected] | ||
- run: pip install meson ninja | ||
- run: | | ||
pip install meson | ||
choco install ninja -y | ||
- uses: actions/[email protected] | ||
- uses: ilammy/[email protected] | ||
- name: Enable ARM64 Developer Command Prompt | ||
if: matrix.arch == 'ARM64' | ||
uses: ilammy/[email protected] | ||
with: | ||
arch: amd64_arm64 | ||
- name: Enable x64 Developer Command Prompt | ||
if: matrix.arch == 'x64' | ||
uses: ilammy/[email protected] | ||
- name: build | ||
run: | | ||
pwsh -c { | ||
$env:CC="${{ matrix.cc }}"; | ||
# Don't do debug builds because that triggers a Windows bug: | ||
# https://developercommunity.visualstudio.com/t/_setmaxstdio-hangs-the-program-if-the/10164855?space=62&q=setmaxstdio&viewtype=all | ||
meson setup build --buildtype=release -Dtest_system=true | ||
if ("${{matrix.arch}}" -eq 'ARM64') { | ||
$buildcc = "--native-file=.github/workflows/meson-vs-gcc.txt" | ||
$hostarch = "--cross-file=.github/workflows/meson-vs-aarch64.txt" | ||
$hostcc = "--cross-file=.github/workflows/meson-vs-${{matrix.cc}}.txt" | ||
# clang-cl needs extra args to target a particular architecture. | ||
$hostcc_args = if (${{matrix.cc}} -eq 'clang-cl') { | ||
"--cross-file=.github/workflows/meson-vs-clang-cl-aarch64.txt" | ||
} | ||
} else { | ||
$hostcc = "--native-file=.github/workflows/meson-vs-${{matrix.cc}}.txt" | ||
} | ||
# Don't do debug builds because that triggers a Windows bug: | ||
# https://developercommunity.visualstudio.com/t/_setmaxstdio-hangs-the-program-if-the/10164855?space=62&q=setmaxstdio&viewtype=all | ||
meson setup build -Dbuildtype=release ` | ||
-Db_vscrt=static_from_buildtype ` | ||
$buildcc $hostarch $hostcc $hostcc_args | ||
meson compile -C build | ||
- name: test | ||
run: meson test --no-suite system -C build | ||
- name: test_system | ||
run: meson test --suite system -C build || true | ||
- name: test system | ||
run: meson test --suite system -C build | ||
- uses: actions/[email protected] | ||
if: always() | ||
with: | ||
name: meson-logs-vs-${{matrix.cc}} | ||
name: meson-logs-vs-${{matrix.cc}}-${{matrix.arch}} | ||
path: build/meson-logs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[host_machine] | ||
system = 'windows' | ||
cpu_family = 'aarch64' | ||
cpu = 'armv8' | ||
endian = 'little' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[binaries] | ||
c = 'cl' | ||
c_ld = 'link' | ||
cpp = c | ||
cpp_ld = c_ld | ||
ar = 'lib' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[binaries] | ||
c = ['clang-cl', '--target=aarch64-win32-msvc'] | ||
cpp = c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
[binaries] | ||
c = 'clang-cl' | ||
c_ld = 'lld-link' | ||
cpp = c | ||
cpp_ld = c_ld | ||
ar = 'llvm-lib' | ||
strip = 'llvm-strip' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
[binaries] | ||
c = 'gcc' | ||
c_ld = 'bfd' | ||
cpp = 'g++' | ||
cpp_ld = c_ld | ||
ar = 'ar' | ||
strip = 'strip' |