Frodo45127 / rpfm

Rusted PackFile Manager (RPFM) is a... reimplementation in Rust and Qt5 of PackFile Manager (PFM), one of the best modding tools for Total War Games.
MIT License
357 stars 57 forks source link

/rpfm_cli: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.38' not found (required by ./rpfm_cli) #282

Closed GHMesLing closed 7 months ago

GHMesLing commented 7 months ago

❯ uname -a Linux Laptop-RedmiBook-NagaResst 6.2.0-39-generic #40~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Thu Nov 16 10:53:04 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

❯ cat /etc/os-release PRETTY_NAME="Ubuntu 22.04.3 LTS" NAME="Ubuntu" VERSION_ID="22.04" VERSION="22.04.3 LTS (Jammy Jellyfish)" VERSION_CODENAME=jammy ID=ubuntu ID_LIKE=debian HOME_URL="https://www.ubuntu.com/" SUPPORT_URL="https://help.ubuntu.com/" BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy" UBUNTU_CODENAME=jammy

❯ strings /lib/x8664-linux-gnu/libc.so.6 | grep GLIBC GLIBC_2.2.5 GLIBC_2.2.6 GLIBC_2.3 GLIBC_2.3.2 GLIBC_2.3.3 GLIBC_2.3.4 GLIBC_2.4 GLIBC_2.5 GLIBC_2.6 GLIBC_2.7 GLIBC_2.8 GLIBC_2.9 GLIBC_2.10 GLIBC_2.11 GLIBC_2.12 GLIBC_2.13 GLIBC_2.14 GLIBC_2.15 GLIBC_2.16 GLIBC_2.17 GLIBC_2.18 GLIBC_2.22 GLIBC_2.23 GLIBC_2.24 GLIBC_2.25 GLIBC_2.26 GLIBC_2.27 GLIBC_2.28 GLIBC_2.29 GLIBC_2.30 GLIBC_2.31 GLIBC_2.32 GLIBC_2.33 GLIBC_2.34 GLIBC_2.35 GLIBC_PRIVATE

why it need GLIBC_2.38? Installing additional glibc installation packages is a very foolish behavior, which can lead to very unstable systems.

Frodo45127 commented 7 months ago

Because the binary was compiled in arch, and that's the version of glibc that was on the docker container that compiled the binary. If you need to use it in a distro with older libs, it may be better to install rust and do "cargo install rpfm_cli", or manually downloading the repo and compiling it yourself for your distro.

GHMesLing commented 7 months ago

Because the binary was compiled in arch, and that's the version of glibc that was on the docker container that compiled the binary. If you need to use it in a distro with older libs, it may be better to install rust and do "cargo install rpfm_cli", or manually downloading the repo and compiling it yourself for your distro.

I install rust and do "cargo install rpfm_cli" :

