Your message dated Thu, 09 Oct 2014 12:04:28 +0000
with message-id <[email protected]>
and subject line Bug#695296: fixed in libunwind 1.1-3.1
has caused the Debian Bug report #695296,
regarding libunwind: Add test suite execution on amd64
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
695296: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=695296
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: libunwind
Version: 1.0.1-4
Severity: normal
Tags: patch
User: [email protected]
Usertags: origin-ubuntu raring ubuntu-patch
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Dear Maintainer,
In Ubuntu, the attached patch was applied to achieve the following:
* Enable test suite for amd64 architecture:
+ d/rules: Execute test suite when building for amd64 only.
+ d/patches/20122307_fix_setjmp.patch: Cherry picked fix from upstream
VCS to fixup setjmp test failure.
+ d/patches/20123007_disable_known_test_failures.patch: Disable *-dyn1
tests as they use unsupported features on amd64.
+ d/patches/20123007_workaround_ltest-nocalloc.patch: Make dummy call to
do_backtrace to ensure that malloc is not called post thread init.
+ d/patches/20123007_workaround_test-ptrace.patch: Walk default test
arguments to ensure child process has visibility.
The libunwind test suite is only really usable on amd64 but it serves as a
useful canary for any core integration issues.
Thanks for considering the patch.
- -- System Information:
Debian Release: wheezy/sid
APT prefers quantal-updates
APT policy: (500, 'quantal-updates'), (500, 'quantal-security'), (500,
'quantal')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.5.0-19-generic (SMP w/8 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iQIcBAEBCAAGBQJQwOUvAAoJEL/srsug59jDmeEP/jXBaUkqlmG0CuMFqJ7qEiPk
dA3yw0Do2Cjjj+/Ju1L9F2vS5vI17b/aDHql4OgY677tA1YET7G4rJvG53AVtldz
OL4O0EaPtbce0XtzWAHM8AEjVlgoiyBclQtzK3QinZTFf9ymAjYx4pLl3p+VacY2
z1KS/TWMklgrdTbuDMISf4yLVdTaQ5Omkd9cROf3xwIvww3wf0wwQ41u+MhAD+Uk
34vL8nczVWD/kbSru7u0t/tV4mkljBdD+PHAZraPB+XOkz65u3FKPbn7piIgRttz
U1JiSSA5QOyWfd/HEt8cHLimH/EZ+IzdalBlzNOWugfx1d0aZsEb7VAn+LnOU3/g
AprDr52UfvTKUMCa92MDKlZcTRsvE/IPLVwpuOnPTCKG0ExrbVqNEs/BAiAIvwnV
Fvu03ERedK+9U3trHsCqDPLvinQmyZ8HvlcnUu+ySp0jGLHhafpLqr+Pcee7GtG4
WkdcCbyp0imFqwegWpFad5wE43pYKUeSAB+fPxgUzGA1mmocTccAAMDDdKUAmMG6
DfTdaw3OiUW7I1XBEuPsxFgbGhj1cac/L4KttrnkCnP0bxD5XZdbyvIErpC7alqa
Qjl0JQig14BaYi+CUTahwVPxzgVNmAmJqK6UOv0wBozGk5ZqB6GQpsBmF/dmil4R
gEx8JYfh3QwBnBu9LtFf
=eeth
-----END PGP SIGNATURE-----
diff -Nru libunwind-1.0.1/debian/changelog libunwind-1.0.1/debian/changelog
diff -Nru libunwind-1.0.1/debian/patches/20122307_fix_setjmp.patch libunwind-1.0.1/debian/patches/20122307_fix_setjmp.patch
--- libunwind-1.0.1/debian/patches/20122307_fix_setjmp.patch 1970-01-01 01:00:00.000000000 +0100
+++ libunwind-1.0.1/debian/patches/20122307_fix_setjmp.patch 2012-07-30 10:10:02.000000000 +0100
@@ -0,0 +1,109 @@
+From 297d9cd07d7ea9b541fb13bffe418c8b2a8c3aa6 Mon Sep 17 00:00:00 2001
+From: Paul Pluzhnikov <[email protected]>
+Date: Tue, 15 Nov 2011 07:45:09 +0000
+Subject: Fix for failing test-setjmp
+
+On Mon, Nov 14, 2011 at 5:02 PM, Paul Pluzhnikov <[email protected]> wrote:
+
+> P.S. test-setjmp is failing for me (before or after the patch).
+> When I enable assertions (to confirm my new assertions are correct), I see:
+>
+> lt-test-setjmp: ../../src/dwarf/Gparser.c:754: apply_reg_state: \
+> Assertion `rs->reg[17].where == DWARF_WHERE_EXPR' failed.
+>
+> which likely explains that failure.
+
+The problem is actually two-fold:
+
+First, the loops in {sig,}longjmp.c are "do { ... } while (unw_step() >= 0);"
+
+But unw_step() returns 0 on reaching the end of the chain (_start),
+and the loop should stop there.
+
+The second problem is that with this commit:
+ http://repo.or.cz/w/glibc.git/commitdiff/c67da0b50e3d20f89d7bb352cd67dcf66d808e50
+glibc obfuscates value of SP in jmp_buf, so we might as well just give up.
+
+Patch attached.
+
+Thanks,
+--
+Paul Pluzhnikov
+---
+Index: libunwind/src/setjmp/longjmp.c
+===================================================================
+--- libunwind.orig/src/setjmp/longjmp.c 2012-07-23 10:59:17.449688000 +0100
++++ libunwind/src/setjmp/longjmp.c 2012-07-23 11:00:31.632589776 +0100
+@@ -34,6 +34,20 @@
+ #include "jmpbuf.h"
+ #include "setjmp_i.h"
+
++#if defined(__GLIBC__) && __GLIBC_PREREQ(2, 4)
++
++/* Starting with glibc-2.4, {sig,}setjmp in GLIBC obfuscates the
++ register values in jmp_buf by XORing them with a "random"
++ canary value.
++
++ This makes it impossible to implement longjmp, as we
++ can never match wp[JB_SP], unless we decode the canary first.
++
++ Doing so is possible, but doesn't appear to be worth the trouble,
++ so we simply defer to glibc longjmp here. */
++
++#else
++
+ void
+ _longjmp (jmp_buf env, int val)
+ {
+@@ -74,7 +88,7 @@
+
+ abort ();
+ }
+- while (unw_step (&c) >= 0);
++ while (unw_step (&c) > 0);
+
+ abort ();
+ }
+@@ -89,4 +103,6 @@
+ _longjmp (env, val);
+ }
+
++#endif /* __GLIBC__ */
++
+ #endif
+Index: libunwind/src/setjmp/siglongjmp.c
+===================================================================
+--- libunwind.orig/src/setjmp/siglongjmp.c 2012-07-23 10:59:17.449688000 +0100
++++ libunwind/src/setjmp/siglongjmp.c 2012-07-23 11:00:31.632589776 +0100
+@@ -35,6 +35,20 @@
+ # define _NSIG (_SIG_MAXSIG - 1)
+ #endif
+
++#if defined(__GLIBC__) && __GLIBC_PREREQ(2, 4)
++
++/* Starting with glibc-2.4, {sig,}setjmp in GLIBC obfuscates the
++ register values in jmp_buf by XORing them with a "random"
++ canary value.
++
++ This makes it impossible to implement longjmp, as we
++ can never match wp[JB_SP], unless we decode the canary first.
++
++ Doing so is possible, but doesn't appear to be worth the trouble,
++ so we simply defer to glibc siglongjmp here. */
++
++#else
++
+ void
+ siglongjmp (sigjmp_buf env, int val)
+ {
+@@ -96,7 +110,9 @@
+
+ abort ();
+ }
+- while (unw_step (&c) >= 0);
++ while (unw_step (&c) > 0);
+
+ abort ();
+ }
++
++#endif /* __GLIBC__ */
diff -Nru libunwind-1.0.1/debian/patches/20123007_disable_known_test_failures.patch libunwind-1.0.1/debian/patches/20123007_disable_known_test_failures.patch
--- libunwind-1.0.1/debian/patches/20123007_disable_known_test_failures.patch 1970-01-01 01:00:00.000000000 +0100
+++ libunwind-1.0.1/debian/patches/20123007_disable_known_test_failures.patch 2012-07-30 12:09:41.000000000 +0100
@@ -0,0 +1,19 @@
+Description: Some tests within the libunwind test suite
+ are known failures (see Origin and README for verification of this).
+ .
+ The package currently only executes tests for amd64:
+ - *-dyn1 tests use feature which are not avaliable on this arch
+Origin: http://lists.nongnu.org/archive/html/libunwind-devel/2012-07/msg00005.html
+
+Index: libunwind/tests/Makefile.am
+===================================================================
+--- libunwind.orig/tests/Makefile.am 2012-07-30 10:05:35.271168000 +0100
++++ libunwind/tests/Makefile.am 2012-07-30 11:57:02.332769610 +0100
+@@ -41,7 +41,6 @@
+ Gtest-init Ltest-init \
+ Gtest-concurrent Ltest-concurrent \
+ Gtest-resume-sig Ltest-resume-sig \
+- Gtest-dyn1 Ltest-dyn1 \
+ Gtest-trace Ltest-trace \
+ test-async-sig test-flush-cache test-init-remote \
+ test-mem test-setjmp test-ptrace \
diff -Nru libunwind-1.0.1/debian/patches/20123007_workaround_ltest-nocalloc.patch libunwind-1.0.1/debian/patches/20123007_workaround_ltest-nocalloc.patch
--- libunwind-1.0.1/debian/patches/20123007_workaround_ltest-nocalloc.patch 1970-01-01 01:00:00.000000000 +0100
+++ libunwind-1.0.1/debian/patches/20123007_workaround_ltest-nocalloc.patch 2012-07-30 10:21:11.000000000 +0100
@@ -0,0 +1,22 @@
+Description: Make dummy call to backtrace from thread creation to ensure
+ that libunwind per-thread state only gets initialized once resulting
+ in no futher calls to calloc.
+ .
+ This can create issues if libunwind is being used within a signal handler
+ (such as provided by google-perftools).
+Origin: https://groups.google.com/forum/#!msg/google-perftools/Df10Uy4Djrg/XzbESvLZhiYJ
+Forwarded: not-needed
+
+Index: libunwind/tests/Gtest-nocalloc.c
+===================================================================
+--- libunwind.orig/tests/Gtest-nocalloc.c 2012-07-30 10:05:35.271168000 +0100
++++ libunwind/tests/Gtest-nocalloc.c 2012-07-30 10:17:34.794107721 +0100
+@@ -123,6 +123,8 @@
+ if (pthread_key_create (&key, NULL))
+ panic ("FAILURE: unable to create key %d\n", i);
+ }
++ do_backtrace();
++ num_mallocs = num_callocs = 0;
+ foo1 ();
+ num_errors = num_mallocs + num_callocs;
+ if (num_errors > 0)
diff -Nru libunwind-1.0.1/debian/patches/20123007_workaround_test-ptrace.patch libunwind-1.0.1/debian/patches/20123007_workaround_test-ptrace.patch
--- libunwind-1.0.1/debian/patches/20123007_workaround_test-ptrace.patch 1970-01-01 01:00:00.000000000 +0100
+++ libunwind-1.0.1/debian/patches/20123007_workaround_test-ptrace.patch 2012-07-30 11:39:41.000000000 +0100
@@ -0,0 +1,16 @@
+Index: libunwind/tests/test-ptrace.c
+===================================================================
+--- libunwind.orig/tests/test-ptrace.c 2012-07-30 10:05:35.271168000 +0100
++++ libunwind/tests/test-ptrace.c 2012-07-30 11:39:37.309158623 +0100
+@@ -182,6 +182,11 @@
+
+ /* automated test case */
+ argv = args;
++
++ /* Unless the args array is 'walked' the child
++ process is unable to access it and dies with a segfault */
++ fprintf(stderr, "Automated test (%s,%s,%s,%s)\n",
++ args[0],args[1],args[2],args[3]);
+ }
+ else if (argc > 1)
+ while (argv[optind][0] == '-')
diff -Nru libunwind-1.0.1/debian/patches/series libunwind-1.0.1/debian/patches/series
--- libunwind-1.0.1/debian/patches/series 2012-09-17 06:32:11.000000000 +0100
+++ libunwind-1.0.1/debian/patches/series 2012-12-06 18:31:40.000000000 +0000
@@ -2,3 +2,7 @@
20120422_tests_Makefile_am.patch
20120704_fix_arm_ftbfs.patch
20120707_ia64_FTBFS.patch
+20122307_fix_setjmp.patch
+20123007_workaround_ltest-nocalloc.patch
+20123007_disable_known_test_failures.patch
+20123007_workaround_test-ptrace.patch
diff -Nru libunwind-1.0.1/debian/rules libunwind-1.0.1/debian/rules
--- libunwind-1.0.1/debian/rules 2012-09-17 06:32:11.000000000 +0100
+++ libunwind-1.0.1/debian/rules 2012-11-14 11:22:58.000000000 +0000
@@ -5,7 +5,6 @@
#export DH_VERBOSE=1
export DEB_BUILD_MAINT_OPTIONS = hardening=-all,+format
-DEB_BUILD_OPTIONS=nocheck
%:
dh $@ --parallel --with autoreconf
@@ -22,6 +21,15 @@
override_dh_installchangelogs:
dh_installchangelogs ChangeLog
+override_dh_auto_test:
+ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
+# Test suite is only useful on amd64 architecture;
+# other ARCH's have quite a few know test faulures.
+ifeq (amd64, $(DEB_BUILD_ARCH))
+ $(MAKE) check
+endif # amd64
+endif # nocheck
+
override_dh_strip:
dh_strip -plibunwind8 --dbg-package=libunwind8-dbg
dh_strip -plibunwind-setjmp0 --dbg-package=libunwind-setjmp0-dbg
--- End Message ---
--- Begin Message ---
Source: libunwind
Source-Version: 1.1-3.1
We believe that the bug you reported is fixed in the latest version of
libunwind, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Matthias Klose <[email protected]> (supplier of updated libunwind package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Format: 1.8
Date: Thu, 09 Oct 2014 13:41:49 +0200
Source: libunwind
Binary: libunwind8-dev libunwind8 libunwind8-dbg libunwind-setjmp0-dev
libunwind-setjmp0 libunwind-setjmp0-dbg
Architecture: source amd64
Version: 1.1-3.1
Distribution: unstable
Urgency: medium
Maintainer: Daigo Moriwaki <[email protected]>
Changed-By: Matthias Klose <[email protected]>
Description:
libunwind-setjmp0 - libunwind-based non local goto - runtime
libunwind-setjmp0-dbg - libunwind-based non local goto - runtime
libunwind-setjmp0-dev - libunwind-based non local goto - development
libunwind8 - library to determine the call-chain of a program - runtime
libunwind8-dbg - library to determine the call-chain of a program - runtime
libunwind8-dev - library to determine the call-chain of a program - development
Closes: 695296 734463 753571
Changes:
libunwind (1.1-3.1) unstable; urgency=medium
.
* Non-maintainer upload.
* Apply patches from Ubuntu. Closes: #753571.
- d/p/AArch64-port.diff: Add Aarch64 port.
- d/p/ppc64el.diff: Add PPC64 LE port.
- d/patches/fix-lzma-linking.patch: Fix lzma linking for all supported
architectures.
* Enable test suite for amd64 architecture (James Page). Closes: #695296.
* Build for powerpcspe (Roland Stigge). Closes: #734463.
Checksums-Sha1:
0f461d8349271a8a0180418e9d83a23bfb7a7e7b 2117 libunwind_1.1-3.1.dsc
bdba1803f7ccaf118fb009a319847d222d39ecd1 23728 libunwind_1.1-3.1.debian.tar.xz
35e6d222fdb494d150822f83b7922504e9d3ec5e 346234
libunwind8-dev_1.1-3.1_amd64.deb
e8758cff00943181b42c4db38700d23d2ccbb6e1 50674 libunwind8_1.1-3.1_amd64.deb
dbefdea6f95b141aca34fc9fa6b6e27cf121b554 268438
libunwind8-dbg_1.1-3.1_amd64.deb
edbaa782fb2bb5446e3f3a1f60909b1b80a7169b 18398
libunwind-setjmp0-dev_1.1-3.1_amd64.deb
a34585a38491ac19bbaf23c00e755b40c1d765b6 10364
libunwind-setjmp0_1.1-3.1_amd64.deb
5ca796fddb92f998ec175683b7175190351f6df4 16844
libunwind-setjmp0-dbg_1.1-3.1_amd64.deb
Checksums-Sha256:
d5a88b884f9d28ff4763f766699653967dbede38e8ebe6474a2ee62286c1080f 2117
libunwind_1.1-3.1.dsc
f4f79cfc50a86bdd9dc9484de64dccde5075499cef08b6fb84d36a8107e9d678 23728
libunwind_1.1-3.1.debian.tar.xz
10d28cf1b640116673286a3e22425ebff9cd3d6d7708f741a69128c5d15c9dba 346234
libunwind8-dev_1.1-3.1_amd64.deb
faa6c4d01dee10f6bc41128f27f37bfa3137d5f9d8c5efabe0b0e0e144dfcb40 50674
libunwind8_1.1-3.1_amd64.deb
718f6508aed314e92dda1385e7af9aedab9d14dc8552b01ea0069556c756122f 268438
libunwind8-dbg_1.1-3.1_amd64.deb
2a79949be4c37934f4cc06abc33a2c0ffad0f7b951fe471db8b7f271f738067e 18398
libunwind-setjmp0-dev_1.1-3.1_amd64.deb
a5ce8c1b024a14e1b170f41009daea0e832307effe4a5a18b9378c5c9c224aee 10364
libunwind-setjmp0_1.1-3.1_amd64.deb
32c2bde79bf0c8112eea5f92aaf1fa12ae37a65c7553319cc975694993cd53e8 16844
libunwind-setjmp0-dbg_1.1-3.1_amd64.deb
Files:
7de528dd8a4620d97ee30dc1a506be6e 2117 libs optional libunwind_1.1-3.1.dsc
2d2b14fbc3d1c8b826ce463e010a37a3 23728 libs optional
libunwind_1.1-3.1.debian.tar.xz
1256f21d06a6db580deb738d659425d5 346234 libdevel optional
libunwind8-dev_1.1-3.1_amd64.deb
1be727c03a129042fb47d1d8ef3e6d0f 50674 libs optional
libunwind8_1.1-3.1_amd64.deb
fc0c1b9556ed4949644ce65740c54461 268438 debug extra
libunwind8-dbg_1.1-3.1_amd64.deb
ea1073f4874e7f82e4db9b19aa55c13f 18398 libdevel optional
libunwind-setjmp0-dev_1.1-3.1_amd64.deb
1cab25c1fef9afb008a0504950f9fbf9 10364 libs optional
libunwind-setjmp0_1.1-3.1_amd64.deb
3b50e2b5b079788a4cb273a8948f1df7 16844 debug extra
libunwind-setjmp0-dbg_1.1-3.1_amd64.deb
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
iEYEARECAAYFAlQ2eSQACgkQStlRaw+TLJwHKACgwxnmfYggH2YEFwCHfJeZAXj+
REAAn0l0Dy/8sWoQKaZKIS7oYja0+foh
=60uf
-----END PGP SIGNATURE-----
--- End Message ---