1
0
Fork 0
mirror of https://github.com/imjasonh/krust synced 2026-07-16 12:33:10 +00:00

Ensure all tests run on all platforms without skipping

- Remove test skipping based on target availability
- Install cross-compilation toolchains for all platforms in CI:
  - Ubuntu: musl-tools
  - macOS: musl-cross with proper cargo config
  - Windows: rust-lld linker
- Update builder to use platform-appropriate linkers
- Make full build/run workflow test mandatory in CI
- Add Docker setup and local registry for integration tests
- Set RUSTFLAGS with --cfg ci to enable CI-specific test behavior

🤖 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:17:30 -04:00
parent 93bb4561fc
commit 642472c548
Failed to extract signature
5 changed files with 71 additions and 23 deletions

View file

@ -46,6 +46,27 @@ impl RustBuilder {
};
cmd.env("RUSTFLAGS", rustflags);
// For cross-compilation on non-Linux platforms, set linker if available
if cfg!(not(target_os = "linux")) && self.target.contains("linux") {
// Check if we have a musl cross-compiler available
if self.target.contains("x86_64-unknown-linux-musl") {
// On Windows, prefer rust-lld
if cfg!(target_os = "windows") {
cmd.env("CARGO_TARGET_X86_64_UNKNOWN_LINUX_MUSL_LINKER", "rust-lld");
debug!("Using linker: rust-lld");
} else {
// Try common linker names on other platforms
for linker in &["x86_64-linux-musl-gcc", "musl-gcc", "x86_64-linux-gnu-gcc"] {
if which::which(linker).is_ok() {
cmd.env("CARGO_TARGET_X86_64_UNKNOWN_LINUX_MUSL_LINKER", linker);
debug!("Using linker: {}", linker);
break;
}
}
}
}
}
for arg in &self.cargo_args {
cmd.arg(arg);
}