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

how is lapce-rust compiled #2

Open
SingingBush opened this issue Mar 18, 2022 · 3 comments
Open

how is lapce-rust compiled #2

SingingBush opened this issue Mar 18, 2022 · 3 comments

Comments

@SingingBush
Copy link

I cloned this repo so I can look into writing a new plugin but the project won't build with cargo build as due to missing the crate for core. What steps are being used to build the rust plugin? Will the core of lapce be published to crates.io?

Relates to lapce/lapce#123

@dzhou121
Copy link
Contributor

It depends on lapce-plugin which is on crates.io. It doesn't depend on lapce core.

@SingingBush
Copy link
Author

I see this in build output:

$ cargo build
   Compiling cfg-if v1.0.0
   Compiling itoa v1.0.1
   Compiling adler v1.0.2
   Compiling ryu v1.0.9
   Compiling proc-macro2 v1.0.34
   Compiling syn v1.0.82
   Compiling serde_derive v1.0.132
   Compiling serde v1.0.132
   Compiling miniz_oxide v0.4.4
   Compiling libc v0.2.112
   Compiling crc32fast v1.3.0
   Compiling serde_json v1.0.73
error[E0463]: can't find crate for `core`
  |
  = note: the `wasm32-wasi` target may not be installed
  = help: consider downloading the target with `rustup target add wasm32-wasi`

error[E0463]: can't find crate for `compiler_builtins`

error[E0463]: can't find crate for `core`
  --> /home/samael/.cargo/registry/src/github.com-1ecc6299db9ec823/adler-1.0.2/src/lib.rs:20:1
   |
20 | extern crate core as std;
   | ^^^^^^^^^^^^^^^^^^^^^^^^^ can't find crate
   |
   = note: the `wasm32-wasi` target may not be installed
   = help: consider downloading the target with `rustup target add wasm32-wasi`

For more information about this error, try `rustc --explain E0463`.
error: cannot find attribute `derive` in this scope
  --> /home/samael/.cargo/registry/src/github.com-1ecc6299db9ec823/adler-1.0.2/src/lib.rs:86:3
   |
86 | #[derive(Debug, Copy, Clone)]
   |   ^^^^^^

...

@dzhou121
Copy link
Contributor

It's supposedly to be compiled to WASI so you need to rustup target add wasm32-wasi

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

No branches or pull requests

2 participants