On Thu, Jun 22, 2006 at 03:26:01PM -0400, Neal Becker wrote:
It appears that in an x86_64 environment, that LD_PRELOAD rejects
32-bit
binaries? Even though the executable will be 32-bit.
Is this true, and if so, is there a workaround? Should there be?
Don't use absolute filename or use $LIB in LD_PRELOAD and build the preload
library as both 32-bit and 64-bit (if only one is needed, the other one can
be dummy empty shared lib).
Say
LD_PRELOAD=libSegFault.so
will work for both 32-bit and 64-bit programs, as /lib/libSegFault.so and
/lib64/libSegFault.so both exist.
Similarly
LD_PRELOAD='/$LIB/libSegFault.so'
Jakub