mirror of
git://git.savannah.gnu.org/libtool.git
synced 2025-02-11 15:00:08 +08:00
libtool: Use $LD when checking for --whole-archive
Using `$CC -print-prog-name=ld` will always use the `ld` linker. We should instead be using the $LD variable so that we use the proper linker. There is already another part of the code that does this same check, so I just copy/pasted the if line. * m4/libtool.m4: Change `$CC -print-prog-name=ld` to $LD. Url: https://savannah.gnu.org/support/?110978 Signed-off-by: Raul E Rangel <rrangel@chromium.org>
This commit is contained in:
parent
5a7193dbfb
commit
f81f36e4e9
3
m4/libtool.m4
vendored
3
m4/libtool.m4
vendored
@ -6427,8 +6427,7 @@ if test yes != "$_lt_caught_CXX_error"; then
|
||||
wlarc='$wl'
|
||||
|
||||
# ancient GNU ld didn't support --whole-archive et. al.
|
||||
if eval "`$CC -print-prog-name=ld` --help 2>&1" |
|
||||
$GREP 'no-whole-archive' > /dev/null; then
|
||||
if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
|
||||
_LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
|
||||
else
|
||||
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
||||
|
Loading…
Reference in New Issue
Block a user