exa: `cargo install exa` fails on rust 1.61.0
cargo install exa fails on fresh Ubuntu 22.04 Installation. On a recently installed machine, it worked. What am I missing?
Update: Installing from git on the same machine using cargo install --release works.
If it’s a crash, please include the full text of the crash that gets printed to the screen. If you’re seeing unexpected behaviour, a screenshot of the issue will help a lot.
$ cargo install exa
Updating crates.io index
Installing exa v0.10.1
Compiling libc v0.2.126
Compiling pkg-config v0.3.25
Compiling tinyvec_macros v0.1.0
Compiling unicode-width v0.1.9
Compiling matches v0.1.9
Compiling log v0.4.17
Compiling unicode-bidi v0.3.8
Compiling cfg-if v1.0.0
Compiling percent-encoding v2.1.0
Compiling byteorder v1.4.3
Compiling bitflags v1.3.2
Compiling scoped_threadpool v0.1.9
Compiling number_prefix v0.4.0
Compiling natord v1.0.9
Compiling lazy_static v1.4.0
Compiling glob v0.3.0
Compiling ansi_term v0.12.1
Compiling tinyvec v1.6.0
Compiling pad v0.1.6
Compiling term_grid v0.1.7
Compiling form_urlencoded v1.0.1
Compiling jobserver v0.1.24
Compiling locale v0.2.2
Compiling unicode-normalization v0.1.19
Compiling num_cpus v1.13.1
Compiling users v0.11.0
Compiling term_size v0.3.2
Compiling cc v1.0.73
Compiling datetime v0.5.2
Compiling zoneinfo_compiled v0.5.1
Compiling exa v0.10.1
Compiling idna v0.2.3
Compiling libz-sys v1.1.6
Compiling libgit2-sys v0.12.26+1.3.0
Compiling url v2.2.2
Compiling git2 v0.13.25
error: could not compile `exa`
Caused by:
process didn't exit successfully: `rustc --crate-name exa --edition=2018 /home/nuky/.cargo/registry/src/github.com-1ecc6299db9ec823/exa-0.10.1/src/main.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C opt-level=3 -C lto --cfg 'feature="default"' --cfg 'feature="git"' --cfg 'feature="git2"' -C metadata=1ce0c9a27006a300 -C extra-filename=-1ce0c9a27006a300 --out-dir /tmp/cargo-install5JSrtn/release/deps -L dependency=/tmp/cargo-install5JSrtn/release/deps --extern ansi_term=/tmp/cargo-install5JSrtn/release/deps/libansi_term-7a2f5b24394af86a.rlib --extern datetime=/tmp/cargo-install5JSrtn/release/deps/libdatetime-6916874f0cd40e2f.rlib --extern git2=/tmp/cargo-install5JSrtn/release/deps/libgit2-adccec571f115ad4.rlib --extern glob=/tmp/cargo-install5JSrtn/release/deps/libglob-023a5ddb3e769dc1.rlib --extern lazy_static=/tmp/cargo-install5JSrtn/release/deps/liblazy_static-d41ca21dec8b0771.rlib --extern libc=/tmp/cargo-install5JSrtn/release/deps/liblibc-699b121c119cf89f.rlib --extern locale=/tmp/cargo-install5JSrtn/release/deps/liblocale-d17442f3bd4d293c.rlib --extern log=/tmp/cargo-install5JSrtn/release/deps/liblog-b7e9159025711fc8.rlib --extern natord=/tmp/cargo-install5JSrtn/release/deps/libnatord-f4d9ddd248c87024.rlib --extern num_cpus=/tmp/cargo-install5JSrtn/release/deps/libnum_cpus-324722fbaed9d5db.rlib --extern number_prefix=/tmp/cargo-install5JSrtn/release/deps/libnumber_prefix-7efb1d77d0543926.rlib --extern scoped_threadpool=/tmp/cargo-install5JSrtn/release/deps/libscoped_threadpool-a2cf35eaa1a14f8a.rlib --extern term_grid=/tmp/cargo-install5JSrtn/release/deps/libterm_grid-1ab9843592eac954.rlib --extern term_size=/tmp/cargo-install5JSrtn/release/deps/libterm_size-745601c4cec2b307.rlib --extern unicode_width=/tmp/cargo-install5JSrtn/release/deps/libunicode_width-0096a1d028fe53c1.rlib --extern users=/tmp/cargo-install5JSrtn/release/deps/libusers-b95ed63432d62fd8.rlib --extern zoneinfo_compiled=/tmp/cargo-install5JSrtn/release/deps/libzoneinfo_compiled-29640f2a94be6951.rlib --cap-lints allow -L native=/tmp/cargo-install5JSrtn/release/build/libgit2-sys-6db745f6ace2f021/out/build` (signal: 8, SIGFPE: erroneous arithmetic operation)
error: failed to compile `exa v0.10.1`, intermediate artifacts can be found at `/tmp/cargo-install5JSrtn`
- Your operating system and hardware platform
$ screenfetch
./+o+- nuky@hobel
yyyyy- -yyyyyy+ OS: Ubuntu 22.04 jammy
://+//////-yyyyyyo Kernel: x86_64 Linux 5.15.0-10025-tuxedo
.++ .:/++++++/-.+sss/` Uptime: 1h 17m
.:++o: /++++++++/:--:/- Packages: 2067
o:+o+:++.`..```.-/oo+++++/ Shell: zsh 5.8.1
.:+o:+o/. `+sssoo+/ Resolution: 5360x1440
.++/+:+oo+o:` /sssooo. DE: GNOME 41.4
/+++//+:`oo+o /::--:. WM: Mutter
\+/+o+++`o++o ++////. WM Theme: Adwaita
.++.o+++oo+:` /dddhhh. GTK Theme: Yaru-dark [GTK2/3]
.+.o+oo:. `oddhhhh+ Icon Theme: Yaru
\+.++o+o``-````.:ohdhhhhh+ Font: Ubuntu 11
`:o+++ `ohhhhhhhhyo++os: Disk: 39G / 1.8T (3%)
.o:`.syhhhhhhh/.oo++o` CPU: AMD Ryzen 7 4800H with Radeon Graphics @ 16x 2.9GHz
/osyyyyyyo++ooo+++/ GPU: AMD RENOIR (LLVM 13.0.1, DRM 3.42, 5.15.0-10025-tuxedo)
````` +oo+++o\: RAM: 6250MiB / 62211MiB
`oo++.
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 13
- Comments: 23 (1 by maintainers)
This is fixed with rust 1.62.0 from 2022-06-27 (public available since 2022-06-30).
The problem is still present with current rust versions. I’ve tried building exa in (K)Ubuntu 22.04 using rust 1.65 and got the known error message
signal: 8, SIGFPE: erroneous arithmetic operationThe build process completes without this bug if either --release is omitted or lto is disabled.
People should also try the nightly toolchain build via rustup – As mentioned previously, I was able to skirt the issue on mac with this. https://www.oreilly.com/library/view/rust-programming-by/9781788390637/e07dc768-de29-482e-804b-0274b4bef418.xhtml
I really don’t think more “+1s” are needed. As explained above, the issue is in the Rust binaries for 1.61. It’s not actually an issue in exa.
Getting the same error too
how do i update rust and cargo version?
https://github.com/rust-lang/rust/issues/97255 downstream gentoo bug: https://bugs.gentoo.org/847421
in gentoo we’ve added those 2 patches on top of 1.61.0 and it fixes the problem
I think it’s the first one https://github.com/llvm/llvm-project/issues/54413 , but I added second patch too anyway.
too bad we can’t patch released tarball of 1.61.0.
Same issue on a freshly installed Windows 11 / WSL2, looking forward to a fix: