openrr / urdf-viz

visualize URDF/XACRO file, URDF Viewer works on Windows/MacOS/Linux
Apache License 2.0
438 stars 54 forks source link

Installation fails on Ubuntu Focal 20.04 #54

Closed antoan closed 3 years ago

antoan commented 3 years ago

CPU: Quad Core Intel Core i7-2600K Kernel: 5.8.0-43-generic x86_64 Shell: zsh 5.8 inxi: 3.0.38

cargo install urdf-viz fails with the following errors:


error[E0658]: unions with non-`Copy` fields are unstable
  --> /home/tony/.cargo/registry/src/github.com-1ecc6299db9ec823/slotmap-1.0.2/src/basic.rs:19:1
   |
19 | / union SlotUnion<T> {
20 | |     value: ManuallyDrop<T>,
21 | |     next_free: u32,
22 | | }
   | |_^
   |
   = note: see issue #55149 <https://github.com/rust-lang/rust/issues/55149> for more information

error[E0658]: unions with non-`Copy` fields are unstable
  --> /home/tony/.cargo/registry/src/github.com-1ecc6299db9ec823/slotmap-1.0.2/src/hop.rs:39:1
   |
39 | / union SlotUnion<T> {
40 | |     value: ManuallyDrop<T>,
41 | |     free: FreeListEntry,
42 | | }
   | |_^
   |
   = note: see issue #55149 <https://github.com/rust-lang/rust/issues/55149> for more information

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0658`.
The following warnings were emitted during compilation:

warning: slotmap requires rustc => 1.49.0

error: could not compile `slotmap`.

To learn more, run the command again with --verbose.
warning: build failed, waiting for other jobs to finish...
error: failed to compile `urdf-viz v0.25.0`, intermediate artifacts can be found at `/tmp/cargo-installMA9D45`

$rustc --explain E0658


An unstable feature was used.

Erroneous code example:

#[repr(u128)] // error: use of unstable library feature 'repr128'
enum Foo {
    Bar(u64),
}

If you're using a stable or a beta version of rustc, you won't be able to use
any unstable features. In order to do so, please switch to a nightly version of
rustc (by using rustup).

If you're using a nightly version of rustc, just add the corresponding feature
to be able to use it:

#![feature(repr128)]

#[repr(u128)] // ok!
enum Foo {
    Bar(u64),
}
taiki-e commented 3 years ago

warning: slotmap requires rustc => 1.49.0

You have to use Rust 1.49 or later as the warning says.

antoan commented 3 years ago

I see, thank you.