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

wasmer problem building on FreeBSD #1077

Closed
ghost opened this issue Feb 8, 2020 · 4 comments
Closed

wasmer problem building on FreeBSD #1077

ghost opened this issue Feb 8, 2020 · 4 comments

Comments

@ghost
Copy link

ghost commented Feb 8, 2020

Trying to build elrond-go on FreeBSD 11.3 I have problems building the ElrondNetwork fork of wasmer. I open the issue here because issues are disabled in the forked wasmer repo.

[user@idefix ~/wasmer]$ cargo build --release
.
.
.
error[E0425]: cannot find function `get_fault_info` in this scope
   --> lib/runtime-core/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

For more information about this error, try `rustc --explain E0425`.
error: could not compile `wasmer-runtime-core`.
warning: build failed, waiting for other jobs to finish...
error: build failed

This is with cargo rust 1.43.0-nightly because stable fails with error[E0554]: `#![feature]` may not be used on the stable release channel --> /home/stone/.cargo/registry/src/github.com-1ecc6299db9ec823/dynasm-0.5.2/sr c/lib.rs:1:1

@camilbancioiu
Copy link
Contributor

camilbancioiu commented Feb 9, 2020

We build Wasmer using the following command:

$ make capi

Make sure you have make installed.

Indeed, you need the nightly rustup channel to compile successfully. After the build succeeds, look for the file target/release/libwasmer_c_api.so. Copy this file into your local clone of arwen-wasm-vm, under the folder wasmer (thus replacing the one bundled with the repository).

Even if we don't support FreeBSD officially at the moment (focusing on Linux and MacOS), we'll definitely help you out to get your FreeBSD build running. Let us know how the build goes.

EDIT: As a clarification, running make capi will build Wasmer in its C API configuration, thus it will be a shared library, as opposed to an executable. The Elrond Node can only use Wasmer in this configuration.

@ghost
Copy link
Author

ghost commented Feb 9, 2020

Thanks for the hints! Building the Elrond fork of wasmer (master) with $ make capi gives the same error. Upstream wasmer recently merged a patch porting to FreeBSD but I don't know anything about rust so I didn't try merging that patch.
Due to a bug in nightly, building the blake3 dependency also fails right now. I could look for an older and working nightly but even if I could build libwasmer_c_api.so from upstream wasmer, I doubt it will work with arwen, right?

@camilbancioiu
Copy link
Contributor

camilbancioiu commented Feb 13, 2020

Looks like it will be solved when we will update our fork with the upstream Wasmer, which should allow you to compile on FreeBSD. While this update isn't planned for the immediate future (it's a non-trivial task and requires testing), we do want to keep our Wasmer fork up-to-date with the upstream. Stay tuned!

The upstream Wasmer is incompatible with Arwen. Our fork contains modifications required by Arwen and the Elrond Node.

@iulianpascalau
Copy link
Contributor

This should be fixed as of today 2020.05.15. Please open a new issue if the problem persist.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants