You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Context
Background on what is broken in rustc (besides language features like proc macros depending on linking mode): rust-lang/rust#135244 and rust-lang/rust#95926
System: Chimera Linux with network installation.
error: linking with `cc` failed: exit status: 1
[...]
= note: some arguments are omitted. use `--verbose` to show all linker arguments
= note: ld: error: unable to find library -lgcc_s
cc: error: linker command failed with exit code 1 (use -v to see invocation)
cargo install stylua --features lua52
Updating crates.io index
Installing stylua v2.0.2
Updating crates.io index
Locking 97 packages to latest compatible versions
Adding clap v3.2.25 (available: v4.5.32)
Adding env_logger v0.10.2 (available: v0.11.7)
Adding thiserror v1.0.69 (available: v2.0.12)
error: failed to compile `stylua v2.0.2`, intermediate artifacts can be found at `/tmp/cargo-installlGgsiF`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.
Caused by:
cannot produce proc-macro for `clap_derive v3.2.25` as the target `x86_64-unknown-linux-musl` does not support these crate types
Solution 1
Describe in README correct flags to disable clap_derive for static builds to just work on any host system.
Solution 2
Explain how to set musl dynamic linking.
Solution 3
Explain that musl host systems are not supported.
Solution 4
Link to gcc based cross-compiler setup with rustc and cargo for proc-macro to "just work".
The text was updated successfully, but these errors were encountered:
I don't know much about chimera linux, but we do already publish a stylua-linux-x86_64-musl.zip release artifact that is based on musl, so I believe it should be working. As also seen by the link above
the issue they are facing is most likely due to upstream rust compilers not handling systems that are clang-native well (due to those having no libgcc/libgcc_s and instead using libclang_rt.builtins staticlib and libunwind) but this is patched in distro toolchain
Context
Background on what is broken in rustc (besides language features like proc macros depending on linking mode): rust-lang/rust#135244 and rust-lang/rust#95926
System: Chimera Linux with network installation.
Output
Output
Solution 1
Describe in README correct flags to disable clap_derive for static builds to just work on any host system.
Solution 2
Explain how to set musl dynamic linking.
Solution 3
Explain that musl host systems are not supported.
Solution 4
Link to gcc based cross-compiler setup with rustc and cargo for proc-macro to "just work".
The text was updated successfully, but these errors were encountered: