diff --git a/coreutils-gnulib-tests-ppc64le.patch b/coreutils-gnulib-tests-ppc64le.patch new file mode 100644 index 0000000..ee05437 --- /dev/null +++ b/coreutils-gnulib-tests-ppc64le.patch @@ -0,0 +1,41 @@ +diff --git a/gnulib-tests/test-isnanl.h b/gnulib-tests/test-isnanl.h +index 06e6a7c..2df10f8 100644 +--- a/gnulib-tests/test-isnanl.h ++++ b/gnulib-tests/test-isnanl.h +@@ -51,6 +51,15 @@ main () + /* A bit pattern that is different from a Quiet NaN. With a bit of luck, + it's a Signalling NaN. */ + { ++#if defined __powerpc__ && LDBL_MANT_DIG == 106 ++ /* This is PowerPC "double double", a pair of two doubles. Inf and Nan are ++ represented as the corresponding 64-bit IEEE values in the first double; ++ the second is ignored. Manipulate only the first double. */ ++ #undef NWORDS ++ #define NWORDS \ ++ ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int)) ++#endif ++ + memory_long_double m; + m.value = NaNl (); + # if LDBL_EXPBIT0_BIT > 0 +diff --git a/gnulib-tests/test-signbit.c b/gnulib-tests/test-signbit.c +index e8ea097..7e24292 100644 +--- a/gnulib-tests/test-signbit.c ++++ b/gnulib-tests/test-signbit.c +@@ -151,6 +151,16 @@ test_signbitl () + #define NWORDS \ + ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int)) + typedef union { long double value; unsigned int word[NWORDS]; } memory_long_double; ++ ++#if defined __powerpc__ && LDBL_MANT_DIG == 106 ++ /* This is PowerPC "double double", a pair of two doubles. Inf and Nan are ++ represented as the corresponding 64-bit IEEE values in the first double; ++ the second is ignored. Manipulate only the first double. */ ++ #undef NWORDS ++ #define NWORDS \ ++ ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int)) ++#endif ++ + memory_long_double m; + m.value = zerol / zerol; + # if LDBL_EXPBIT0_BIT > 0 diff --git a/coreutils-testsuite.changes b/coreutils-testsuite.changes index b2028ba..7aa0916 100644 --- a/coreutils-testsuite.changes +++ b/coreutils-testsuite.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Dec 19 23:37:39 UTC 2013 - uweigand@de.ibm.com + +- coreutils-gnulib-tests-ppc64le.patch: Fix imported gnulib long double + math tests for little-endian PowerPC. + ------------------------------------------------------------------- Thu Dec 19 22:54:26 UTC 2013 - mail@bernhard-voelker.de diff --git a/coreutils-testsuite.spec b/coreutils-testsuite.spec index 9003ea4..0ea9094 100644 --- a/coreutils-testsuite.spec +++ b/coreutils-testsuite.spec @@ -106,6 +106,9 @@ Patch200: coreutils-gnulib-tests-fix-nap-race.patch # a bit more to avoid failures on OBS. Patch201: coreutils-gnulib-tests-fix-nap-race-obs.patch +# Fix imported gnulib long double math tests for little-endian PowerPC +Patch202: coreutils-gnulib-tests-ppc64le.patch + # ================================================ %description These are the GNU core utilities. This package is the union of @@ -136,6 +139,7 @@ the GNU fileutils, sh-utils, and textutils packages. %patch200 %patch201 +%patch202 -p1 xz -dc %{S:2} >po/de.po diff --git a/coreutils.changes b/coreutils.changes index b2028ba..7aa0916 100644 --- a/coreutils.changes +++ b/coreutils.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Dec 19 23:37:39 UTC 2013 - uweigand@de.ibm.com + +- coreutils-gnulib-tests-ppc64le.patch: Fix imported gnulib long double + math tests for little-endian PowerPC. + ------------------------------------------------------------------- Thu Dec 19 22:54:26 UTC 2013 - mail@bernhard-voelker.de diff --git a/coreutils.spec b/coreutils.spec index ab0e30b..2d1d888 100644 --- a/coreutils.spec +++ b/coreutils.spec @@ -106,6 +106,9 @@ Patch200: coreutils-gnulib-tests-fix-nap-race.patch # a bit more to avoid failures on OBS. Patch201: coreutils-gnulib-tests-fix-nap-race-obs.patch +# Fix imported gnulib long double math tests for little-endian PowerPC +Patch202: coreutils-gnulib-tests-ppc64le.patch + # ================================================ %description These are the GNU core utilities. This package is the union of @@ -136,6 +139,7 @@ the GNU fileutils, sh-utils, and textutils packages. %patch200 %patch201 +%patch202 -p1 xz -dc %{S:2} >po/de.po