Make wasi_libc_sys a required dependency of roc_build to fix repl_test

This commit is contained in:
Brian Carroll 2022-05-04 22:33:07 +01:00
parent ad1d23d0a4
commit 58dc7a9635
2 changed files with 4 additions and 5 deletions

View file

@ -31,7 +31,7 @@ libloading = "0.7.1"
tempfile = "3.2.0" tempfile = "3.2.0"
inkwell = { path = "../../vendor/inkwell", optional = true } inkwell = { path = "../../vendor/inkwell", optional = true }
target-lexicon = "0.12.3" target-lexicon = "0.12.3"
wasi_libc_sys = { path = "../../wasi-libc-sys", optional = true } wasi_libc_sys = { path = "../../wasi-libc-sys" }
[target.'cfg(target_os = "macos")'.dependencies] [target.'cfg(target_os = "macos")'.dependencies]
serde_json = "1.0.69" serde_json = "1.0.69"
@ -41,7 +41,7 @@ target-arm = []
target-aarch64 = ["roc_gen_dev/target-aarch64"] target-aarch64 = ["roc_gen_dev/target-aarch64"]
target-x86 = [] target-x86 = []
target-x86_64 = ["roc_gen_dev/target-x86_64"] target-x86_64 = ["roc_gen_dev/target-x86_64"]
target-wasm32 = ["roc_gen_wasm", "wasi_libc_sys"] target-wasm32 = ["roc_gen_wasm"]
# This is a separate feature because when we generate docs on Netlify, # This is a separate feature because when we generate docs on Netlify,
# it doesn't have LLVM installed. (Also, it doesn't need to do code gen.) # it doesn't have LLVM installed. (Also, it doesn't need to do code gen.)

View file

@ -11,9 +11,8 @@ extern "C" {
pub fn memset(dst: *mut c_void, ch: i32, n: usize) -> *mut c_void; pub fn memset(dst: *mut c_void, ch: i32, n: usize) -> *mut c_void;
} }
// Tell users of this crate where to find the Wasm .a file
// If a non-Wasm target is using this crate, we assume it is a build script that wants to emit Wasm // If a non-Wasm target is using this crate, we assume it is a build script that wants to emit Wasm
// Tell it where to find the Wasm .a file // For Wasm target, it won't ever be used, but we expose it just to keep things simple
#[cfg(not(target_family = "wasm"))]
mod generated; mod generated;
#[cfg(not(target_family = "wasm"))]
pub use generated::WASI_LIBC_PATH; pub use generated::WASI_LIBC_PATH;