mirror of
https://github.com/JakeStanger/ironbar.git
synced 2026-07-11 08:15:21 +01:00
[GH-ISSUE #573] cargo install error on Alpine -- nix related? #5808
Labels
No labels
A:Build
A:CI
A:Client
A:Config
A:Core
A:Documentation
A:Documentation
A:IPC
A:Testing
A:UX/UI
blocked
BREAKING CHANGE
duplicate
good first issue
GTK4
help wanted
invalid
M:Battery
M:Battery
M:Bindmode
M:Bluetooth
M:Brightness
M:Cairo
M:Clipboard
M:Clock
M:Clock
M:Custom
M:Focused
M:Keyboard
M:Launcher
M:Menu
M:Music
M:Music
M:Music
M:Network Manager
M:Notifications
M:SysInfo
M:Tray
M:Volume
M:Workspaces
partially resolved
P:Critical
P:High
P:Low
P:Medium
pull-request
T:Bug
T:Bug
T:Core Enhancement
T:Module Enhancement
T:New Module
T:Question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
JakeStanger/ironbar#5808
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 @moranbw on GitHub (May 6, 2024).
Original GitHub issue: https://github.com/JakeStanger/ironbar/issues/573
When running
cargo install ironbaron my machine, I got this error:I then proceeded to clone the repo and build directly (
cargo build --release), and it worked! I am using Alpine Linux, so not sure if there is some weirdness going on there. But just wanted to bring it to your attention. Looking forward to playing with the bar.System information:
@JakeStanger commented on GitHub (May 7, 2024):
Hey, the
nixcrate refers to *nix rather than Nix(OS). Under the hood it binds to the platform's libc library.Am I right in thinking alpine uses musl rather than glibc? That might be the cause here, although I've no idea why it'd work installing it one way and not the other when it's compiling on your system either way.
@rgilton commented on GitHub (May 18, 2024):
I see the same errors when trying to build on Fedora 40. Building with rust 1.78.0.
@JakeStanger commented on GitHub (May 18, 2024):
Well I guess that rules out musl then. I've just tried in a Fedora docker container from blank and it built fine, so not sure what's going on there.
I'll have a poke around in the nix crate and see if I can see any reason that
fsfeature flag would get turned off.@JakeStanger commented on GitHub (May 18, 2024):
For some reason Rust is resolving a newer version of the
nixcrate than what was in the lockfile for you guys, which had breaking changes. I've updated to the latest version in the above PR which also fixes the breaking changes, so this should be resolved once that's merged.@JimitSoni18 commented on GitHub (Jun 9, 2024):
still facing the issue when installing using cargo:
cargo install ironbar
error[E0432]: unresolved import
nix::fcntl::OFlag--> /home/jimit/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ironbar-0.15.1/src/clients/wayland/wlr_data_control/offer.rs:3:5
|
3 | use nix::fcntl::OFlag;
| ^^^^^^^^^^^^^^^^^ no
OFlaginfcntlerror[E0432]: unresolved import
nix::unistd::pipe2--> /home/jimit/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ironbar-0.15.1/src/clients/wayland/wlr_data_control/offer.rs:4:26
|
4 | use nix::unistd::{close, pipe2};
| ^^^^^
| |
| no
pipe2inunistd| help: a similar name exists in the module:
pipe|
note: found an item that was configured out
--> /home/jimit/.cargo/registry/src/index.crates.io-6f17d22bba15001f/nix-0.27.1/src/unistd.rs:1233:8
|
1233 | pub fn pipe2(flags: OFlag) -> Result<(RawFd, RawFd)> {
| ^^^^^
= note: the item is gated behind the
fsfeatureerror[E0432]: unresolved imports
nix::fcntl::fcntl,nix::fcntl::F_GETPIPE_SZ,nix::fcntl::F_SETPIPE_SZ--> /home/jimit/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ironbar-0.15.1/src/clients/wayland/wlr_data_control/mod.rs:13:18
|
13 | use nix::fcntl::{fcntl, F_GETPIPE_SZ, F_SETPIPE_SZ};
| ^^^^^ ^^^^^^^^^^^^ ^^^^^^^^^^^^ no
F_SETPIPE_SZinfcntl| | |
| | no
F_GETPIPE_SZinfcntl| no
fcntlinfcntl|
= help: consider importing this module instead:
nix::fcntl
note: found an item that was configured out
--> /home/jimit/.cargo/registry/src/index.crates.io-6f17d22bba15001f/nix-0.27.1/src/fcntl.rs:509:8
|
509 | pub fn fcntl(fd: RawFd, arg: FcntlArg) -> Result<c_int> {
| ^^^^^
= note: the item is gated behind the
fsfeatureerror[E0308]: mismatched types
--> /home/jimit/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ironbar-0.15.1/src/clients/compositor/hyprland.rs:156:51
|
156 | let name = get_workspace_name(workspace_type);
| ------------------ ^^^^^^^^^^^^^^ expected
WorkspaceType, foundWorkspaceDestroyedEventData| |
| arguments to this function are incorrect
|
note: function defined here
--> /home/jimit/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ironbar-0.15.1/src/clients/compositor/hyprland.rs:247:4
|
247 | fn get_workspace_name(name: WorkspaceType) -> String {
| ^^^^^^^^^^^^^^^^^^ -------------------
Some errors have detailed explanations: E0308, E0432.
For more information about an error, try
rustc --explain E0308.error: could not compile
ironbar(bin "ironbar") due to 4 previous errorserror: failed to compile
ironbar v0.15.1, intermediate artifacts can be found at/tmp/cargo-installpCyxrB.To reuse those artifacts with a future compilation, set the environment variable
CARGO_TARGET_DIRto that path.