error[E0308]: mismatched types --> /home/nagaresst/.cargo/registry/src/github.com-1ecc6299db9ec823/rpfm_lib-4.2.3/src/games/mod.rs:705:20 705 if let Some(mut steamdir) = SteamDir::locate() { ^^^^^^^^^^^^^^^^^^ ------------------ this expression has type std::result::Result<SteamDir, steamlocate::Error>
expected Result<SteamDir, Error>, found Option<_>
= note: expected enum `std::result::Result<SteamDir, steamlocate::Error>`
           found enum `std::option::Option<_>`
error[E0308]: mismatched types --> /home/nagaresst/.cargo/registry/src/github.com-1ecc6299db9ec823/rpfm_lib-4.2.3/src/games/mod.rs:731:20 731 if let Some(mut steamdir) = SteamDir::locate() { ^^^^^^^^^^^^^^^^^^ ------------------ this expression has type std::result::Result<SteamDir, steamlocate::Error>
expected Result<SteamDir, Error>, found Option<_>
= note: expected enum `std::result::Result<SteamDir, steamlocate::Error>`
           found enum `std::option::Option<_>`

For more information about this error, try rustc --explain E0308.

all detils:

❯ cargo install rpfm_cli Updating crates.io index Installing rpfm_cli v4.2.3 Compiling libc v0.2.152 Compiling proc-macro2 v1.0.76 Compiling unicode-ident v1.0.12 Compiling serde v1.0.195 Compiling autocfg v1.1.0 Compiling pkg-config v0.3.28 Compiling thiserror v1.0.56 Compiling cfg-if v1.0.0 Compiling memchr v2.7.1 Compiling itoa v1.0.10 Compiling vcpkg v0.2.15 Compiling once_cell v1.19.0 Compiling tinyvec_macros v0.1.1 Compiling tinyvec v1.6.0 Compiling percent-encoding v2.3.1 Compiling form_urlencoded v1.2.1 Compiling num-traits v0.2.17 Compiling unicode-bidi v0.3.14 Compiling ryu v1.0.16 Compiling pin-project-lite v0.2.13 Compiling powerfmt v0.2.0 Compiling serde_json v1.0.111 Compiling time-core v0.1.2 Compiling time-macros v0.2.16 Compiling deranged v0.3.11 Compiling quote v1.0.35 Compiling unicode-normalization v0.1.22 Compiling ppv-lite86 v0.2.17 Compiling syn v2.0.48 Compiling log v0.4.20 Compiling num_threads v0.1.6 Compiling getrandom v0.2.12 Compiling jobserver v0.1.27 Compiling rand_core v0.6.4 Compiling idna v0.5.0 Compiling bytes v1.5.0 Compiling cc v1.0.83 Compiling rand_chacha v0.3.1 Compiling mio v0.8.10 Compiling num_cpus v1.16.0 Compiling socket2 v0.5.5 Compiling rand v0.8.5 Compiling slab v0.4.9 Compiling num-integer v0.1.45 Compiling hashbrown v0.14.3 Compiling hex v0.4.3 Compiling equivalent v1.0.1 Compiling futures-core v0.3.30 Compiling time v0.3.31 Compiling tokio v1.35.1 Compiling tracing-core v0.1.32 Compiling foreign-types-shared v0.1.1 Compiling fnv v1.0.7 Compiling openssl v0.10.62 Compiling version_check v0.9.4 Compiling openssl-sys v0.9.98 Compiling libz-sys v1.1.14 Compiling indexmap v2.1.0 Compiling semver v1.0.21 Compiling ucd-trie v0.1.6 Compiling tracing v0.1.40 Compiling http v0.2.11 Compiling foreign-types v0.3.2 Compiling aho-corasick v1.1.2 Compiling num-bigint v0.4.4 Compiling crossbeam-utils v0.8.19 Compiling openssl-probe v0.1.5 Compiling futures-io v0.3.30 Compiling regex-syntax v0.8.2 Compiling httparse v1.8.0 Compiling pin-utils v0.1.0 Compiling futures-sink v0.3.30 Compiling native-tls v0.2.11 Compiling futures-task v0.3.30 Compiling syn v1.0.109 Compiling futures-util v0.3.30 Compiling libssh2-sys v0.3.0 Compiling backtrace v0.3.69 Compiling num-rational v0.4.1 Compiling try-lock v0.2.5 Compiling adler v1.0.2 Compiling gimli v0.28.1 Compiling miniz_oxide v0.7.1 Compiling want v0.3.1 Compiling rustc_version v0.4.0 Compiling regex-automata v0.4.3 Compiling serde_derive v1.0.195 Compiling thiserror-impl v1.0.56 Compiling openssl-macros v0.1.1 Compiling tokio-util v0.7.10 Compiling addr2line v0.21.0 Compiling regex v1.10.2 Compiling pest v2.7.6 Compiling h2 v0.3.23 Compiling pest_meta v2.7.6 Compiling http-body v0.4.6 Compiling proc-macro-error-attr v1.0.4 Compiling pest_generator v2.7.6 Compiling findshlibs v0.10.2 Compiling futures-channel v0.3.30 Compiling num-complex v0.4.4 Compiling object v0.32.2 Compiling num-iter v0.1.43 Compiling httpdate v1.0.3 Compiling tower-service v0.3.2 Compiling option-ext v0.2.0 Compiling paste v1.0.14 Compiling rustc-demangle v0.1.23 Compiling bytemuck v1.14.0 Compiling safe_arch v0.7.1 Compiling pest_derive v2.7.6 Compiling dirs-sys v0.4.1 Compiling hyper v0.14.28 Compiling crossbeam-epoch v0.9.18 Compiling sentry-contexts v0.32.1 Compiling proc-macro-error v1.0.4 Compiling libgit2-sys v0.15.2+1.6.4 Compiling lzma-sys v0.1.20 Compiling bitflags v2.4.1 Compiling url v2.5.0 Compiling uuid v1.6.1 Compiling matrixmultiply v0.3.8 Compiling rustix v0.38.28 Compiling debugid v0.8.0 Compiling base64 v0.21.6 Compiling typenum v1.17.0 Compiling match_cfg v0.1.0 Compiling rayon-core v1.12.0 Compiling sentry-types v0.32.1 Compiling hostname v0.3.1 Compiling toml_datetime v0.6.5 Compiling serde_spanned v0.6.5 Compiling serde_urlencoded v0.7.1 Compiling caseless v0.2.1 Compiling crossbeam-deque v0.8.5 Compiling keyvalues-parser v0.2.0 Compiling wide v0.7.13 Compiling approx v0.5.1 Compiling uname v0.1.1 Compiling encoding_rs v0.8.33 Compiling ipnet v2.9.0 Compiling either v1.9.0 Compiling tokio-native-tls v0.3.1 Compiling sentry-core v0.32.1 Compiling hyper-tls v0.5.0 Compiling sentry-backtrace v0.32.1 Compiling mime v0.3.17 Compiling rawpointer v0.2.1 Compiling linux-raw-sys v0.4.12 Compiling crc-catalog v2.4.0 Compiling winnow v0.5.34 Compiling derive_pod v0.1.2 Compiling utf8parse v0.2.1 Compiling anstyle-parse v0.2.3 Compiling dataview v1.0.1 Compiling crc v3.0.1 Compiling reqwest v0.11.23 Compiling sentry-panic v0.32.1 Compiling sentry-log v0.32.1 Compiling toml_edit v0.19.15 Compiling sentry-debug-images v0.32.1 Compiling simba v0.8.1 Compiling num v0.4.1 Compiling keyvalues-serde v0.2.1 Compiling dirs v5.0.1 Compiling nalgebra-macros v0.2.1 Compiling csv-core v0.1.11 Compiling lazy_static v1.4.0 Compiling bitflags v1.3.2 Compiling xml-rs v0.8.19 Compiling termcolor v1.1.3 Compiling pelite-macros v0.1.1 Compiling bit-vec v0.6.3 Compiling no-std-compat v0.4.1 Compiling anstyle-query v1.0.2 Compiling colorchoice v1.0.0 Compiling anstyle v1.0.4 Compiling bit-set v0.5.3 Compiling serde-xml-rs v0.6.0 Compiling pelite v0.10.0 Compiling simplelog v0.12.1 Compiling anstream v0.6.5 Compiling fraction v0.13.1 Compiling csv v1.3.0 Compiling toml v0.7.8 Compiling rayon v1.8.0 Compiling steamlocate v2.0.0-beta.2 Compiling getset v0.1.2 Compiling sentry v0.32.1 Compiling terminal_size v0.3.0 Compiling itertools v0.11.0 Compiling ron v0.8.1 Compiling os_info v3.7.0 Compiling bincode v1.3.3 Compiling directories v5.0.1 Compiling content_inspector v0.2.4 Compiling anyhow v1.0.79 Compiling nalgebra v0.32.3 Compiling float_eq v1.0.1 Compiling heck v0.4.1 Compiling byteorder v1.5.0 Compiling clap_lex v0.6.0 Compiling strsim v0.10.0 Compiling clap_derive v4.4.7 Compiling clap_builder v4.4.14 Compiling fancy-regex v0.11.0 Compiling rpfm_cli v4.2.3 Compiling clap v4.4.14 Compiling xz2 v0.1.7 Compiling git2 v0.17.2 Compiling rpfm_lib v4.2.3 error[E0308]: mismatched types --> /home/nagaresst/.cargo/registry/src/github.com-1ecc6299db9ec823/rpfm_lib-4.2.3/src/games/mod.rs:705:20 705 if let Some(mut steamdir) = SteamDir::locate() { ^^^^^^^^^^^^^^^^^^ ------------------ this expression has type std::result::Result<SteamDir, steamlocate::Error>
expected Result<SteamDir, Error>, found Option<_>
= note: expected enum `std::result::Result<SteamDir, steamlocate::Error>`
           found enum `std::option::Option<_>`
error[E0308]: mismatched types --> /home/nagaresst/.cargo/registry/src/github.com-1ecc6299db9ec823/rpfm_lib-4.2.3/src/games/mod.rs:731:20 731 if let Some(mut steamdir) = SteamDir::locate() { ^^^^^^^^^^^^^^^^^^ ------------------ this expression has type std::result::Result<SteamDir, steamlocate::Error>
expected Result<SteamDir, Error>, found Option<_>
= note: expected enum `std::result::Result<SteamDir, steamlocate::Error>`
           found enum `std::option::Option<_>`

For more information about this error, try rustc --explain E0308. error: could not compile rpfm_lib due to 2 previous errors error: failed to compile rpfm_cli v4.2.3, intermediate artifacts can be found at /tmp/cargo-installFBJc4b

❯ rustc -V rustc 1.70.0 (90c541806 2023-05-31) (built from a source tarball)

Frodo45127 commented 7 months ago

Fixed for the next release. Not sure why, but when using cargo install the cli seems to try to use a more recent version of the steam lib it uses to find the game folders.... which contain breaking changes that break compilation. I've updated the dependencies for the next update so it compiles with the latest version of said lib correctly. If you don't want to wait until then, download this repo, change to the develop branch, and do an cargo build --release --bin rpfm_cli and it'll build your bin in target/release.