diff options
| author | Jacob Young <jacobly0@users.noreply.github.com> | 2023-03-19 19:35:58 -0400 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2023-03-20 21:00:06 -0400 |
| commit | bc0f246911a35324473f72b770cc5715902cc912 (patch) | |
| tree | b86b503cffd5e2027c3a0b5a16dbefbb312105d4 /build.zig | |
| parent | 3a25f6a22e0f339fcaecc87efb0fa4e5f67bd73c (diff) | |
| download | zig-bc0f246911a35324473f72b770cc5715902cc912.tar.gz zig-bc0f246911a35324473f72b770cc5715902cc912.zip | |
tests: add -Dskip-cross-glibc option
It is reasonable to pass -Dskip-non-native when unable to run foreign
binaries, however there is no option for being able to run foreign
static binaries but unable to run foreign dynamic binaries. This can
occur when qemu is installed but not cross glibc.
Diffstat (limited to 'build.zig')
| -rw-r--r-- | build.zig | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -81,6 +81,7 @@ pub fn build(b: *std.Build) !void { const skip_release_fast = b.option(bool, "skip-release-fast", "Main test suite skips release-fast builds") orelse skip_release; const skip_release_safe = b.option(bool, "skip-release-safe", "Main test suite skips release-safe builds") orelse skip_release; const skip_non_native = b.option(bool, "skip-non-native", "Main test suite skips non-native builds") orelse false; + const skip_cross_glibc = b.option(bool, "skip-cross-glibc", "Main test suite skips builds that require cross glibc") orelse false; const skip_libc = b.option(bool, "skip-libc", "Main test suite skips tests that link libc") orelse false; const skip_single_threaded = b.option(bool, "skip-single-threaded", "Main test suite skips tests that are single-threaded") orelse false; const skip_stage1 = b.option(bool, "skip-stage1", "Main test suite skips stage1 compile error tests") orelse false; @@ -351,6 +352,7 @@ pub fn build(b: *std.Build) !void { test_cases_options.addOption(bool, "enable_logging", enable_logging); test_cases_options.addOption(bool, "enable_link_snapshots", enable_link_snapshots); test_cases_options.addOption(bool, "skip_non_native", skip_non_native); + test_cases_options.addOption(bool, "skip_cross_glibc", skip_cross_glibc); test_cases_options.addOption(bool, "skip_stage1", skip_stage1); test_cases_options.addOption(bool, "have_llvm", enable_llvm); test_cases_options.addOption(bool, "llvm_has_m68k", llvm_has_m68k); @@ -415,6 +417,7 @@ pub fn build(b: *std.Build) !void { .optimize_modes = optimization_modes, .skip_single_threaded = skip_single_threaded, .skip_non_native = skip_non_native, + .skip_cross_glibc = skip_cross_glibc, .skip_libc = skip_libc, .skip_stage1 = skip_stage1, .skip_stage2 = skip_stage2_tests, @@ -429,6 +432,7 @@ pub fn build(b: *std.Build) !void { .optimize_modes = optimization_modes, .skip_single_threaded = true, .skip_non_native = skip_non_native, + .skip_cross_glibc = skip_cross_glibc, .skip_libc = true, .skip_stage1 = skip_stage1, .skip_stage2 = true, // TODO get all these passing @@ -442,6 +446,7 @@ pub fn build(b: *std.Build) !void { .optimize_modes = optimization_modes, .skip_single_threaded = true, .skip_non_native = skip_non_native, + .skip_cross_glibc = skip_cross_glibc, .skip_libc = true, .skip_stage1 = skip_stage1, .skip_stage2 = true, // TODO get all these passing @@ -473,6 +478,7 @@ pub fn build(b: *std.Build) !void { .optimize_modes = optimization_modes, .skip_single_threaded = skip_single_threaded, .skip_non_native = skip_non_native, + .skip_cross_glibc = skip_cross_glibc, .skip_libc = skip_libc, .skip_stage1 = skip_stage1, .skip_stage2 = true, // TODO get all these passing |
