| Log Message: |
filterSysLibpath: do NOT remove any -L arguments
Since we do not recognise various multilib-dirs, the following simple
example causes breakage due to only the Prefix libdir being removed:
% gcc -o t -L$EPREFIX/usr/lib -L/usr/lib64 -lgdbm t.c
The executable t will be linked against /usr/lib64/libgdbm.so.X, while
$EPREFIX/usr/lib/libgdbm.so.Y (with Y > X) exists. This is due to the
invocation to ld having the -L$EPREFIX/usr/lib moved to the end, while
the -L/usr/lib64 is retained in its original position. Net effect,
/usr/lib64 is searched first, while the original gcc/collect2 invocation
was setup properly.
For this reason, don't try to be smart, by moving -L arguments around.
At all times, the input should be sane, the wrapper should only be
adding -L/-rpath arguments at the end for the configured Prefix system.
|