Skip to content

Commit c525204

Browse files
authored
Being more flexible in when not to explicitly set the sysroot when compiling for WASI (GH-142242)
1 parent 547d8da commit c525204

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
@@ -271,7 +271,7 @@ def wasi_sdk_env(context):
271271
for env_var, binary_name in list(env.items()):
272272
env[env_var] = os.fsdecode(wasi_sdk_path / "bin" / binary_name)
273273

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

0 commit comments

Comments
 (0)