mirror of
https://github.com/librespot-org/librespot.git
synced 2026-04-27 08:15:50 +03:00
[GH-ISSUE #678] Error: could not compile protobuf #390
Labels
No labels
A-Alsa
SpotifyAPI
Tokio 1.0
audio
bug
can't reproduce
compilation
dependencies
duplicate
enhancement
good first issue
help wanted
high priority
imported
imported
invalid
new api
pull-request
question
reverse engineering
wiki
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/librespot#390
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @MW-SAND on GitHub (Mar 21, 2021).
Original GitHub issue: https://github.com/librespot-org/librespot/issues/678
I'm using Ubuntu 20.04 and I'm unable to compile librespot with the following command: sudo cargo build --release. If you need any more info please let me know.
error: could not compile
protobuf.Caused by:
process didn't exit successfully:
rustc --crate-name protobuf /root/.cargo/registry/src/github.com-1ecc6299db9ec823/protobuf-2.14.0/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -Cembed-bitcode=no -C metadata=f69098f2fee967d7 -C extra-filename=-f69098f2fee967d7 --out-dir /home/ubuntu/Wekker/librespot/target/release/deps -L dependency=/home/ubuntu/Wekker/librespot/target/release/deps --cap-lints allow(signal: 9, SIGKILL: kill)warning: build failed, waiting for other jobs to finish...
error: build failed
@Johannesd3 commented on GitHub (Mar 21, 2021):
Works fine for me. Did you try it several times or just once? You're log has a strange formatting, but it seems as if it was simply killed.
Edit: Maybe the OOM killer? Do you have enough RAM?
@MW-SAND commented on GitHub (Mar 23, 2021):
I have tried it several times over the past few weeks.
Thank you for your suggestion. I only have 1 GB ram, however, the library has been compiled a couple of months ago with the same amount of ram. I tried disabling the overcommit of OOM, but this results in multiple errors, I couldn't even get to the library folder.
@MW-SAND commented on GitHub (Mar 25, 2021):
Compiling librespot-metadata v0.1.6 (/home/ubuntu/Wekker/librespot/metadata)
error: could not compile
librespot-protocol.Caused by:
process didn't exit successfully:
rustc --crate-name librespot_protocol --edi tion=2018 protocol/src/lib.rs --error-format=json --json=diagnostic-rendered-ans i,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -Cembe d-bitcode=no -C metadata=27e66b292c3d66e2 -C extra-filename=-27e66b292c3d66e2 -- out-dir /home/ubuntu/Wekker/librespot/target/release/deps -L dependency=/home/ub untu/Wekker/librespot/target/release/deps --extern protobuf=/home/ubuntu/Wekker/ librespot/target/release/deps/libprotobuf-f69098f2fee967d7.rmeta(signal: 9, SI GKILL: kill)warning: build failed, waiting for other jobs to finish...
error: build failed
okay so I've tried it once again and for some reason, protobuf compiled correctly but now it got an error on librespot-protocol.
Is this a RAM issue or could it be something else?
@Johannesd3 commented on GitHub (Mar 25, 2021):
I really think it's a RAM issue.
You could try to google for tricks to compile rust programs with little memory, or if you don't find anything, ask on users.rust-lang.org
@roderickvd commented on GitHub (Mar 25, 2021):
1GB is enough to compile even with all features. Surely this is not a librespot bug.
@sashahilton00 commented on GitHub (Mar 26, 2021):
I believe I have encountered this before when I used to use a RPi 2 as a connect receiver. I'd suggest either cross compiling or a swap file of 2G or so, though this won't be great for the SD card if that's what you're running it off. Anyway, closing as this isn't a librespot bug from what I can tell.
pkg-configto docker build container #904