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

errors building xcb-imdkit-rs #2

Open
joh6nn opened this issue Dec 26, 2022 · 2 comments
Open

errors building xcb-imdkit-rs #2

joh6nn opened this issue Dec 26, 2022 · 2 comments

Comments

@joh6nn
Copy link

joh6nn commented Dec 26, 2022

I got the following errors when running cargo install --path ./vime

error[E0432]: unresolved import `std::ffi::c_char`
  --> xcb-imdkit-rs/src/lib.rs:15:16
   |
15 | use std::ffi::{c_char, c_void};
   |                ^^^^^^ no `c_char` in `ffi`

error[E0282]: type annotations needed
   --> xcb-imdkit-rs/src/lib.rs:345:46
    |
345 |                 self.inner.preedit_string as _,
    |                                              ^ cannot infer type
    |
    = note: type must be known at this point

error[E0658]: use of unstable library feature 'box_into_pin'
   --> xcb-imdkit-rs/src/lib.rs:770:9
    |
770 |         Box::into_pin(im_server)
    |         ^^^^^^^^^^^^^
    |
    = note: see issue #62370 <https://github.com/rust-lang/rust/issues/62370> for more information

Some errors have detailed explanations: E0282, E0432, E0658.
For more information about an error, try `rustc --explain E0282`.
The following warnings were emitted during compilation:

warning: deps/xcb-imdkit/src/imdkit.c: In function ‘_xcb_im_init’:
warning: deps/xcb-imdkit/src/imdkit.c:248:5: warning: ignoring return value of ‘asprintf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
warning:   248 |     asprintf(&buf, "@server=%s", im->serverName);
warning:       |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

error: could not compile `xcb-imdkit` due to 3 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to compile `vime v0.1.0 (/home/joh6nn/Code/vime/vime)`, intermediate artifacts can be found at `/home/joh6nn/Code/vime/target
@algon-320
Copy link
Owner

Could you try it again with the latest Rust compiler (or version 1.65+) ?

If you are using rustup, you can switch the compliler by placing a "rust-toolchain" file with the content "1.65".

@joh6nn
Copy link
Author

joh6nn commented Dec 28, 2022

Yup, compiles successfully with rust 1.65 :)

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