We have 32 bit application on 64 bit rhel 6.4 . If I do ldd on the binary, it showsit is using 32 bit version of glibc. Is it possible to make it to point to 64 bit version of glibc? If yes, how can I do that?I have compiled the binaries using the -m32 flag.
using 64bit library for 32 bit application
linux
No it's not possible. They use different binary formats, use different calling conventions, different instruction set, different syscall methods, different ... everything.root@el6 ~ # file /lib/libc-2.12.so /lib/libc-2.12.so: ELF 32-bit LSB shared object, Intel 80386, [...]root@el6 ~ # file /lib64/libc-2.12.so /lib64/libc-2.12.so: ELF 64-bit LSB shared object, x86-64, [...]32-bit binary needs 32-bit libs, 64-bit binaries need 64-bit libs. If you want your app to use the 64-bit libc compile it without -m32 as a 64-bit app.