mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 06:13:07 +00:00
test: remove -Dskip-translate-c from test-standalone
No longer necessary since we've stopped using Clang for this.
This commit is contained in:
parent
2a88a6a456
commit
17f9a25924
@ -9,7 +9,6 @@ pub fn build(b: *std.Build) void {
|
|||||||
const enable_macos_sdk = b.option(bool, "enable_macos_sdk", "Run tests requiring presence of macOS SDK and frameworks") orelse enable_ios_sdk;
|
const enable_macos_sdk = b.option(bool, "enable_macos_sdk", "Run tests requiring presence of macOS SDK and frameworks") orelse enable_ios_sdk;
|
||||||
const enable_symlinks_windows = b.option(bool, "enable_symlinks_windows", "Run tests requiring presence of symlinks on Windows") orelse false;
|
const enable_symlinks_windows = b.option(bool, "enable_symlinks_windows", "Run tests requiring presence of symlinks on Windows") orelse false;
|
||||||
const omit_symlinks = builtin.os.tag == .windows and !enable_symlinks_windows;
|
const omit_symlinks = builtin.os.tag == .windows and !enable_symlinks_windows;
|
||||||
const skip_translate_c = b.option(bool, "skip_translate_c", "Test suite skips translate-c tests") orelse false;
|
|
||||||
|
|
||||||
const simple_skip_debug = b.option(bool, "simple_skip_debug", "Simple tests skip debug builds") orelse false;
|
const simple_skip_debug = b.option(bool, "simple_skip_debug", "Simple tests skip debug builds") orelse false;
|
||||||
const simple_skip_release_safe = b.option(bool, "simple_skip_release_safe", "Simple tests skip release-safe builds") orelse false;
|
const simple_skip_release_safe = b.option(bool, "simple_skip_release_safe", "Simple tests skip release-safe builds") orelse false;
|
||||||
@ -21,7 +20,6 @@ pub fn build(b: *std.Build) void {
|
|||||||
.skip_release_safe = simple_skip_release_safe,
|
.skip_release_safe = simple_skip_release_safe,
|
||||||
.skip_release_fast = simple_skip_release_fast,
|
.skip_release_fast = simple_skip_release_fast,
|
||||||
.skip_release_small = simple_skip_release_small,
|
.skip_release_small = simple_skip_release_small,
|
||||||
.skip_translate_c = skip_translate_c,
|
|
||||||
});
|
});
|
||||||
const simple_dep_step = simple_dep.builder.default_step;
|
const simple_dep_step = simple_dep.builder.default_step;
|
||||||
simple_dep_step.name = "standalone_test_cases.simple";
|
simple_dep_step.name = "standalone_test_cases.simple";
|
||||||
@ -99,12 +97,9 @@ pub fn build(b: *std.Build) void {
|
|||||||
pkg.build_zig.requires_macos_sdk;
|
pkg.build_zig.requires_macos_sdk;
|
||||||
const requires_symlinks = @hasDecl(pkg.build_zig, "requires_symlinks") and
|
const requires_symlinks = @hasDecl(pkg.build_zig, "requires_symlinks") and
|
||||||
pkg.build_zig.requires_symlinks;
|
pkg.build_zig.requires_symlinks;
|
||||||
const requires_translate_c = @hasDecl(pkg.build_zig, "requires_translate_c") and
|
|
||||||
pkg.build_zig.requires_translate_c;
|
|
||||||
if ((requires_symlinks and omit_symlinks) or
|
if ((requires_symlinks and omit_symlinks) or
|
||||||
(requires_macos_sdk and !enable_macos_sdk) or
|
(requires_macos_sdk and !enable_macos_sdk) or
|
||||||
(requires_ios_sdk and !enable_ios_sdk) or
|
(requires_ios_sdk and !enable_ios_sdk))
|
||||||
(requires_translate_c and skip_translate_c))
|
|
||||||
{
|
{
|
||||||
continue :add_dep_steps;
|
continue :add_dep_steps;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,7 +1,5 @@
|
|||||||
const std = @import("std");
|
const std = @import("std");
|
||||||
|
|
||||||
pub const requires_translate_c = true;
|
|
||||||
|
|
||||||
pub fn build(b: *std.Build) void {
|
pub fn build(b: *std.Build) void {
|
||||||
const test_step = b.step("test", "Test it");
|
const test_step = b.step("test", "Test it");
|
||||||
b.default_step = test_step;
|
b.default_step = test_step;
|
||||||
|
|||||||
@ -1,8 +1,6 @@
|
|||||||
const std = @import("std");
|
const std = @import("std");
|
||||||
const builtin = @import("builtin");
|
const builtin = @import("builtin");
|
||||||
|
|
||||||
pub const requires_translate_c = true;
|
|
||||||
|
|
||||||
// To run executables linked against a specific glibc version, the
|
// To run executables linked against a specific glibc version, the
|
||||||
// run-time glibc version needs to be new enough. Check the host's glibc
|
// run-time glibc version needs to be new enough. Check the host's glibc
|
||||||
// version. Note that this does not allow for translation/vm/emulation
|
// version. Note that this does not allow for translation/vm/emulation
|
||||||
|
|||||||
@ -1,7 +1,5 @@
|
|||||||
const std = @import("std");
|
const std = @import("std");
|
||||||
|
|
||||||
pub const requires_translate_c = true;
|
|
||||||
|
|
||||||
pub fn build(b: *std.Build) void {
|
pub fn build(b: *std.Build) void {
|
||||||
const test_step = b.step("test", "Test it");
|
const test_step = b.step("test", "Test it");
|
||||||
b.default_step = test_step;
|
b.default_step = test_step;
|
||||||
|
|||||||
@ -9,7 +9,6 @@ pub fn build(b: *std.Build) void {
|
|||||||
const skip_release_safe = b.option(bool, "skip_release_safe", "Skip release-safe builds") orelse false;
|
const skip_release_safe = b.option(bool, "skip_release_safe", "Skip release-safe builds") orelse false;
|
||||||
const skip_release_fast = b.option(bool, "skip_release_fast", "Skip release-fast builds") orelse false;
|
const skip_release_fast = b.option(bool, "skip_release_fast", "Skip release-fast builds") orelse false;
|
||||||
const skip_release_small = b.option(bool, "skip_release_small", "Skip release-small builds") orelse false;
|
const skip_release_small = b.option(bool, "skip_release_small", "Skip release-small builds") orelse false;
|
||||||
const skip_translate_c = b.option(bool, "skip_translate_c", "Test suite skips translate-c tests") orelse false;
|
|
||||||
|
|
||||||
var optimize_modes_buf: [4]std.builtin.OptimizeMode = undefined;
|
var optimize_modes_buf: [4]std.builtin.OptimizeMode = undefined;
|
||||||
var optimize_modes_len: usize = 0;
|
var optimize_modes_len: usize = 0;
|
||||||
@ -37,7 +36,6 @@ pub fn build(b: *std.Build) void {
|
|||||||
if (case.os_filter) |os_tag| {
|
if (case.os_filter) |os_tag| {
|
||||||
if (os_tag != builtin.os.tag) continue;
|
if (os_tag != builtin.os.tag) continue;
|
||||||
}
|
}
|
||||||
if (case.uses_translate_c and skip_translate_c) continue;
|
|
||||||
|
|
||||||
const resolved_target = b.resolveTargetQuery(case.target);
|
const resolved_target = b.resolveTargetQuery(case.target);
|
||||||
|
|
||||||
@ -84,7 +82,6 @@ const Case = struct {
|
|||||||
is_exe: bool = true,
|
is_exe: bool = true,
|
||||||
/// Run only on this OS.
|
/// Run only on this OS.
|
||||||
os_filter: ?std.Target.Os.Tag = null,
|
os_filter: ?std.Target.Os.Tag = null,
|
||||||
uses_translate_c: bool = false,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const cases = [_]Case{
|
const cases = [_]Case{
|
||||||
@ -96,7 +93,6 @@ const cases = [_]Case{
|
|||||||
.src_path = "hello_world/hello_libc.zig",
|
.src_path = "hello_world/hello_libc.zig",
|
||||||
.link_libc = true,
|
.link_libc = true,
|
||||||
.all_modes = true,
|
.all_modes = true,
|
||||||
.uses_translate_c = true,
|
|
||||||
},
|
},
|
||||||
.{
|
.{
|
||||||
.src_path = "cat/main.zig",
|
.src_path = "cat/main.zig",
|
||||||
@ -112,10 +108,7 @@ const cases = [_]Case{
|
|||||||
.os_tag = .freestanding,
|
.os_tag = .freestanding,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
.{
|
.{ .src_path = "issue_12471/main.zig" },
|
||||||
.src_path = "issue_12471/main.zig",
|
|
||||||
.uses_translate_c = true,
|
|
||||||
},
|
|
||||||
.{ .src_path = "guess_number/main.zig" },
|
.{ .src_path = "guess_number/main.zig" },
|
||||||
.{ .src_path = "main_return_error/error_u8.zig" },
|
.{ .src_path = "main_return_error/error_u8.zig" },
|
||||||
.{ .src_path = "main_return_error/error_u8_non_zero.zig" },
|
.{ .src_path = "main_return_error/error_u8_non_zero.zig" },
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user