Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 1 | From 1bfae624b27ea4a1f5c5a92050d741b511e7b3d5 Mon Sep 17 00:00:00 2001 |
| 2 | From: Szabolcs Nagy <nsz@port70.net> |
| 3 | Date: Wed, 28 Feb 2018 00:54:05 +0000 |
| 4 | Subject: [PATCH 30/39] ldbl128 config |
| 5 | |
| 6 | Upstream-Status: Pending |
| 7 | |
| 8 | Signed-off-by: Khem Raj <raj.khem@gmail.com> |
| 9 | --- |
| 10 | gcc/configure | 13 +++++++++++++ |
| 11 | gcc/configure.ac | 16 ++++++++++++++-- |
| 12 | 2 files changed, 27 insertions(+), 2 deletions(-) |
| 13 | |
| 14 | diff --git a/gcc/configure b/gcc/configure |
| 15 | index 0788b7bf0b5..eb1a45bb263 100755 |
| 16 | --- a/gcc/configure |
| 17 | +++ b/gcc/configure |
| 18 | @@ -29370,6 +29370,15 @@ if test "${with_long_double_128+set}" = set; then : |
| 19 | withval=$with_long_double_128; gcc_cv_target_ldbl128="$with_long_double_128" |
| 20 | else |
| 21 | |
| 22 | + case "$target" in |
| 23 | + s390*-*-linux-musl*) |
| 24 | + gcc_cv_target_ldbl128=yes |
| 25 | + ;; |
| 26 | + powerpc*-*-linux-musl*) |
| 27 | + gcc_cv_target_ldbl128=no |
| 28 | + ;; |
| 29 | + *) |
| 30 | + |
| 31 | if test $glibc_version_major -gt 2 \ |
| 32 | || ( test $glibc_version_major -eq 2 && test $glibc_version_minor -ge 4 ); then : |
| 33 | gcc_cv_target_ldbl128=yes |
| 34 | @@ -29381,6 +29390,10 @@ else |
| 35 | && gcc_cv_target_ldbl128=yes |
| 36 | |
| 37 | fi |
| 38 | + |
| 39 | + ;; |
| 40 | + esac |
| 41 | + |
| 42 | fi |
| 43 | |
| 44 | ;; |
| 45 | diff --git a/gcc/configure.ac b/gcc/configure.ac |
| 46 | index 5ab50fae0f3..7ffe35ee1c3 100644 |
| 47 | --- a/gcc/configure.ac |
| 48 | +++ b/gcc/configure.ac |
| 49 | @@ -6030,13 +6030,25 @@ case "$target" in |
| 50 | AC_ARG_WITH(long-double-128, |
| 51 | [AS_HELP_STRING([--with-long-double-128], |
| 52 | [use 128-bit long double by default])], |
| 53 | - gcc_cv_target_ldbl128="$with_long_double_128", |
| 54 | + gcc_cv_target_ldbl128="$with_long_double_128", [ |
| 55 | + case "$target" in |
| 56 | + s390*-*-linux-musl*) |
| 57 | + gcc_cv_target_ldbl128=yes |
| 58 | + ;; |
| 59 | + powerpc*-*-linux-musl*) |
| 60 | + gcc_cv_target_ldbl128=no |
| 61 | + ;; |
| 62 | + *)] |
| 63 | [GCC_GLIBC_VERSION_GTE_IFELSE([2], [4], [gcc_cv_target_ldbl128=yes], [ |
| 64 | [gcc_cv_target_ldbl128=no |
| 65 | grep '^[ ]*#[ ]*define[ ][ ]*__LONG_DOUBLE_MATH_OPTIONAL' \ |
| 66 | $target_header_dir/bits/wordsize.h > /dev/null 2>&1 \ |
| 67 | && gcc_cv_target_ldbl128=yes |
| 68 | - ]])]) |
| 69 | + ]])] |
| 70 | + [ |
| 71 | + ;; |
| 72 | + esac |
| 73 | + ]) |
| 74 | ;; |
| 75 | esac |
| 76 | if test x$gcc_cv_target_ldbl128 = xyes; then |
| 77 | -- |
| 78 | 2.25.1 |
| 79 | |