diff options
| author | Jakub Konka <kubkon@jakubkonka.com> | 2024-05-09 15:04:13 +0200 |
|---|---|---|
| committer | Jakub Konka <kubkon@jakubkonka.com> | 2024-05-09 15:04:15 +0200 |
| commit | 2e1fc0dd14c2897cd6fb4ff433bff2e5297272cb (patch) | |
| tree | 342325fd62cc47755cf1dddf7305365d298f6fe6 /lib/compiler/aro | |
| parent | 8f202ba7c7c446da9dff4b9ca2bbfb5b21c0aa18 (diff) | |
| download | zig-2e1fc0dd14c2897cd6fb4ff433bff2e5297272cb.tar.gz zig-2e1fc0dd14c2897cd6fb4ff433bff2e5297272cb.zip | |
handle visionos target OS tag in the compiler
* rename .xros to .visionos as agreed in the tracking issue
* add support for VisionOS platform in the MachO linker
Diffstat (limited to 'lib/compiler/aro')
| -rw-r--r-- | lib/compiler/aro/aro/Compilation.zig | 4 | ||||
| -rw-r--r-- | lib/compiler/aro/aro/target.zig | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/compiler/aro/aro/Compilation.zig b/lib/compiler/aro/aro/Compilation.zig index 8329ad4405..d6b9b91780 100644 --- a/lib/compiler/aro/aro/Compilation.zig +++ b/lib/compiler/aro/aro/Compilation.zig @@ -912,12 +912,12 @@ fn generateVaListType(comp: *Compilation) !Type { const kind: Kind = switch (comp.target.cpu.arch) { .aarch64 => switch (comp.target.os.tag) { .windows => @as(Kind, .char_ptr), - .ios, .macos, .tvos, .watchos => .char_ptr, + .ios, .macos, .tvos, .watchos, .visionos => .char_ptr, else => .aarch64_va_list, }, .sparc, .wasm32, .wasm64, .bpfel, .bpfeb, .riscv32, .riscv64, .avr, .spirv32, .spirv64 => .void_ptr, .powerpc => switch (comp.target.os.tag) { - .ios, .macos, .tvos, .watchos, .aix => @as(Kind, .char_ptr), + .ios, .macos, .tvos, .watchos, .visionos, .aix => @as(Kind, .char_ptr), else => return Type{ .specifier = .void }, // unknown }, .x86, .msp430 => .char_ptr, diff --git a/lib/compiler/aro/aro/target.zig b/lib/compiler/aro/aro/target.zig index dcb4777de6..62f9ffad1a 100644 --- a/lib/compiler/aro/aro/target.zig +++ b/lib/compiler/aro/aro/target.zig @@ -706,6 +706,7 @@ pub fn toLLVMTriple(target: std.Target, buf: []u8) []const u8 { .ios => "ios", .tvos => "tvos", .watchos => "watchos", + .visionos => "xros", .driverkit => "driverkit", .shadermodel => "shadermodel", .liteos => "liteos", |
