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
I have a develop machine with Centos7 where I build little applications to run on Centos7 and Centos6 target machines.
Now trying to run my "hello-world" application on Centos6 and it crashes:
fn main() {
println!("Hello, world!");
}
$ ./hello-world
./hello-world: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by ./hello-world)
The actually glibc version that gets dynamically linked to the pre-packaged libstd in the x86_64-unknown-linux-gnu components is chosen in rust-lang/rust, so you'd need to ask there why are they using a linux image that uses glibc 2.14 and not some older linux version (probably because libstd needs an API that's only available in glibc 2.14, but maybe there isn't a good reason beyond "that's the image we have and nobody has complained about it until now").
Needless to mention that Applications compiled with other Languages do run on both Centos7 and Centos6 systems.
Those applications might be dynamically linked against a glibc 2.12 or older. You can recompile your application in your system down to libstd using cargo xbuild, and that will have to at least try to link to your system glibc version. A binary compiled against glibc 2.12 is forward compatible with glibc 2.14, so if libstd supports glibc 2.12, then that should work.
I have a develop machine with Centos7 where I build little applications to run on Centos7 and Centos6 target machines.
Now trying to run my "hello-world" application on Centos6 and it crashes:
the target system is:
the
glibc
package provides:So I am wondering why the Rust Library requires
GLIBC_2.14
and cannot run withGLIBC_2.12
?Needless to mention that Applications compiled with other Languages do run on both Centos7 and Centos6 systems.
Another Application built with another Compiler on Centos7:
The text was updated successfully, but these errors were encountered: