Skip to content

Commit f4b0261

Browse files
authored
Fix broken symlink in WebAssemblyRecipe.swift (#216)
`usr/lib/swift/clang/lib/wasi` directory doesn't exist in Swift SDKs for WASI, for `libclang_rt.*-wasm32.a` we should symlink to `../../../swift_static/clang/lib/wasi` instead.
1 parent d7264b7 commit f4b0261

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Sources/SwiftSDKGenerator/SwiftSDKRecipes/WebAssemblyRecipe.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,10 @@ package struct WebAssemblyRecipe: SwiftSDKRecipe {
200200
"usr/lib/swift/clang/lib/wasip1"
201201
)
202202

203-
try await generator.createSymlink(at: embeddedCompilerRTPath, pointingTo: "wasi")
203+
try await generator.createSymlink(
204+
at: embeddedCompilerRTPath,
205+
pointingTo: "../../../swift_static/clang/lib/wasi"
206+
)
204207

205208
// Copy the WASI sysroot into the SDK bundle.
206209
let sdkDirPath = pathsConfiguration.swiftSDKRootPath.appending("WASI.sdk")

0 commit comments

Comments
 (0)