diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2023-03-13 23:41:41 -0700 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2023-03-15 10:48:15 -0700 |
| commit | 941cae4331ff4922ccef08a5d3d5879a0d1fa786 (patch) | |
| tree | 47e67ecc8ea5231850a45505af1081e62c38f6a3 /test | |
| parent | 22d94eaf32bc303ff757f442991f570b264b24c3 (diff) | |
| download | zig-941cae4331ff4922ccef08a5d3d5879a0d1fa786.tar.gz zig-941cae4331ff4922ccef08a5d3d5879a0d1fa786.zip | |
revert a change to C ABI tests
See tracking issue #14908
Diffstat (limited to 'test')
| -rw-r--r-- | test/tests.zig | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/test/tests.zig b/test/tests.zig index 76ea537bb2..7af1ba6c3b 100644 --- a/test/tests.zig +++ b/test/tests.zig @@ -1045,9 +1045,13 @@ pub fn addCAbiTests(b: *std.Build, skip_non_native: bool, skip_release: bool) *S } test_step.linkLibC(); test_step.addCSourceFile("test/c_abi/cfuncs.c", &.{"-std=c99"}); - // This test is intentionally trying to check if the external ABI is - // done properly. LTO would be a hindrance to this. - test_step.want_lto = false; + + // test-c-abi should test both with LTO on and with LTO off. Only + // some combinations are passing currently: + // https://github.com/ziglang/zig/issues/14908 + if (c_abi_target.isWindows() and (c_abi_target.getCpuArch() == .x86 or builtin.target.os.tag == .linux)) { + test_step.want_lto = false; + } const triple_prefix = c_abi_target.zigTriple(b.allocator) catch @panic("OOM"); test_step.setNamePrefix(b.fmt("{s}-{s}-{s} ", .{ |
