Package: src:libprelude
Version: 1.0.0-1.0.0-11.2
Severity: normal
Tags: patch
User: debian-powe...@lists.debian.org
Usertags: ppc64el
Hi,
These 2 patches address build failures of libprelude on ppc64el.
May you please consider incorporating them into an upload?
Thank you!
1) ppc64el-isnan-tests-fix-for-little-endian-PowerPC.patch
This patch is upstream at gnulib as of May 30th, 2014
(commit e962c07c0c8bb18f9a5969cbf1ddb01d0fe4f55c).
It picks the subset applicable to files carried by libprelude.
It fixes this test-suite error:
PASS: test-isnand-nolibm
PASS: test-isnanf-nolibm
../../test-driver: line 107: 20059 Aborted "$@" >
$log_file 2>&1
FAIL: test-isnanl-nolibm
2) python-libprelude-prefix.patch
This patch makes sure bindings/python/setup.py uses '/usr'
as prefix, since it can vary (occurence of '/usr/local' below).
If the prefix is different then /usr, a build failure occurs
because of a hardcoded '/usr/lib' in override_dh_auto_install:
[...]
debian/rules binary
dh binary --with=quilt,python2,autoreconf
[...]
debian/rules override_dh_auto_install
[...]
dh_auto_install; \
rm -rf debian/tmp/usr/lib/python*; \
find debian/tmp-python-libprelude/usr/lib -name "*.la" -delete;
\
mv debian/tmp-python-libprelude/usr/lib/* debian/tmp/usr/lib/
[...]
find: `debian/tmp-python-libprelude/usr/lib': No such file or directory
mv: cannot stat ‘debian/tmp-python-libprelude/usr/lib/*’: No such file
or directory
make[1]: *** [override_dh_auto_install] Error 1
[...]
--
Mauricio Faria de Oliveira
IBM Linux Technology Center
Index: libprelude-1.0.0/bindings/python/Makefile.am
===================================================================
--- libprelude-1.0.0.orig/bindings/python/Makefile.am
+++ libprelude-1.0.0/bindings/python/Makefile.am
@@ -9,7 +9,7 @@
CC="$(CXX)" $(PYTHON) setup.py build
install-exec-hook:
- $(PYTHON) setup.py install `test -n "$(DESTDIR)" && echo --root $(DESTDIR)`
+ $(PYTHON) setup.py install `test -n "$(DESTDIR)" && echo --root $(DESTDIR)` --prefix /usr
uninstall-hook:
$(PYTHON) setup.py uninstall `test -n "$(DESTDIR)" && echo --root $(DESTDIR)`
curl 'http://git.savannah.gnu.org/gitweb/?p=gnulib.git;a=patch;h=e962c07c0c8bb18f9a5969cbf1ddb01d0fe4f55c' \
| filterdiff \
--strip=1 \
--addoldprefix='a/libmissing/' \
--addnewprefix='b/libmissing/' \
-i '*/tests/test-isnanl.h' \
-i '*/tests/test-signbit.c' \
> 'ppc64el-isnan-tests-fix-for-little-endian-PowerPC.patch'
--- a/libmissing/tests/test-isnanl.h
+++ b/libmissing/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
--- a/libmissing/tests/test-signbit.c
+++ b/libmissing/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