summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-core/coreutils/coreutils/strtod_fix_clash_with_strtold.patch56
-rw-r--r--meta/recipes-core/coreutils/coreutils_8.31.bb (renamed from meta/recipes-core/coreutils/coreutils_8.30.bb)8
2 files changed, 61 insertions, 3 deletions
diff --git a/meta/recipes-core/coreutils/coreutils/strtod_fix_clash_with_strtold.patch b/meta/recipes-core/coreutils/coreutils/strtod_fix_clash_with_strtold.patch
new file mode 100644
index 0000000000..19410715f5
--- /dev/null
+++ b/meta/recipes-core/coreutils/coreutils/strtod_fix_clash_with_strtold.patch
@@ -0,0 +1,56 @@
1From 0562b040fa17f1722ba2b3096067b45d0582ca53 Mon Sep 17 00:00:00 2001
2From: Paul Eggert <eggert@cs.ucla.edu>
3Date: Mon, 11 Mar 2019 16:40:29 -0700
4Subject: [PATCH] strtod: fix clash with strtold
5
6Problem reported for RHEL 5 by Jesse Caldwell (Bug#34817).
7* lib/strtod.c (compute_minus_zero, minus_zero):
8Simplify by remving the macro / external variable,
9and having just a function. User changed. This avoids
10the need for an external variable that might clash.
11
12Upstream-Status: Backported [rhel5]
13
14Signed-off-by: Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>
15
16---
17 ChangeLog | 9 +++++++++
18 lib/strtod.c | 11 +++++------
19 2 files changed, 14 insertions(+), 6 deletions(-)
20
21diff --git a/lib/strtod.c b/lib/strtod.c
22index b9eaa51b4..69b1564e1 100644
23--- a/lib/strtod.c
24+++ b/lib/strtod.c
25@@ -294,16 +294,15 @@ parse_number (const char *nptr,
26 ICC 10.0 has a bug when optimizing the expression -zero.
27 The expression -MIN * MIN does not work when cross-compiling
28 to PowerPC on Mac OS X 10.5. */
29-#if defined __hpux || defined __sgi || defined __ICC
30 static DOUBLE
31-compute_minus_zero (void)
32+minus_zero (void)
33 {
34+#if defined __hpux || defined __sgi || defined __ICC
35 return -MIN * MIN;
36-}
37-# define minus_zero compute_minus_zero ()
38 #else
39-DOUBLE minus_zero = -0.0;
40+ return -0.0;
41 #endif
42+}
43
44 /* Convert NPTR to a DOUBLE. If ENDPTR is not NULL, a pointer to the
45 character after the last one used in the number is put in *ENDPTR. */
46@@ -479,6 +478,6 @@ STRTOD (const char *nptr, char **endptr)
47 /* Special case -0.0, since at least ICC miscompiles negation. We
48 can't use copysign(), as that drags in -lm on some platforms. */
49 if (!num && negative)
50- return minus_zero;
51+ return minus_zero ();
52 return negative ? -num : num;
53 }
54--
552.20.1
56
diff --git a/meta/recipes-core/coreutils/coreutils_8.30.bb b/meta/recipes-core/coreutils/coreutils_8.31.bb
index 8f4ee55712..4a74f619af 100644
--- a/meta/recipes-core/coreutils/coreutils_8.30.bb
+++ b/meta/recipes-core/coreutils/coreutils_8.31.bb
@@ -6,7 +6,7 @@ HOMEPAGE = "http://www.gnu.org/software/coreutils/"
6BUGTRACKER = "http://debbugs.gnu.org/coreutils" 6BUGTRACKER = "http://debbugs.gnu.org/coreutils"
7LICENSE = "GPLv3+" 7LICENSE = "GPLv3+"
8LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504\ 8LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504\
9 file://src/ls.c;beginline=1;endline=15;md5=dbe356a88b09c29232b083d1ff8ac82a" 9 file://src/ls.c;beginline=1;endline=15;md5=c456f9896277a0543e3866777ccc0255"
10DEPENDS = "gmp libcap" 10DEPENDS = "gmp libcap"
11DEPENDS_class-native = "" 11DEPENDS_class-native = ""
12 12
@@ -20,8 +20,10 @@ SRC_URI = "${GNU_MIRROR}/coreutils/${BP}.tar.xz \
20 file://0001-local.mk-fix-cross-compiling-problem.patch \ 20 file://0001-local.mk-fix-cross-compiling-problem.patch \
21 " 21 "
22 22
23SRC_URI[md5sum] = "ab06d68949758971fe744db66b572816" 23SRC_URI_append_libc-musl = "file://strtod_fix_clash_with_strtold.patch"
24SRC_URI[sha256sum] = "e831b3a86091496cdba720411f9748de81507798f6130adeaef872d206e1b057" 24
25SRC_URI[md5sum] = "0009a224d8e288e8ec406ef0161f9293"
26SRC_URI[sha256sum] = "ff7a9c918edce6b4f4b2725e3f9b37b0c4d193531cac49a48b56c4d0d3a9e9fd"
25 27
26EXTRA_OECONF_class-native = "--without-gmp" 28EXTRA_OECONF_class-native = "--without-gmp"
27EXTRA_OECONF_class-target = "--enable-install-program=arch,hostname --libexecdir=${libdir}" 29EXTRA_OECONF_class-target = "--enable-install-program=arch,hostname --libexecdir=${libdir}"