rucene icon indicating copy to clipboard operation
rucene copied to clipboard

unable to build from source on toolchain recommendation

Open mooreniemi opened this issue 4 years ago • 4 comments

Failing to build on latest nightly, but also when using rustup run nightly-2019-10-28 cargo build:

error[E0658]: `cfg(doctest)` is experimental and subject to change
  --> /Users/amooren/.cargo/registry/src/github.com-1ecc6299db9ec823/memoffset-0.5.6/src/lib.rs:74:7
   |
74 | #[cfg(doctest)]
   |       ^^^^^^^
   |
   = note: for more information, see https://github.com/rust-lang/rust/issues/62210
   = help: add `#![feature(cfg_doctest)]` to the crate attributes to enable

error[E0658]: `cfg(doctest)` is experimental and subject to change
  --> /Users/amooren/.cargo/registry/src/github.com-1ecc6299db9ec823/memoffset-0.5.6/src/lib.rs:77:7
   |
77 | #[cfg(doctest)]
   |       ^^^^^^^
   |
   = note: for more information, see https://github.com/rust-lang/rust/issues/62210
   = help: add `#![feature(cfg_doctest)]` to the crate attributes to enable

error: aborting due to 2 previous errors

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

Looks correct to me?

rustc --version
rustc 1.40.0-nightly (95f437b3c 2019-10-27)

mooreniemi avatar Oct 02 '20 18:10 mooreniemi

Based on https://github.com/zhihu/rucene/issues/1 looking to see if I can use memoffset 0.2.1 and that fixes it.

mooreniemi avatar Oct 02 '20 18:10 mooreniemi

I don't see a branch for https://github.com/Gilnaa/memoffset that would allow me to take 0.2.1 easily. I tried taking crossbeam = "0.4" and was able to avoid memoffset but of course this is too old and breaks other things.

mooreniemi avatar Oct 02 '20 19:10 mooreniemi

I ended up editing the locale file in memoffset to add #![feature(cfg_doctest)] and build succeeded. Maybe I should close this and reopen in memoffset repo?

mooreniemi avatar Oct 02 '20 19:10 mooreniemi

I ended up editing the locale file in memoffset to add #![feature(cfg_doctest)] and build succeeded. Maybe I should close this and reopen in memoffset repo?

hi, we have synced the toolchain using in prod. rustc --version rustc 1.43.0-nightly (c20d7eecb 2020-03-11)

jtong11 avatar Oct 13 '20 02:10 jtong11