Binutils: Check if AR works with --plugin and rc
authorH.J. Lu <hjl.tools@gmail.com>
Tue, 12 Jan 2021 00:29:31 +0000 (16:29 -0800)
committerH.J. Lu <hjl.tools@gmail.com>
Tue, 12 Jan 2021 00:29:45 +0000 (16:29 -0800)
Check if AR works with --plugin and rc before passing --plugin to AR and
RANLIB.

bfd/

PR ld/27173

binutils/

PR ld/27173
* configure: Regenerated.

gas/

PR ld/27173
* configure: Regenerated.

gprof/

PR ld/27173
* configure: Regenerated.

ld/

PR ld/27173
* configure: Regenerated.

libctf/

PR ld/27173
* configure: Regenerated.

opcodes/

PR ld/27173
* configure: Regenerated.

14 files changed:
bfd/ChangeLog
bfd/configure
binutils/ChangeLog
binutils/configure
gas/ChangeLog
gas/configure
gprof/ChangeLog
gprof/configure
ld/ChangeLog
ld/configure
libctf/ChangeLog
libctf/configure
opcodes/ChangeLog
opcodes/configure

index 876cd1c86e3baca56f6dcf295c2ed2e840f89faa..38123b44407bc378b24d3b57a28d80020859a873 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/27173
+       * configure: Regenerated.
+
 2021-01-11  Nick Clifton  <nickc@redhat.com>
 
        * po/fr.po: Updated French translation.
index 4b8dede2150012d5387c8576a4eacf42df53900f..32c547f53bcbe054961267447cf1e52761baab0d 100755 (executable)
@@ -6932,7 +6932,15 @@ fi
 test -z "$AR" && AR=ar
 if test -n "$plugin_option"; then
   if $AR --help 2>&1 | grep -q "\--plugin"; then
-    AR="$AR $plugin_option"
+    touch conftest.c
+    $AR $plugin_option rc conftest.a conftest.c
+    if test "$?" != 0; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
+    else
+      AR="$AR $plugin_option"
+    fi
+    rm -f conftest.*
   fi
 fi
 test -z "$AR_FLAGS" && AR_FLAGS=cru
@@ -11742,7 +11750,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11745 "configure"
+#line 11753 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11848,7 +11856,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11851 "configure"
+#line 11859 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
index 13d05612618be6f9c50bde35d95b2f06078d8498..49c15f4bd91660b8064710366bce194ada7fc546 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/27173
+       * configure: Regenerated.
+
 2021-01-11  Nick Clifton  <nickc@redhat.com>
 
        * po/pt.po: Updated Portuguese translation.
index f1b80648d3f50a2c8d040ed658aeb05e50f12ac6..5fa72aed16be270934e4cd882c8d60ea86da8a2e 100755 (executable)
@@ -6728,7 +6728,15 @@ fi
 test -z "$AR" && AR=ar
 if test -n "$plugin_option"; then
   if $AR --help 2>&1 | grep -q "\--plugin"; then
-    AR="$AR $plugin_option"
+    touch conftest.c
+    $AR $plugin_option rc conftest.a conftest.c
+    if test "$?" != 0; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
+    else
+      AR="$AR $plugin_option"
+    fi
+    rm -f conftest.*
   fi
 fi
 test -z "$AR_FLAGS" && AR_FLAGS=cru
@@ -11569,7 +11577,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11572 "configure"
+#line 11580 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11675,7 +11683,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11678 "configure"
+#line 11686 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
index d65b6216677b3134daf780abe30674b7681fefc8..f8f8c1bc0ec05a2bcdcf69d4b10da7a0d87ddbaf 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/27173
+       * configure: Regenerated.
+
 2021-10-11  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
 
        * NEWS: Remove CSRE.
index 43ac48491dbbda146def0360bb8769f9c7511b50..9dd469b3432ecd3c6ef9a893d9633ca78e755595 100755 (executable)
@@ -6516,7 +6516,15 @@ fi
 test -z "$AR" && AR=ar
 if test -n "$plugin_option"; then
   if $AR --help 2>&1 | grep -q "\--plugin"; then
-    AR="$AR $plugin_option"
+    touch conftest.c
+    $AR $plugin_option rc conftest.a conftest.c
+    if test "$?" != 0; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
+    else
+      AR="$AR $plugin_option"
+    fi
+    rm -f conftest.*
   fi
 fi
 test -z "$AR_FLAGS" && AR_FLAGS=cru
