Skip to content

Commit d3a9093

Browse files
respect LIB_WASI_VFS_A if defined
1 parent 6b4c96d commit d3a9093

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

lib/ruby_wasm/build_system/product/crossruby.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,8 @@ def with_zlib(zlib)
167167

168168
def with_wasi_vfs(wasi_vfs)
169169
@wasi_vfs = wasi_vfs
170-
@dep_tasks << wasi_vfs.install_task
170+
install_task = wasi_vfs.install_task
171+
@dep_tasks << install_task if install_task
171172
end
172173

173174
def dest_dir

lib/ruby_wasm/build_system/product/wasi_vfs.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,15 @@ def lib_product_build_dir
2020
end
2121

2222
def lib_wasi_vfs_a
23-
File.join(lib_product_build_dir, "libwasi_vfs.a")
23+
ENV["LIB_WASI_VFS_A"] || File.join(lib_product_build_dir, "libwasi_vfs.a")
2424
end
2525

2626
def name
2727
lib_product_build_dir
2828
end
2929

3030
def define_task
31+
return if ENV["LIB_WASI_VFS_A"]
3132
@install_task =
3233
file(lib_wasi_vfs_a) do
3334
require "tmpdir"

0 commit comments

Comments
 (0)