compile error. stack overflow
SemElVik opened this issue · comments
- x86_64 /ubuntu 18.04
- rustc 1.32.0;
- gcc + clang;
- pkg-config;
- libusb (1.0+)
What can be caused by stack overflow?
cargo install tmkms --features=ledgertm
thread '<unknown>' has overflowed its stack
fatal runtime error: stack overflow
error: failed to compile tmkms v0.5.0, intermediate artifacts can be found at /tmp/cargo-install62z2KV
Caused by:
Could not compile curve25519-dalek.
Caused by:
process didn't exit successfully: rustc --crate-name curve25519_dalek /home/cos/.cargo/registry/src/github.com-1ecc6299db9ec823/curve25519-dalek-1.1.4/src/lib.rs --color always --crate-type lib --emit=dep-info,link -C opt-level=3 -C overflow-checks=on --cfg 'feature="u64_backend"' -C metadata=37a7824463be57a8 -C extra-filename=-37a7824463be57a8 --out-dir /tmp/cargo-install62z2KV/release/deps -L dependency=/tmp/cargo-install62z2KV/release/deps --extern byteorder=/tmp/cargo-install62z2KV/release/deps/libbyteorder-390edbb2df0d5ae3.rlib --extern clear_on_drop=/tmp/cargo-install62z2KV/release/deps/libclear_on_drop-ae77b3887c6e4253.rlib --extern digest=/tmp/cargo-install62z2KV/release/deps/libdigest-2db4b0bc6cdb0346.rlib --extern rand_core=/tmp/cargo-install62z2KV/release/deps/librand_core-8496bd7248272c63.rlib --extern subtle=/tmp/cargo-install62z2KV/release/deps/libsubtle-05e24300c165daf8.rlib --cap-lints allow -Ctarget-feature=+aes,+ssse3 --cfg 'feature="stage2_build"' -L native=/tmp/cargo-install62z2KV/release/build/clear_on_drop-c162a7e97e5ad099/out (signal: 6, SIGABRT: process abort signal)
another sever: [ubuntu 16.04]
cargo build --release --features=ledgertm
error: Could not compile `curve25519-dalek`.
Caused by:
process didn't exit successfully: `rustc --crate-name curve25519_dalek /root/.cargo/registry/src/github.com-1ecc6299db9ec823/curve25519-dalek-1.1.3/src/lib.rs --color always --crate-type lib --emit=dep-info,link -C opt-level=3 -C overflow-checks=on --cfg 'feature="u64_backend"' -C metadata=56ed1176248e50db -C extra-filename=-56ed1176248e50db --out-dir /root/kms/target/release/deps -L dependency=/root/kms/target/release/deps --extern byteorder=/root/kms/target/release/deps/libbyteorder-390edbb2df0d5ae3.rlib --extern clear_on_drop=/root/kms/target/release/deps/libclear_on_drop-ae77b3887c6e4253.rlib --extern digest=/root/kms/target/release/deps/libdigest-2db4b0bc6cdb0346.rlib --extern rand_core=/root/kms/target/release/deps/librand_core-8496bd7248272c63.rlib --extern subtle=/root/kms/target/release/deps/libsubtle-66151c67315ea5d1.rlib --cap-lints allow -Ctarget-feature=+aes,+ssse3 --cfg 'feature="stage2_build"' -L native=/root/kms/target/release/build/clear_on_drop-c162a7e97e5ad099/out` (signal: 11, SIGSEGV: invalid memory reference)
warning: build failed, waiting for other jobs to finish...
error: build failed
I'd suggest opening issues with https://github.com/dalek-cryptography/curve25519-dalek
I'm having the same issue, same config:
- x86_64 /ubuntu 18.04
- rustc 1.32.0;
- gcc + clang;
- pkg-config;
- libusb (1.0+)
but while trying with cargo install tmkms --features=yubihsm
@gaia please post the full error
@SemElVik, I might have solved it (if positive please don't forget to close dalek-cryptography/curve25519-dalek#252)
At first I had installed rust as a dep of apt install cargo
. So I started fresh again (clean install of Ubuntu 18.04.2), then:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh (instead of apt install cargo)
apt install pkg-config
apt install libusb-1.0-0-dev
downloaded the YubiHSM2 SDK, then dpkg -i *.deb
, followed by cargo install tmkms --features=yubihsm
. no errors in the compiling.
@tarcieri, the error was as far as I recall identical to SemElVik's, maybe only some numbers changed - my memory isn't that good ;)
@gaia thanks. i remember open issue.
I will close when I will describe reproduction.
dalek-cryptography/curve25519-dalek#261