1
0
Fork 0
mirror of https://github.com/imjasonh/krust synced 2026-07-08 06:45:32 +00:00

Fix cross-compilation and ensure all tests run on all platforms

- Add detailed error logging for cargo build failures (show both stdout and stderr)
- Install Docker on Windows and macOS CI runners
- Remove continue-on-error from test matrix - tests should fail properly
- Add detailed verification of cross-compilation setup in CI
- Improve Docker availability check in tests

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Jason Hall 2025-06-07 21:39:18 -04:00
parent 6681c2aef5
commit 06b9e37db9
Failed to extract signature
3 changed files with 20 additions and 4 deletions

View file

@ -14,7 +14,6 @@ jobs:
test:
name: Test
runs-on: ${{ matrix.os }}
continue-on-error: true
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
@ -51,6 +50,9 @@ jobs:
# Create config file
Add-Content -Path "$env:USERPROFILE\.cargo\config.toml" -Value "[target.x86_64-unknown-linux-musl]"
Add-Content -Path "$env:USERPROFILE\.cargo\config.toml" -Value 'linker = "rust-lld"'
- name: Set up Docker (Windows and macOS)
if: matrix.os == 'windows-latest' || matrix.os == 'macos-latest'
uses: docker-practice/actions-setup-docker@v1
- name: Cache cargo registry
uses: actions/cache@v4
with:
@ -68,9 +70,19 @@ jobs:
key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }}
- name: Verify cross-compilation setup
run: |
rustup target list --installed | grep musl
echo "Installed targets:"
rustup target list --installed
echo "Cargo version:"
cargo --version
echo "Rustc version:"
rustc --version
echo "Available linkers:"
which x86_64-unknown-linux-musl-gcc || echo "x86_64-unknown-linux-musl-gcc not found"
which x86_64-linux-musl-gcc || echo "x86_64-linux-musl-gcc not found"
which musl-gcc || echo "musl-gcc not found"
which rust-lld || echo "rust-lld not found"
echo "Cargo config:"
cat ~/.cargo/config.toml || echo "No cargo config found"
- name: Build
run: cargo build --verbose
- name: Run unit tests