Skip to content

Commit 1ce8b02

Browse files
committed
build-script: Copy libclang_rt.a from the host toolchain for visionOS.
During the toolchain build, when building the Swift standard library for platforms other than macOS the `libclang_rt.a` needs to be copied out of the host SDK. That wasn't happening for visionOS. Resolves rdar://135023111.
1 parent f001732 commit 1ce8b02

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

stdlib/public/core/Availability.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ import SwiftShims
3737
/// interpreter doesn't currently know how to load symbols from compiler-rt.
3838
/// Since `@_transparent` is only necessary for iOS apps, we only apply it on
3939
/// iOS, not any other which would inherit/remap iOS availability.
40-
#if os(iOS) && !os(xrOS)
40+
#if os(iOS) && !os(visionOS)
4141
@_effects(readnone)
4242
@_transparent
4343
public func _stdlib_isOSVersionAtLeast(

utils/swift_build_support/swift_build_support/products/llvm.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def copy_embedded_compiler_rt_builtins_from_darwin_host_toolchain(
134134
' into the local clang build directory {}.'.format(
135135
host_cxx_builtins_dir, dest_builtins_dir))
136136

137-
for _os in ['ios', 'watchos', 'tvos']:
137+
for _os in ['ios', 'watchos', 'tvos', 'xros']:
138138
# Copy over the device .a when necessary
139139
lib_name = 'libclang_rt.{}.a'.format(_os)
140140
host_lib_path = os.path.join(host_cxx_builtins_dir, lib_name)

0 commit comments

Comments
 (0)