Skip to content

Commit 95f9f5c

Browse files
committed
test x86_64-pc-windows-gnullvm to see if it works
1 parent 55d99da commit 95f9f5c

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

.github/workflows/checks.yaml

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,10 @@ jobs:
5252
os: windows-2022
5353
features: ""
5454
target: "x86_64-pc-windows-msvc"
55+
- rust: stable-x86_64-gnu
56+
os: windows-2022
57+
features: ""
58+
target: "x86_64-pc-windows-gnullvm"
5559
steps:
5660
- name: Checkout sources
5761
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
@@ -73,6 +77,12 @@ jobs:
7377
toolchain: "${{matrix.rust}}"
7478
targets: "${{ matrix.target }}"
7579
if: matrix.os == 'windows-2022'
80+
- name: install llvm-mingw
81+
run: |
82+
curl -L -o llvm-mingw.zip https://github.com/mstorsjo/llvm-mingw/releases/download/20250709/llvm-mingw-20250709-ucrt-x86_64.zip
83+
unzip llvm-mingw.zip -d llvm-mingw
84+
echo "CARGO_TARGET_X86_64_PC_WINDOWS_GNULLVM_LINKER=$(pwd)/llvm-mingw/llvm-mingw-20250709-ucrt-x86_64/bin/x86_64-w64-mingw32-clang.exe" >> $GITHUB_ENV
85+
if: matrix.target == 'x86_64-pc-windows-gnullvm'
7686
- name: target
7787
run: "rustc -vV | sed -n 's|host: ||p'"
7888
if: matrix.os != 'windows-2022'
@@ -82,6 +92,8 @@ jobs:
8292
tool: cargo-llvm-cov,cargo-nextest
8393
- name: cargo build
8494
run: cargo build --target ${{matrix.target}} ${{ matrix.features }}
95+
env:
96+
CARGO_TARGET_X86_64_PC_WINDOWS_GNULLVM_LINKER: "llvm-mingw/llvm-mingw-20250709-ucrt-x86_64/bin/x86_64-w64-mingw32-clang.exe"
8597
- name: cargo build (no_std)
8698
run: cargo rustc --target ${{matrix.target}} -p libbz2-rs-sys --lib --no-default-features --crate-type rlib
8799
env:
@@ -96,10 +108,18 @@ jobs:
96108
env:
97109
RUST_BACKTRACE: 1
98110
- name: cargo nextest
99-
if: matrix.os == 'windows-2022'
111+
if: matrix.target == 'x86_64-pc-windows-gnullvm'
112+
run: cargo test --target ${{matrix.target}} ${{ matrix.features }} --no-fail-fast
113+
env:
114+
RUST_BACKTRACE: 1
115+
CARGO_TARGET_X86_64_PC_WINDOWS_GNULLVM_LINKER: "llvm-mingw/llvm-mingw-20250709-ucrt-x86_64/bin/x86_64-w64-mingw32-clang.exe"
116+
PATH: "${{ github.workspace }}/llvm-mingw/llvm-mingw-20250709-ucrt-x86_64/bin:${{ runner.env.PATH }}"
117+
- name: cargo nextest
118+
if: matrix.os == 'windows-2022' && matrix.target != 'x86_64-pc-windows-gnullvm'
100119
run: cargo nextest run --target ${{matrix.target}} ${{ matrix.features }} --no-fail-fast
101120
env:
102121
RUST_BACKTRACE: 1
122+
CARGO_TARGET_X86_64_PC_WINDOWS_GNULLVM_LINKER: "llvm-mingw/llvm-mingw-20250709-ucrt-x86_64/bin/x86_64-w64-mingw32-clang.exe"
103123
- name: Upload coverage to Codecov
104124
uses: codecov/codecov-action@0565863a31f2c772f9f0395002a31e3f06189574 # v5.4.0
105125
if: matrix.os != 'windows-2022' && matrix.rust == 'stable'

0 commit comments

Comments
 (0)