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

Failed to compile on Mac OS #37

Open
jqmichael opened this issue Nov 10, 2020 · 2 comments
Open

Failed to compile on Mac OS #37

jqmichael opened this issue Nov 10, 2020 · 2 comments

Comments

@jqmichael
Copy link

Added dependency on rio on MacOS 10.14.6.

[dependencies]
rio = "0.9.4"

With cargo 1.47.0, cargo check failed with the error message below:

   Compiling libc v0.2.80
    Checking rio v0.9.4
error[E0432]: unresolved imports `super::io_uring`, `super::Uring`
  --> /Users/juqing/.cargo/registry/src/github.com-1ecc6299db9ec823/rio-0.9.4/src/completion.rs:11:5
   |
11 |     io_uring::io_uring_cqe, FromCqe, Measure, Uring, M,
   |     ^^^^^^^^                                  ^^^^^ no `Uring` in the root
   |     |
   |     maybe a missing crate `io_uring`?

error[E0433]: failed to resolve: use of undeclared type or module `Config`
   --> /Users/juqing/.cargo/registry/src/github.com-1ecc6299db9ec823/rio-0.9.4/src/lib.rs:219:5
    |
219 |     Config::default().start()
    |     ^^^^^^ use of undeclared type or module `Config`

error[E0433]: failed to resolve: use of undeclared type or module `io_uring`
   --> /Users/juqing/.cargo/registry/src/github.com-1ecc6299db9ec823/rio-0.9.4/src/lib.rs:298:22
    |
298 |     fn from_cqe(cqe: io_uring::io_uring_cqe) -> Self;
    |                      ^^^^^^^^ use of undeclared type or module `io_uring`

error[E0433]: failed to resolve: use of undeclared type or module `io_uring`
   --> /Users/juqing/.cargo/registry/src/github.com-1ecc6299db9ec823/rio-0.9.4/src/lib.rs:302:22
    |
302 |     fn from_cqe(cqe: io_uring::io_uring_cqe) -> usize {
    |                      ^^^^^^^^ use of undeclared type or module `io_uring`

error[E0433]: failed to resolve: use of undeclared type or module `io_uring`
   --> /Users/juqing/.cargo/registry/src/github.com-1ecc6299db9ec823/rio-0.9.4/src/lib.rs:309:20
    |
309 |     fn from_cqe(_: io_uring::io_uring_cqe) {}
    |                    ^^^^^^^^ use of undeclared type or module `io_uring`

error[E0412]: cannot find type `Rio` in this scope
   --> /Users/juqing/.cargo/registry/src/github.com-1ecc6299db9ec823/rio-0.9.4/src/lib.rs:218:28
    |
218 | pub fn new() -> io::Result<Rio> {
    |           -                ^^^ not found in this scope
    |           |
    |           help: you might be missing a type parameter: `<Rio>`

error[E0282]: type annotations needed
  --> /Users/juqing/.cargo/registry/src/github.com-1ecc6299db9ec823/rio-0.9.4/src/completion.rs:25:19
   |
25 |             item: None,
   |                   ^^^^ cannot infer type for type parameter `T` declared on the enum `Option`

error: aborting due to 7 previous errors
@tekjar
Copy link

tekjar commented Nov 11, 2020

@jqmichael iouring is linux specific

@jqmichael
Copy link
Author

Thanks @tekjar. I can totally understand if it failed to run at run time. But I'm a little surprised it failed to compile.

Was there a Rust feature that I can tweak to make it compile on Mac?

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