mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-06 13:54:21 +00:00
compiler-rt: Fix some exports for *-windows-none.
This commit is contained in:
parent
7cae6b8fa7
commit
358ee859ba
4 changed files with 8 additions and 3 deletions
|
|
@ -260,7 +260,7 @@ comptime {
|
|||
_ = @import("compiler_rt/ssp.zig");
|
||||
}
|
||||
|
||||
if (!builtin.link_libc and builtin.abi == .msvc) {
|
||||
if (!builtin.link_libc and builtin.os.tag == .windows and (builtin.abi == .none or builtin.abi == .msvc)) {
|
||||
@export(&_fltused, .{ .name = "_fltused", .linkage = common.linkage, .visibility = common.visibility });
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ const common = @import("common.zig");
|
|||
pub const panic = common.panic;
|
||||
|
||||
comptime {
|
||||
if (arch == .x86 and os == .windows and (abi == .msvc or abi == .itanium) and !builtin.link_libc) {
|
||||
if (arch == .x86 and common.want_windows_msvc_or_itanium_abi and !builtin.link_libc) {
|
||||
// Don't let LLVM apply the stdcall name mangling on those MSVC builtins
|
||||
@export(&_alldiv, .{ .name = "\x01__alldiv", .linkage = common.linkage, .visibility = common.visibility });
|
||||
@export(&_aulldiv, .{ .name = "\x01__aulldiv", .linkage = common.linkage, .visibility = common.visibility });
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ const common = @import("common.zig");
|
|||
pub const panic = common.panic;
|
||||
|
||||
comptime {
|
||||
if (arch == .x86 and os == .windows and (abi == .msvc or abi == .itanium) and !builtin.link_libc) {
|
||||
if (arch == .x86 and common.want_windows_msvc_or_itanium_abi and !builtin.link_libc) {
|
||||
// Don't let LLVM apply the stdcall name mangling on those MSVC builtins
|
||||
@export(&_allrem, .{ .name = "\x01__allrem", .linkage = common.linkage, .visibility = common.visibility });
|
||||
@export(&_aullrem, .{ .name = "\x01__aullrem", .linkage = common.linkage, .visibility = common.visibility });
|
||||
|
|
|
|||
|
|
@ -52,6 +52,11 @@ pub const want_aeabi = switch (builtin.abi) {
|
|||
// Temporarily used for thumb-uefi until https://github.com/ziglang/zig/issues/21630 is addressed.
|
||||
pub const want_windows_arm_abi = builtin.cpu.arch.isArm() and (builtin.os.tag == .windows or builtin.os.tag == .uefi) and (builtin.abi.isGnu() or !builtin.link_libc);
|
||||
|
||||
pub const want_windows_msvc_or_itanium_abi = switch (builtin.abi) {
|
||||
.none, .msvc, .itanium => builtin.os.tag == .windows,
|
||||
else => false,
|
||||
};
|
||||
|
||||
pub const want_ppc_abi = builtin.cpu.arch.isPowerPC();
|
||||
|
||||
pub const want_float_exceptions = !builtin.cpu.arch.isWasm();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue