Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cross compilation, compilation error #1025

Closed
ghost opened this issue Dec 1, 2019 · 3 comments
Closed

Cross compilation, compilation error #1025

ghost opened this issue Dec 1, 2019 · 3 comments
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Dec 1, 2019

I'm cross compiling from x86_64-linux to armv7-linux-androideabi and aarch64-linux-android. If I don't cross compile, it works fine, but when I cross compile, I get these errors for aarch64-linux-android :

error[E0425]: cannot find function `get_fault_info` in this scope
   --> /home/mnur/.cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/wasmer-runtime-core-0.11.0/src/fault.rs:289:21
    |
289 |         let fault = get_fault_info(siginfo as _, ucontext);
    |                     ^^^^^^^^^^^^^^ not found in this scope

error: aborting due to previous error

And these for armv7-linux-androideabi:

error[E0425]: cannot find function `get_fault_info` in this scope
   --> /home/mnur/.cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/wasmer-runtime-core-0.11.0/src/fault.rs:289:21
    |
289 |         let fault = get_fault_info(siginfo as _, ucontext);
    |                     ^^^^^^^^^^^^^^ not found in this scope

error[E0425]: cannot find value `ARCH` in this scope
   --> /home/mnur/.cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/wasmer-runtime-core-0.11.0/src/fault.rs:294:82
    |
294 |                     let magic_size = if let Some(x) = get_inline_breakpoint_size(ARCH, v.backend) {
    |                                                                                  ^^^^ not found in this scope
help: possible candidate is found in another module, you can import it into scope
    |
30  | use std::env::consts::ARCH;
    |

error[E0425]: cannot find value `ARCH` in this scope
   --> /home/mnur/.cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/wasmer-runtime-core-0.11.0/src/fault.rs:303:29
    |
303 |                             ARCH,
    |                             ^^^^ not found in this scope
help: possible candidate is found in another module, you can import it into scope
    |
30  | use std::env::consts::ARCH;
    |

error: aborting due to 3 previous errors
echo "`wasmer -V` | `rustc -V` | `uname -m`"
wasmer 0.11.0 | rustc 1.39.0-nightly (9eae1fc0e 2019-08-23) | x86_64

Steps to reproduce

Created directory by defaults with cargo and added this to Cargo.toml

[lib]                                                                                               
name = "libwasmer"
crate_type = ["cdylib"]

[dependencies]
wasmer-runtime = "0.11.0"

and ran CC_aarch64_linux_android=$NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android28-clang cargo build --target aarch64-linux-android --release, similarly for arm7-android-abi

@ghost ghost added the bug Something isn't working label Dec 1, 2019
@ghost
Copy link
Author

ghost commented Dec 2, 2019

#1003 Possibly related

@syrusakbary
Copy link
Member

This should not affect wasmer master anymore. The code has evolved significantly since opening the issue

@ivanproskuryakov
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants