public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: "Paul E. Murphy" <murphyp@linux.vnet.ibm.com>
To: libc-alpha@sourceware.org
Subject: [PATCH v3 4/6] powerpc64le: bump binutils version requirement to >= 2.26
Date: Mon,  6 Apr 2020 14:12:37 -0500	[thread overview]
Message-ID: <c5c4a635e96b9c53311f27d58cfde2ed5f79b5c6.1586199342.git.murphyp@linux.vnet.ibm.com> (raw)
In-Reply-To: <cover.1586199342.git.murphyp@linux.vnet.ibm.com>

This is a small step up from 2.25 which brings in support for
rewriting the .gnu.attributes section of libc/libm.so.

Reviewed-by: Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
---
 INSTALL                                   |  4 ++
 manual/install.texi                       |  4 ++
 sysdeps/powerpc/powerpc64/le/configure    | 65 +++++++++++++++++++++++
 sysdeps/powerpc/powerpc64/le/configure.ac |  6 +++
 4 files changed, 79 insertions(+)

diff --git a/INSTALL b/INSTALL
index d7c109358c..551ca9434e 100644
--- a/INSTALL
+++ b/INSTALL
@@ -495,6 +495,10 @@ build the GNU C Library:
      moment.  As of release time, GNU 'binutils' 2.32 is the newest
      verified to work to build the GNU C Library.
 
+     For PowerPC 64-bits little-endian (powerpc64le), binutils is
+     required to support the '--update-section'.  This option requires
+     binutils 2.26 or newer.
+
    * GNU 'texinfo' 4.7 or later
 
      To correctly translate and install the Texinfo documentation you
diff --git a/manual/install.texi b/manual/install.texi
index 66de8ea59b..acbcc8c091 100644
--- a/manual/install.texi
+++ b/manual/install.texi
@@ -533,6 +533,10 @@ No other assembler or linker has the necessary functionality at the
 moment. As of release time, GNU @code{binutils} 2.32 is the newest
 verified to work to build @theglibc{}.
 
+For PowerPC 64-bits little-endian (powerpc64le), binutils is required
+to support the @option{--update-section}.  This option requires binutils
+2.26 or newer.
+
 @item
 GNU @code{texinfo} 4.7 or later
 
diff --git a/sysdeps/powerpc/powerpc64/le/configure b/sysdeps/powerpc/powerpc64/le/configure
index 4b4d6cff6f..b08c3e0587 100644
--- a/sysdeps/powerpc/powerpc64/le/configure
+++ b/sysdeps/powerpc/powerpc64/le/configure
@@ -90,5 +90,70 @@ if test "$libc_cv_compiler_powerpc64le_ice" != "yes"; then :
   critic_missing="$critic_missing __builtin_signbit is broken. GCC 7.4 or newer is required to resolve (BZ 83862)."
 fi
 
+# Binutils (objcopy) 2.26 or newer required to support the --update-section
+# feature for fixing up .gnu.attribute section with IEEE ldbl.
+for ac_prog in $OBJCOPY
+do
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_prog_OBJCOPY+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$OBJCOPY"; then
+  ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+    ac_cv_prog_OBJCOPY="$ac_prog"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+OBJCOPY=$ac_cv_prog_OBJCOPY
+if test -n "$OBJCOPY"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
+$as_echo "$OBJCOPY" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+  test -n "$OBJCOPY" && break
+done
+
+if test -z "$OBJCOPY"; then
+  ac_verc_fail=yes
+else
+  # Found it, now check the version.
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of $OBJCOPY" >&5
+$as_echo_n "checking version of $OBJCOPY... " >&6; }
+  ac_prog_version=`$OBJCOPY --version 2>&1 | sed -n 's/^.*GNU objcopy.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
+  case $ac_prog_version in
+    '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
+    2.1[0-9][0-9]*|2.2[6-9]*|2.[3-9][0-9]*|[3-9].*|[1-9][0-9]*)
+       ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
+    *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
+
+  esac
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_prog_version" >&5
+$as_echo "$ac_prog_version" >&6; }
+fi
+if test $ac_verc_fail = yes; then
+  AS=: critic_missing="$critic_missing objcopy >= 2.26 is required on powerpc64le"
+fi
+
 
 test -n "$critic_missing" && as_fn_error $? "*** $critic_missing" "$LINENO" 5
diff --git a/sysdeps/powerpc/powerpc64/le/configure.ac b/sysdeps/powerpc/powerpc64/le/configure.ac
index 26a54beaa0..630086bd88 100644
--- a/sysdeps/powerpc/powerpc64/le/configure.ac
+++ b/sysdeps/powerpc/powerpc64/le/configure.ac
@@ -51,5 +51,11 @@ CFLAGS="$save_CFLAGS"])
 AS_IF([test "$libc_cv_compiler_powerpc64le_ice" != "yes"],
       [critic_missing="$critic_missing __builtin_signbit is broken. GCC 7.4 or newer is required to resolve (BZ 83862)."])
 
+# Binutils (objcopy) 2.26 or newer required to support the --update-section
+# feature for fixing up .gnu.attribute section with IEEE ldbl.
+AC_CHECK_PROG_VER(OBJCOPY, $OBJCOPY, --version,
+		  [GNU objcopy.* \([0-9]*\.[0-9.]*\)],
+		  [2.1[0-9][0-9]*|2.2[6-9]*|2.[3-9][0-9]*|[3-9].*|[1-9][0-9]*],
+		  AS=: critic_missing="$critic_missing objcopy >= 2.26 is required on powerpc64le")
 
 test -n "$critic_missing" && AC_MSG_ERROR([*** $critic_missing])
-- 
2.21.1


  parent reply	other threads:[~2020-04-06 19:12 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-06 19:12 [PATCH v3 0/6] IEEE binary128 long double on powerpc64le Paul E. Murphy
2020-04-06 19:12 ` [PATCH v3 1/6] ldbl-128ibm-compat: workaround GCC 9 C++ BZ 90731 Paul E. Murphy
2020-04-15 14:20   ` Paul E Murphy
2020-04-22 14:58     ` Paul E Murphy
2020-04-22 15:11   ` Florian Weimer
2020-04-22 21:17     ` Paul E Murphy
2020-04-23  5:48       ` Florian Weimer
2020-04-06 19:12 ` [PATCH v3 2/6] Rename __LONG_DOUBLE_USES_FLOAT128 to __LDOUBLE_REDIRECTS_TO_FLOAT128_ABI Paul E. Murphy
2020-04-15 14:21   ` Paul E Murphy
2020-04-22 14:59     ` Paul E Murphy
2020-04-06 19:12 ` [PATCH v3 3/6] powerpc64le: raise GCC requirement to 7.4 for long double transition Paul E. Murphy
2020-04-22 15:19   ` Florian Weimer
2020-04-22 19:33     ` Paul E Murphy
2020-04-06 19:12 ` Paul E. Murphy [this message]
2020-04-22 15:20   ` [PATCH v3 4/6] powerpc64le: bump binutils version requirement to >= 2.26 Florian Weimer
2020-04-06 19:12 ` [PATCH v3 5/6] powerpc64le: blacklist broken GCC compilers (e.g GCC 7.5.0) Paul E. Murphy
2020-04-22 15:23   ` Florian Weimer
2020-04-06 19:12 ` [PATCH v3 6/6] powerpc64le: Enable support for IEEE long double Paul E. Murphy
2020-04-22 15:03   ` Paul E Murphy
2020-04-22 15:15   ` Florian Weimer
2020-04-22 16:20     ` Paul E Murphy
2020-04-22 16:23       ` Florian Weimer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c5c4a635e96b9c53311f27d58cfde2ed5f79b5c6.1586199342.git.murphyp@linux.vnet.ibm.com \
    --to=murphyp@linux.vnet.ibm.com \
    --cc=libc-alpha@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).