Skip to content

Commit afaa3b0

Browse files
[3.14] Being more flexible in when not to explicitly set the sysroot when compiling for WASI (GH-142242) (GH-142246)
Being more flexible in when not to explicitly set the sysroot when compiling for WASI (GH-142242) (cherry picked from commit c525204) Co-authored-by: Brett Cannon <[email protected]>
1 parent 319c6a2 commit afaa3b0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Tools/wasm/wasi/__main__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ def wasi_sdk_env(context):
269269
for env_var, binary_name in list(env.items()):
270270
env[env_var] = os.fsdecode(wasi_sdk_path / "bin" / binary_name)
271271

272-
if wasi_sdk_path != pathlib.Path("/opt/wasi-sdk"):
272+
if not wasi_sdk_path.name.startswith("wasi-sdk"):
273273
for compiler in ["CC", "CPP", "CXX"]:
274274
env[compiler] += f" --sysroot={sysroot}"
275275

0 commit comments

Comments
 (0)