Skip to content

Commit 3ed0131

Browse files
Add an escape hatch for the linker validation
1 parent afccbef commit 3ed0131

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/ruby_wasm/packager/core.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ def link_exts(executor, build)
125125
linker = RubyWasmExt::ComponentLink.new
126126
linker.use_built_in_libdl(true)
127127
linker.stub_missing_functions(false)
128-
linker.validate(true)
128+
linker.validate(ENV["RUBYWASM_SKIP_LINKER_VALIDATION"] != "1")
129129

130130
libraries.each do |lib|
131131
# Non-DL openable libraries should be referenced as base name
@@ -305,7 +305,7 @@ def build_and_link_exts(executor, module_bytes)
305305
return module_bytes unless @packager.features.support_component_model?
306306

307307
linker = RubyWasmExt::ComponentEncode.new
308-
linker.validate(true)
308+
linker.validate(ENV["RUBYWASM_SKIP_LINKER_VALIDATION"] != "1")
309309
linker.module(module_bytes)
310310
linker.adapter(
311311
"wasi_snapshot_preview1",

0 commit comments

Comments
 (0)