@@ -11357,7 +11365,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11360 "configure"
+#line 11368 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11463,7 +11471,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11466 "configure"
+#line 11474 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
index c6127850d0e5a4be17029c48b9a89039a6c0c65f..8d4c1feeeeff40a9aebb1054b8cc4fd976c49e22 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/27173
+       * configure: Regenerated.
+
 2021-01-09  H.J. Lu  <hongjiu.lu@intel.com>
 
        * configure: Regenerated.
index ce3a1d5bd11dcf087bd082fb032108867f9e6463..375a033aa91e9e03b3650b710120095d84964cb9 100755 (executable)
@@ -6363,7 +6363,15 @@ fi
 test -z "$AR" && AR=ar
 if test -n "$plugin_option"; then
   if $AR --help 2>&1 | grep -q "\--plugin"; then
-    AR="$AR $plugin_option"
+    touch conftest.c
+    $AR $plugin_option rc conftest.a conftest.c
+    if test "$?" != 0; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
+    else
+      AR="$AR $plugin_option"
+    fi
+    rm -f conftest.*
   fi
 fi
 test -z "$AR_FLAGS" && AR_FLAGS=cru
@@ -11204,7 +11212,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11207 "configure"
+#line 11215 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11310,7 +11318,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11313 "configure"
+#line 11321 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
index 9dc7c3ffda3b2ee3f654fc7bf0a0092ee98656e5..bedd0fa326f68730ec01766a8ee462cf9bf14d12 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/27173
+       * configure: Regenerated.
+
 2021-01-11  Matt Jenkins  <matt@majenko.co.uk>
 
        PR ld/27167
index d7cd782957f8c2010926470213a8480b3848a469..4a965be70d71ab7dc37240bbe6a375b8f1102bc2 100755 (executable)
@@ -7214,7 +7214,15 @@ fi
 test -z "$AR" && AR=ar
 if test -n "$plugin_option"; then
   if $AR --help 2>&1 | grep -q "\--plugin"; then
-    AR="$AR $plugin_option"
+    touch conftest.c
+    $AR $plugin_option rc conftest.a conftest.c
+    if test "$?" != 0; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
+    else
+      AR="$AR $plugin_option"
+    fi
+    rm -f conftest.*
   fi
 fi
 test -z "$AR_FLAGS" && AR_FLAGS=cru
@@ -12056,7 +12064,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 12059 "configure"
+#line 12067 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -12162,7 +12170,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 12165 "configure"
+#line 12173 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
index 4970cab4e4a496159c2aea79da1abdf0c93e5cea..9cc02d3c43ba4713249077b36aaf63335acf228c 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/27173
+       * configure: Regenerated.
+
 2021-01-09  H.J. Lu  <hongjiu.lu@intel.com>
 
        * configure: Regenerated.
index 3d2f22528d3103abcba9a054fe73383b665c5329..5e44eda194e0adb17ff40dcaf52527cba5ec7460 100755 (executable)
@@ -6720,7 +6720,15 @@ fi
 test -z "$AR" && AR=ar
 if test -n "$plugin_option"; then
   if $AR --help 2>&1 | grep -q "\--plugin"; then
-    AR="$AR $plugin_option"
+    touch conftest.c
+    $AR $plugin_option rc conftest.a conftest.c
+    if test "$?" != 0; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
+    else
+      AR="$AR $plugin_option"
+    fi
+    rm -f conftest.*
   fi
 fi
 test -z "$AR_FLAGS" && AR_FLAGS=cru
@@ -11531,7 +11539,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11534 "configure"
+#line 11542 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11637,7 +11645,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11640 "configure"
+#line 11648 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
index 147ca03af571107b03b4ee21a3b05b4198a5741a..c87a05d591af8484b3d529ec0942290078d2ff19 100644 (file)
@@ -1,3 +1,8 @@
+2021-01-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/27173
+       * configure: Regenerated.
+
 2021-01-11  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
 
        * aarch64-asm-2.c: Regenerate.
index 92b4b2247d6928723b4c4b026a18b03529120c59..e9f68df568a480896375a3a426627965b2fd8e18 100755 (executable)
@@ -6641,7 +6641,15 @@ fi
 test -z "$AR" && AR=ar
 if test -n "$plugin_option"; then
   if $AR --help 2>&1 | grep -q "\--plugin"; then
-    AR="$AR $plugin_option"
+    touch conftest.c
+    $AR $plugin_option rc conftest.a conftest.c
+    if test "$?" != 0; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
+    else
+      AR="$AR $plugin_option"
+    fi
+    rm -f conftest.*
   fi
 fi
 test -z "$AR_FLAGS" && AR_FLAGS=cru
@@ -11452,7 +11460,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11455 "configure"
+#line 11463 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11558,7 +11566,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11561 "configure"
+#line 11569 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H