I am compiling some inherited code onto a linux platform. When I try to run it, I get a library versioning error:
[aardvark@aardvark-burrow /data/users/aardvark/project-source] /data/users/aardvark/project-source/buck-out/gen/arvr/projects/viper/applications/replay/fcv_replay
/data/users/aardvark/project-source/buck-out/gen/arvr/projects/viper/applications/replay/fcv_replay: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by /data/users/aardvark/project-source/buck-out/gen/arvr/projects/viper/applications/replay/fcv_replay)
First off, who cares that I have GLIBC_2.28, not 2.29, and why do they care? Is it a compile flag passed to build the final executable (fcv_replay), or one of its many dependencies? How do I find out? I basically want to know what to look for inside a large, complex build system that I didn't create.
Here are the results of another query:
[aardvark@ /data/users/aardvark/project-source] ldd /data/users/aardvark/project-source/buck-out/gen/arvr/projects/viper/applications/replay/fcv_replay
/data/users/aardvark/project-source/buck-out/gen/arvr/projects/viper/applications/replay/fcv_replay: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by /data/users/aardvark/project-source/buck-out/gen/arvr/projects/viper/applications/replay/fcv_replay)
linux-vdso.so.1 (0x00007ffe84592000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fe4daefd000)
libm.so.6 => /lib64/libm.so.6 (0x00007fe4dab7b000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007fe4da977000)
libc.so.6 => /lib64/libc.so.6 (0x00007fe4da5b2000)
/lib64/ld-linux-x86-64.so.2 (0x00007fe4db11d000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007fe4da39a000)
You app,
fcv_replay, has been compiled on a newer Linux distro (or a new toolchain) and is using some new functions fromlibmlibrary which are missing in your current distro.You can see which part of the executable is causing the problem by inspecting the disassembly:
The best solution would be to rebuild
fcv_replayon the oldest possible distro to avoid dependency on new versions of libc.