Set target_family="wasm" for wasm targets
This commit is contained in:
parent
4afea69090
commit
1a491e2304
4 changed files with 9 additions and 5 deletions
|
@ -1046,7 +1046,7 @@ pub struct TargetOptions {
|
|||
///
|
||||
/// Common options are: "unix", "windows". Defaults to no families.
|
||||
///
|
||||
/// See https://doc.rust-lang.org/reference/conditional-compilation.html#target_family
|
||||
/// See <https://doc.rust-lang.org/reference/conditional-compilation.html#target_family>.
|
||||
pub families: Vec<String>,
|
||||
/// Whether the target toolchain's ABI supports returning small structs as an integer.
|
||||
pub abi_return_struct_as_int: bool,
|
||||
|
|
|
@ -61,6 +61,7 @@ pub fn options() -> TargetOptions {
|
|||
|
||||
TargetOptions {
|
||||
is_like_wasm: true,
|
||||
families: vec!["wasm".to_string()],
|
||||
|
||||
// we allow dynamic linking, but only cdylibs. Basically we allow a
|
||||
// final library artifact that exports some symbols (a wasm module) but
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue