@@ -806,37 +806,20 @@ class Wasm32WASIBuild(UnixCrossBuild):
806
806
"""wasm32-wasi builder
807
807
808
808
* WASI SDK >= 16 must be installed to default path /opt/wasi-sdk
809
- * WASIX must be installed to /opt/wasix
810
- * ccache must be installed
811
809
* wasmtime must be installed and on PATH
810
+ * Tools/wasm/wasi-env detects presence of WASIX and ccache
812
811
"""
813
812
buildersuffix = ".wasi"
814
813
factory_tags = ["wasm" , "wasi" ]
815
814
extra_configure_flags = [
816
815
# debug builds exhaust the limited call stack on WASI
817
816
"--without-pydebug" ,
818
- # ipv6 is not supported on WASI
819
- "--disable-ipv6" ,
820
817
]
821
- wasi_sdk = "/opt/wasi-sdk"
822
- wasi_sysroot = f"{ wasi_sdk } /share/wasi-sysroot"
823
- wasix = "/opt/wasix"
824
818
compile_environ = {
825
819
"CONFIG_SITE" : "../../Tools/wasm/config.site-wasm32-wasi" ,
826
- # use Clang from WASI-SDK
827
- "CC" : f"ccache { wasi_sdk } /bin/clang" ,
828
- "LDSHARED" : f"{ wasi_sdk } /bin/wasm-ld" ,
829
- "AR" : f"{ wasi_sdk } /bin/llvm-ar" ,
830
- # use WASIX library with POSIX stubs
831
- "CFLAGS" : f"-isystem { wasix } /include" ,
832
- "LDFLAGS" : f"-L{ wasix } /lib -lwasix" ,
833
- # WASI-SDK does not have a 'wasm32-unknown-wasi-pkg-config' script
834
- # force pkg-config into cross-compiling mode
835
- "PKG_CONFIG_PATH" : "" ,
836
- "PKG_CONFIG_SYSROOT_DIR" : wasi_sysroot ,
837
- "PKG_CONFIG_LIBDIR" : f"{ wasi_sysroot } /lib/pkgconfig:{ wasi_sysroot } /share/pkgconfig" ,
838
820
}
839
821
host = "wasm32-unknown-wasi"
822
+ host_configure_cmd = ["../../Tools/wasm/wasi-env" , "../../configure" ]
840
823
841
824
def setup (self , parallel , branch , test_with_PTY = False , ** kwargs ):
842
825
self .addStep (
0 commit comments