ld.so's LD_LIBRARY_PATH/LD_PRELOAD in mixed 32bit and 64bit environment

Kalle Olavi Niemitalo kon@iki.fi
Mon Aug 22 19:54:00 GMT 2011


Alon Bar-Lev <alon.barlev@gmail.com> writes:

> LIB  is  expanded to lib or lib64 based on the architecture. Use
> when mixed environment  (32bit  and  64bit)  searches  for  same
> libraries names.

Debian libc6 2.11.2-10 on AMD64 expands the tokens like this:

LIB=lib                 (not lib64)
PLATFORM=x86_64

Debian libc6 2.13-16 on Intel 64 expands the tokens like this:

LIB=x86_64-linux-gnu
PLATFORM=x86_64         (as above)

So, it seems wrong to claim $LIB is expanded to lib or lib64.
Tested with:
% LD_LIBRARY_PATH='/LIB=$LIB/PLATFORM=$PLATFORM' strace true > /dev/null 2>&1 | grep LIB= | head -n1



More information about the Libc-alpha mailing list