[ppl] 27/68: Imported Debian patch 0.10.2-5
Andreas Tille
tille at debian.org
Sat Nov 12 08:40:52 UTC 2016
This is an automated email from the git hooks/post-receive script.
tille pushed a commit to branch master
in repository ppl.
commit 5987eebcc7973387d903436f7ecdda47ca2ef7f6
Author: Michael Tautschnig <mt at debian.org>
Date: Sun Feb 28 10:35:31 2010 +0100
Imported Debian patch 0.10.2-5
---
debian/changelog | 11 +
debian/control | 2 +-
...1fa465112d1f5519310f47de08494b765c420b8f.debian | 85 +++++++
.../3bbfa4bc9da9558d0b538c95c00607b2928bb9d1 | 22 ++
...777f298702f1005f6c4f026fb7a4663bb8dadd0e.debian | 39 +++
.../7ba6445b1c5adb835e27d2f005779d4343721d21 | 281 +++++++++++++++++++++
...8ac2c64c2e9fa2da2d02428fe51c34b8dca3d6ff.debian | 156 ++++++++++++
...9a89bb0a926a098a6e06a18c36881786f45d678b.debian | 27 ++
...9b0ba93300fb829608d40e766b9f3f95c81962e1.debian | 124 +++++++++
.../9ba82c5fb51ff9f63818fa8c6f006a1900a70894 | 88 +++++++
...9bdd6617be52573d3252687844d32001e671a126.debian | 79 ++++++
.../bad1f4e90af2d1368fee383f08c59316182de8dc | 133 ++++++++++
debian/patches/debian-changes-0.10.2-5 | 75 ++++++
.../eab6ab2fd4e44c8e7348c26112e4c9e4190e88ee | 113 +++++++++
.../f0cd7dc9899fc7dac2580a97da69e6282bfc0576 | 86 +++++++
debian/patches/series | 13 +
debian/rules | 3 +-
17 files changed, 1334 insertions(+), 3 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index dfdeae0..46a5ad5 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,14 @@
+ppl (0.10.2-5) unstable; urgency=low
+
+ * Dropped versioned build dep on libgmp3-dev as even etch has a sufficiently
+ new version.
+ * Dropped build dep on quilt.
+ * Added upstream patches to work around incomplete signal handling on hurd.
+ * Disable 2 Prolog tests as there is some failure on PowerPC only that I'm
+ unable to debug. Closes: #570387.
+
+ -- Michael Tautschnig <mt at debian.org> Sun, 28 Feb 2010 10:35:31 +0100
+
ppl (0.10.2-4) unstable; urgency=low
* Switch to dpkg-source 3.0 (quilt) format, removed quilt-related code from
diff --git a/debian/control b/debian/control
index a211744..a0d60e8 100644
--- a/debian/control
+++ b/debian/control
@@ -4,7 +4,7 @@ Priority: optional
Maintainer: Debian GCC Maintainers <debian-gcc at lists.debian.org>
Uploaders: Michael Tautschnig <mt at debian.org>, Arthur Loiret <aloiret at debian.org>
Standards-Version: 3.8.4
-Build-Depends: debhelper (>= 6.0.7~), quilt, libgmp3-dev (>= 4.1.3), autoconf, automake, libtool, autotools-dev, swi-prolog [!hurd-i386 !kfreebsd-amd64 !kfreebsd-i386]
+Build-Depends: debhelper (>= 6.0.7~), libgmp3-dev, autoconf, automake, libtool, autotools-dev, swi-prolog [!hurd-i386 !kfreebsd-amd64 !kfreebsd-i386]
Build-Depends-Indep: doxygen, graphviz, texlive-base-bin, texlive-latex-extra, texlive-latex-recommended, texlive-fonts-recommended, xpdf-utils | poppler-utils, ghostscript, texlive-extra-utils
Homepage: http://www.cs.unipr.it/ppl/
diff --git a/debian/patches/1fa465112d1f5519310f47de08494b765c420b8f.debian b/debian/patches/1fa465112d1f5519310f47de08494b765c420b8f.debian
new file mode 100644
index 0000000..01cfae6
--- /dev/null
+++ b/debian/patches/1fa465112d1f5519310f47de08494b765c420b8f.debian
@@ -0,0 +1,85 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Sun, 21 Feb 2010 10:16:27 +0000 (+0100)
+Subject: If setitimer() is not available, no initialization is necessary.
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=1fa465112d1f5519310f47de08494b765c420b8f
+
+If setitimer() is not available, no initialization is necessary.
+This also works around a linking bug in Mingw.
+C tests improved with error-handling code.
+---
+
+diff --git a/Watchdog/src/Watchdog.cc b/Watchdog/src/Watchdog.cc
+index 68ed01f..84ccda3 100644
+--- a/Watchdog/src/Watchdog.cc
++++ b/Watchdog/src/Watchdog.cc
+@@ -242,6 +242,6 @@ void
+ PWL::Watchdog::finalize() {
+ }
+
+-#endif // PWL_HAVE_DECL_SETITIMER
+-
+ unsigned int PWL::Init::count = 0;
++
++#endif // PWL_HAVE_DECL_SETITIMER
+diff --git a/Watchdog/src/Watchdog.defs.hh b/Watchdog/src/Watchdog.defs.hh
+index a6ec958..674954d 100644
+--- a/Watchdog/src/Watchdog.defs.hh
++++ b/Watchdog/src/Watchdog.defs.hh
+@@ -136,6 +136,8 @@ private:
+ #endif // PWL_HAVE_DECL_SETITIMER
+ };
+
++#if PWL_HAVE_DECL_SETITIMER
++
+ class Init {
+ private:
+ //! Count the number of objects created.
+@@ -149,15 +151,21 @@ public:
+ ~Init();
+ };
+
++#endif // PWL_HAVE_DECL_SETITIMER
++
+ } // namespace Parma_Watchdog_Library
+
+ #include "Watchdog.inlines.hh"
+
++#if PWL_HAVE_DECL_SETITIMER
++
+ namespace {
+
+ Parma_Watchdog_Library::Init Parma_Watchdog_Library_initializer;
+
+ } // namespace
+
++#endif // PWL_HAVE_DECL_SETITIMER
++
+ #endif // !defined(PWL_Watchdog_defs_hh)
+
+diff --git a/Watchdog/src/Watchdog.inlines.hh b/Watchdog/src/Watchdog.inlines.hh
+index 80258dd..6cdd654 100644
+--- a/Watchdog/src/Watchdog.inlines.hh
++++ b/Watchdog/src/Watchdog.inlines.hh
+@@ -109,22 +109,6 @@ inline
+ Watchdog::~Watchdog() {
+ }
+
+-inline
+-Init::Init() {
+- // Only when the first Init object is constructed...
+- if (count++ == 0) {
+- // ... the library is initialized.
+- }
+-}
+-
+-inline
+-Init::~Init() {
+- // Only when the last Init object is destroyed...
+- if (--count == 0) {
+- // ... the library is finalized.
+- }
+-}
+-
+ #endif // !PWL_HAVE_DECL_SETITIMER
+
+ } // namespace Parma_Watchdog_Library
diff --git a/debian/patches/3bbfa4bc9da9558d0b538c95c00607b2928bb9d1 b/debian/patches/3bbfa4bc9da9558d0b538c95c00607b2928bb9d1
new file mode 100644
index 0000000..8a969e1
--- /dev/null
+++ b/debian/patches/3bbfa4bc9da9558d0b538c95c00607b2928bb9d1
@@ -0,0 +1,22 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Sun, 21 Feb 2010 17:05:49 +0000 (+0100)
+Subject: Use the C++ compiler to perform the tests meant for C++.
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=3bbfa4bc9da9558d0b538c95c00607b2928bb9d1
+
+Use the C++ compiler to perform the tests meant for C++.
+---
+
+diff --git a/Watchdog/configure.ac b/Watchdog/configure.ac
+index d4e2b86..278a32d 100644
+--- a/Watchdog/configure.ac
++++ b/Watchdog/configure.ac
+@@ -306,6 +306,9 @@ AM_CONDITIONAL(HAVE_PERL, test x"$PERL" != xno)
+ AC_LANG(C)
+ AC_C_CONST
+
++# Use C++ for the remaining checks.
++AC_LANG(C++)
++
+ enableval=no
+ AC_MSG_CHECKING([whether tests should be run under Valgrind])
+ AC_ARG_ENABLE(valgrind-tests,
diff --git a/debian/patches/777f298702f1005f6c4f026fb7a4663bb8dadd0e.debian b/debian/patches/777f298702f1005f6c4f026fb7a4663bb8dadd0e.debian
new file mode 100644
index 0000000..7df12b5
--- /dev/null
+++ b/debian/patches/777f298702f1005f6c4f026fb7a4663bb8dadd0e.debian
@@ -0,0 +1,39 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Wed, 17 Feb 2010 11:33:34 +0000 (+0100)
+Subject: Cater for systems where setitimer() is not provided (part 4).
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=777f298702f1005f6c4f026fb7a4663bb8dadd0e
+
+Cater for systems where setitimer() is not provided (part 4).
+---
+
+diff --git a/Watchdog/src/pwl_header.hh b/Watchdog/src/pwl_header.hh
+index 4ac7d7e..3a65df6 100644
+--- a/Watchdog/src/pwl_header.hh
++++ b/Watchdog/src/pwl_header.hh
+@@ -31,6 +31,9 @@ site: http://www.cs.unipr.it/ppl/ . */
+ #include "pwl-config.h"
+ #include "pwl_include_files.hh"
+
++//! Defined to 1 if PWL::Watchdog objects are supported, to 0 otherwise.
++#define PWL_WATCHDOG_OBJECTS_ARE_SUPPORTED PWL_HAVE_DECL_SETITIMER
++
+ #ifdef PWL_SAVE_NDEBUG
+ # ifndef NDEBUG
+ # define NDEBUG 1
+diff --git a/Watchdog/tests/simple1.cc b/Watchdog/tests/simple1.cc
+index ea86ec0..6876c5f 100644
+--- a/Watchdog/tests/simple1.cc
++++ b/Watchdog/tests/simple1.cc
+@@ -56,6 +56,12 @@ test01() {
+ interrupt = false;
+ return ok;
+ }
++#if !PWL_WATCHDOG_OBJECTS_ARE_SUPPORTED
++ catch (std::runtime_error& e) {
++ nout << "runtime_error: " << e.what() << endl << endl;
++ return true;
++ }
++#endif // !PWL_WATCHDOG_OBJECTS_ARE_SUPPORTED
+ catch (...) {
+ return false;
+ }
diff --git a/debian/patches/7ba6445b1c5adb835e27d2f005779d4343721d21 b/debian/patches/7ba6445b1c5adb835e27d2f005779d4343721d21
new file mode 100644
index 0000000..b47b3cc
--- /dev/null
+++ b/debian/patches/7ba6445b1c5adb835e27d2f005779d4343721d21
@@ -0,0 +1,281 @@
+From 7ba6445b1c5adb835e27d2f005779d4343721d21 Mon Sep 17 00:00:00 2001
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Mon, 15 Feb 2010 14:50:19 +0100
+Subject: [PATCH] Improve portability to systems that do not (fully) support Posix signal handling.
+
+---
+ Watchdog/configure.ac | 1 +
+ Watchdog/pwl-config.sed | 4 ++-
+ Watchdog/tests/pwl_test.cc | 62 +++++++++++++++++++++++++++++++++++++++----
+ configure.ac | 1 +
+ ppl-config.sed | 4 +++
+ tests/ppl_test.cc | 62 +++++++++++++++++++++++++++++++++++++++----
+ 6 files changed, 121 insertions(+), 13 deletions(-)
+
+diff --git a/Watchdog/configure.ac b/Watchdog/configure.ac
+index b831583..4e7b1a8 100644
+--- a/Watchdog/configure.ac
++++ b/Watchdog/configure.ac
+@@ -371,6 +371,7 @@ then
+
+ # Checks for the availability of C library functions in C++.
+ AC_CHECK_DECLS([getenv], , , [#include <cstdlib>])
++ AC_CHECK_DECLS([sigaction], , , [#include <csignal>])
+
+ # Checks for typedefs, structures, and compiler characteristics.
+ AC_CHECK_TYPES([siginfo_t], [], [], [[
+diff --git a/Watchdog/pwl-config.sed b/Watchdog/pwl-config.sed
+index 960a73e..15a0d31 100644
+--- a/Watchdog/pwl-config.sed
++++ b/Watchdog/pwl-config.sed
+@@ -1,9 +1,11 @@
+ s/\([^A-Z_]\)HAVE_DECL_GETENV/\1PWL_HAVE_DECL_GETENV/g
++s/\([^A-Z_]\)HAVE_DECL_SIGACTION/\1PWL_HAVE_DECL_SIGACTION/g
+ s/\([^A-Z_]\)HAVE_DLFCN_H/\1PWL_HAVE_DLFCN_H/g
+ s/\([^A-Z_]\)HAVE_FENV_H/\1PWL_HAVE_FENV_H/g
+ s/\([^A-Z_]\)HAVE_INTTYPES_H/\1PWL_HAVE_INTTYPES_H/g
+ s/\([^A-Z_]\)HAVE_MEMORY_H/\1PWL_HAVE_MEMORY_H/g
+-s/\([^A-Z_]\)HAVE_SETITIMER_H/\1PWL_HAVE_SETITIMER_H/g
++s/\([^A-Z_]\)HAVE_SETITIMER/\1PWL_HAVE_SETITIMER/g
++s/\([^A-Z_]\)HAVE_SIGINFO_T/\1PWL_HAVE_SIGINFO_T/g
+ s/\([^A-Z_]\)HAVE_STDINT_H/\1PWL_HAVE_STDINT_H/g
+ s/\([^A-Z_]\)HAVE_STDLIB_H/\1PWL_HAVE_STDLIB_H/g
+ s/\([^A-Z_]\)HAVE_STRINGS_H/\1PWL_HAVE_STRINGS_H/g
+diff --git a/Watchdog/tests/pwl_test.cc b/Watchdog/tests/pwl_test.cc
+index 41ab632..f4b828c 100644
+--- a/Watchdog/tests/pwl_test.cc
++++ b/Watchdog/tests/pwl_test.cc
+@@ -43,9 +43,12 @@ uncaught_exception_handler() {
+ exit(1);
+ }
+
+-#ifdef HAVE_SIGINFO_T
++#ifdef PWL_HAVE_DECL_SIGACTION
++
++#if defined(PWL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
++
+ void
+-fpe_handler(int sig, siginfo_t* sip, void*) {
++fpe_sigaction(int sig, siginfo_t* sip, void*) {
+ if (sig != SIGFPE) {
+ std::cerr << "fpe_handler called on signal different from SIGFPE"
+ << std::endl;
+@@ -113,7 +116,49 @@ fpe_handler(int sig, siginfo_t* sip, void*) {
+ }
+ exit(1);
+ }
+-#endif // defined(HAVE_SIGINFO_T)
++
++#else // !defined(PWL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
++
++void
++fpe_handler(int sig) {
++ if (sig != SIGFPE) {
++ std::cerr << "fpe_handler called on signal different from SIGFPE"
++ << std::endl;
++ exit(1);
++ }
++ std::cerr << "SIGFPE caught"
++ << std::endl;
++#if defined(PWL_HAVE_FENV_H)
++ std::cerr << "Inquire with fetestexcept(): ";
++#ifdef FE_INEXACT
++ if (fetestexcept(FE_INEXACT))
++ std::cerr << "FE_INEXACT ";
++#endif
++#ifdef FE_DIVBYZERO
++ if (fetestexcept(FE_DIVBYZERO))
++ std::cerr << "FE_DIVBYZERO ";
++#endif
++#ifdef FE_UNDERFLOW
++ if (fetestexcept(FE_UNDERFLOW))
++ std::cerr << "FE_UNDERFLOW ";
++#endif
++#ifdef FE_OVERFLOW
++ if (fetestexcept(FE_OVERFLOW))
++ std::cerr << "FE_OVERFLOW ";
++#endif
++#if FE_INVALID
++ if (fetestexcept(FE_INVALID))
++ std::cerr << "FE_INVALID ";
++#endif
++ std::cerr << std::endl;
++#endif
++ }
++ exit(1);
++}
++
++#endif // !defined(PWL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
++
++#endif // defined(PWL_HAVE_DECL_SIGACTION)
+
+ } // namespace
+
+@@ -121,19 +166,24 @@ namespace Parma_Watchdog_Library {
+
+ namespace Test {
+
+-#ifdef HAVE_SIGINFO_T
+ void
+ set_handlers() {
++#ifdef PWL_HAVE_DECL_SIGACTION
+ struct sigaction action;
+- action.sa_sigaction = fpe_handler;
+ sigemptyset(&action.sa_mask);
++#if defined(PWL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
++ action.sa_sigaction = fpe_sigaction;
+ action.sa_flags = SA_SIGINFO;
++#else // !defined(PWL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
++ action.sa_handler = fpe_handler;
++ action.sa_flags = 0;
++#endif // !defined(PWL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
+ if (sigaction(SIGFPE, &action, NULL) != 0) {
+ std::cerr << "sigaction() failed"
+ << std::endl;
+ abort();
+ }
+-#endif // defined(HAVE_SIGINFO_T)
++#endif // defined(PWL_HAVE_DECL_SIGACTION)
+
+ std::set_unexpected(unexpected_exception_handler);
+ std::set_terminate(uncaught_exception_handler);
+diff --git a/configure.ac b/configure.ac
+index 465f530..d67f0ff 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1472,6 +1472,7 @@ AC_CHECK_DECLS([getrusage],
+ # include <sys/resource.h>
+ #endif
+ ])
++AC_CHECK_DECLS([sigaction], , , [#include <csignal>])
+
+ # Checks for typedefs, structures, and compiler characteristics.
+ AC_CHECK_TYPES([timeval])
+diff --git a/ppl-config.sed b/ppl-config.sed
+index 2d74bb6..95f8ae1 100644
+--- a/ppl-config.sed
++++ b/ppl-config.sed
+@@ -10,6 +10,7 @@ s/\([^A-Z_]\)HAVE_DECL_RLIMIT_AS/\1PPL_HAVE_DECL_RLIMIT_AS/g
+ s/\([^A-Z_]\)HAVE_DECL_RLIMIT_DATA/\1PPL_HAVE_DECL_RLIMIT_DATA/g
+ s/\([^A-Z_]\)HAVE_DECL_RLIMIT_RSS/\1PPL_HAVE_DECL_RLIMIT_RSS/g
+ s/\([^A-Z_]\)HAVE_DECL_RLIMIT_VMEM/\1PPL_HAVE_DECL_RLIMIT_VMEM/g
++s/\([^A-Z_]\)HAVE_DECL_SIGACTION/\1PPL_HAVE_DECL_SIGACTION/g
+ s/\([^A-Z_]\)HAVE_DECL_STRTOD/\1PPL_HAVE_DECL_STRTOD/g
+ s/\([^A-Z_]\)HAVE_DECL_STRTOF/\1PPL_HAVE_DECL_STRTOF/g
+ s/\([^A-Z_]\)HAVE_DECL_STRTOLD/\1PPL_HAVE_DECL_STRTOLD/g
+@@ -26,6 +27,8 @@ s/\([^A-Z_]\)HAVE_INT_FAST16_T/\1PPL_HAVE_INT_FAST16_T/g
+ s/\([^A-Z_]\)HAVE_INT_FAST32_T/\1PPL_HAVE_INT_FAST32_T/g
+ s/\([^A-Z_]\)HAVE_INT_FAST64_T/\1PPL_HAVE_INT_FAST64_T/g
+ s/\([^A-Z_]\)HAVE_MEMORY_H/\1PPL_HAVE_MEMORY_H/g
++s/\([^A-Z_]\)HAVE_SETITIMER/\1PPL_HAVE_SETITIMER/g
++s/\([^A-Z_]\)HAVE_SIGINFO_T/\1PPL_HAVE_SIGINFO_T/g
+ s/\([^A-Z_]\)HAVE_SIGNAL_H/\1PPL_HAVE_SIGNAL_H/g
+ s/\([^A-Z_]\)HAVE_STDINT_H/\1PPL_HAVE_STDINT_H/g
+ s/\([^A-Z_]\)HAVE_STDLIB_H/\1PPL_HAVE_STDLIB_H/g
+@@ -40,6 +43,7 @@ s/\([^A-Z_]\)HAVE_TYPEOF/\1PPL_HAVE_TYPEOF/g
+ s/\([^A-Z_]\)HAVE_UINT_FAST16_T/\1PPL_HAVE_UINT_FAST16_T/g
+ s/\([^A-Z_]\)HAVE_UINT_FAST32_T/\1PPL_HAVE_UINT_FAST32_T/g
+ s/\([^A-Z_]\)HAVE_UINT_FAST64_T/\1PPL_HAVE_UINT_FAST64_T/g
++s/\([^A-Z_]\)HAVE_UINTPTR_T/\1PPL_HAVE_UINTPTR_T/g
+ s/\([^A-Z_]\)HAVE_UNISTD_H/\1PPL_HAVE_UNISTD_H/g
+ s/\([^A-Z_]\)HAVE___MPZ_STRUCT__MP_ALLOC/\1PPL_HAVE___MPZ_STRUCT__MP_ALLOC/g
+ s/\([^A-Z_]\)HAVE___MPZ_STRUCT__MP_D/\1PPL_HAVE___MPZ_STRUCT__MP_D/g
+diff --git a/tests/ppl_test.cc b/tests/ppl_test.cc
+index 3c5caef..c0ac87f 100644
+--- a/tests/ppl_test.cc
++++ b/tests/ppl_test.cc
+@@ -43,9 +43,12 @@ uncaught_exception_handler() {
+ exit(1);
+ }
+
+-#ifdef HAVE_SIGINFO_T
++#ifdef PPL_HAVE_DECL_SIGACTION
++
++#if defined(PPL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
++
+ void
+-fpe_handler(int sig, siginfo_t* sip, void*) {
++fpe_sigaction(int sig, siginfo_t* sip, void*) {
+ if (sig != SIGFPE) {
+ std::cerr << "fpe_handler called on signal different from SIGFPE"
+ << std::endl;
+@@ -113,7 +116,49 @@ fpe_handler(int sig, siginfo_t* sip, void*) {
+ }
+ exit(1);
+ }
+-#endif // defined(HAVE_SIGINFO_T)
++
++#else // !defined(PPL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
++
++void
++fpe_handler(int sig) {
++ if (sig != SIGFPE) {
++ std::cerr << "fpe_handler called on signal different from SIGFPE"
++ << std::endl;
++ exit(1);
++ }
++ std::cerr << "SIGFPE caught"
++ << std::endl;
++#if defined(PWL_HAVE_FENV_H)
++ std::cerr << "Inquire with fetestexcept(): ";
++#ifdef FE_INEXACT
++ if (fetestexcept(FE_INEXACT))
++ std::cerr << "FE_INEXACT ";
++#endif
++#ifdef FE_DIVBYZERO
++ if (fetestexcept(FE_DIVBYZERO))
++ std::cerr << "FE_DIVBYZERO ";
++#endif
++#ifdef FE_UNDERFLOW
++ if (fetestexcept(FE_UNDERFLOW))
++ std::cerr << "FE_UNDERFLOW ";
++#endif
++#ifdef FE_OVERFLOW
++ if (fetestexcept(FE_OVERFLOW))
++ std::cerr << "FE_OVERFLOW ";
++#endif
++#if FE_INVALID
++ if (fetestexcept(FE_INVALID))
++ std::cerr << "FE_INVALID ";
++#endif
++ std::cerr << std::endl;
++#endif
++ }
++ exit(1);
++}
++
++#endif // !defined(PPL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
++
++#endif // defined(PPL_HAVE_DECL_SIGACTION)
+
+ } // namespace
+
+@@ -123,17 +168,22 @@ namespace Test {
+
+ void
+ set_handlers() {
+-#ifdef HAVE_SIGINFO_T
++#ifdef PPL_HAVE_DECL_SIGACTION
+ struct sigaction action;
+- action.sa_sigaction = fpe_handler;
+ sigemptyset(&action.sa_mask);
++#if defined(PPL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
++ action.sa_sigaction = fpe_sigaction;
+ action.sa_flags = SA_SIGINFO;
++#else // !defined(PPL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
++ action.sa_handler = fpe_handler;
++ action.sa_flags = 0;
++#endif // !defined(PPL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
+ if (sigaction(SIGFPE, &action, NULL) != 0) {
+ std::cerr << "sigaction() failed"
+ << std::endl;
+ abort();
+ }
+-#endif // defined(HAVE_SIGINFO_T)
++#endif // defined(PPL_HAVE_DECL_SIGACTION)
+
+ std::set_unexpected(unexpected_exception_handler);
+ std::set_terminate(uncaught_exception_handler);
+--
+1.6.0.6
+
diff --git a/debian/patches/8ac2c64c2e9fa2da2d02428fe51c34b8dca3d6ff.debian b/debian/patches/8ac2c64c2e9fa2da2d02428fe51c34b8dca3d6ff.debian
new file mode 100644
index 0000000..aad2330
--- /dev/null
+++ b/debian/patches/8ac2c64c2e9fa2da2d02428fe51c34b8dca3d6ff.debian
@@ -0,0 +1,156 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Wed, 17 Feb 2010 11:15:35 +0000 (+0100)
+Subject: Cater for systems where setitimer() is not provided (part 2).
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=8ac2c64c2e9fa2da2d02428fe51c34b8dca3d6ff
+
+Cater for systems where setitimer() is not provided (part 2).
+---
+
+diff --git a/Watchdog/pwl-config.sed b/Watchdog/pwl-config.sed
+index 15a0d31..7972470 100644
+--- a/Watchdog/pwl-config.sed
++++ b/Watchdog/pwl-config.sed
+@@ -1,5 +1,6 @@
+ s/\([^A-Z_]\)HAVE_DECL_GETENV/\1PWL_HAVE_DECL_GETENV/g
+ s/\([^A-Z_]\)HAVE_DECL_SIGACTION/\1PWL_HAVE_DECL_SIGACTION/g
++s/\([^A-Z_]\)HAVE_DECL_SETITIMER/\1PWL_HAVE_DECL_SETITIMER/g
+ s/\([^A-Z_]\)HAVE_DLFCN_H/\1PWL_HAVE_DLFCN_H/g
+ s/\([^A-Z_]\)HAVE_FENV_H/\1PWL_HAVE_FENV_H/g
+ s/\([^A-Z_]\)HAVE_INTTYPES_H/\1PWL_HAVE_INTTYPES_H/g
+diff --git a/Watchdog/src/Watchdog.cc b/Watchdog/src/Watchdog.cc
+index 03e259e..1b2fcb2 100644
+--- a/Watchdog/src/Watchdog.cc
++++ b/Watchdog/src/Watchdog.cc
+@@ -24,6 +24,8 @@ site: http://www.cs.unipr.it/ppl/ . */
+
+ #include "Watchdog.defs.hh"
+
++#if PWL_HAVE_DECL_SETITIMER
++
+ #include <csignal>
+ #include <iostream>
+ #include <stdexcept>
+@@ -218,17 +220,13 @@ PWL::Watchdog::remove_watchdog_event(WD_Pending_List::Iterator position) {
+ pending.erase(position);
+ }
+
+-PWL::Watchdog::~Watchdog() {
+- if (!expired) {
+- in_critical_section = true;
+- remove_watchdog_event(pending_position);
+- in_critical_section = false;
+- }
+- delete &handler;
+-}
++PWL::Time PWL::Watchdog::reschedule_time(1);
++
++#endif // PWL_HAVE_DECL_SETITIMER
+
+ void
+ PWL::Watchdog::initialize() {
++#if PWL_HAVE_DECL_SETITIMER
+ signal_once.it_interval.tv_sec = 0;
+ signal_once.it_interval.tv_usec = 0;
+
+@@ -241,12 +239,11 @@ PWL::Watchdog::initialize() {
+ s.sa_flags = 0; // Was SA_ONESHOT: why?
+
+ my_sigaction(THE_SIGNAL, &s, 0);
++#endif // PWL_HAVE_DECL_SETITIMER
+ }
+
+ void
+ PWL::Watchdog::finalize() {
+ }
+
+-PWL::Time PWL::Watchdog::reschedule_time(1);
+-
+ unsigned int PWL::Init::count = 0;
+diff --git a/Watchdog/src/Watchdog.defs.hh b/Watchdog/src/Watchdog.defs.hh
+index 3b1b3ba..a6ec958 100644
+--- a/Watchdog/src/Watchdog.defs.hh
++++ b/Watchdog/src/Watchdog.defs.hh
+@@ -61,7 +61,7 @@ public:
+ Watchdog(int units, void (*function)());
+ ~Watchdog();
+
+-#if HAVE_DECL_SETITIMER
++#if PWL_HAVE_DECL_SETITIMER
+
+ private:
+ friend class Init;
+@@ -133,7 +133,7 @@ private:
+
+ friend void PWL_handle_timeout(int signum);
+
+-#endif // HAVE_DECL_SETITIMER
++#endif // PWL_HAVE_DECL_SETITIMER
+ };
+
+ class Init {
+diff --git a/Watchdog/src/Watchdog.inlines.hh b/Watchdog/src/Watchdog.inlines.hh
+index a24dd35..016926d 100644
+--- a/Watchdog/src/Watchdog.inlines.hh
++++ b/Watchdog/src/Watchdog.inlines.hh
+@@ -29,7 +29,7 @@ site: http://www.cs.unipr.it/ppl/ . */
+
+ namespace Parma_Watchdog_Library {
+
+-#if HAVE_DECL_SETITIMER
++#if PWL_HAVE_DECL_SETITIMER
+
+ template <typename Flag_Base, typename Flag>
+ Watchdog::Watchdog(int units, const Flag_Base* volatile& holder, Flag& flag)
+@@ -55,32 +56,42 @@ Watchdog::Watchdog(int units, void (*function)())
+ in_critical_section = false;
+ }
+
++inline
++Watchdog::~Watchdog() {
++ if (!expired) {
++ in_critical_section = true;
++ remove_watchdog_event(pending_position);
++ in_critical_section = false;
++ }
++ delete &handler;
++}
++
+ inline void
+ Watchdog::reschedule() {
+ set_timer(reschedule_time);
+ }
+
+-#else // !HAVE_DECL_SETITIMER
++#else // !PWL_HAVE_DECL_SETITIMER
+
+ template <typename Flag_Base, typename Flag>
+-Watchdog::Watchdog(int units,
+- const Flag_Base* volatile& holder, Flag& flag) {
+- used(units);
+- used(holder);
+- used(flag);
++Watchdog::Watchdog(int /* units */,
++ const Flag_Base* volatile& /* holder */,
++ Flag& /* flag */) {
+ throw std::runtime_error("PWL::Watchdog objects not supported:"
+ " system does not provide setitimer()");
+ }
+
+ inline
+-Watchdog::Watchdog(int units, void (*function)()) {
+- used(units);
+- used(function);
++Watchdog::Watchdog(int /* units */, void (* /* function */)()) {
+ throw std::runtime_error("PWL::Watchdog objects not supported:"
+ " system does not provide setitimer()");
+ }
+
+-#endif // HAVE_DECL_SETITIMER
++inline
++Watchdog::~Watchdog() {
++}
++
++#endif // !PWL_HAVE_DECL_SETITIMER
+
+ inline
+ Init::Init() {
diff --git a/debian/patches/9a89bb0a926a098a6e06a18c36881786f45d678b.debian b/debian/patches/9a89bb0a926a098a6e06a18c36881786f45d678b.debian
new file mode 100644
index 0000000..810c215
--- /dev/null
+++ b/debian/patches/9a89bb0a926a098a6e06a18c36881786f45d678b.debian
@@ -0,0 +1,27 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Sat, 27 Feb 2010 06:33:22 +0000 (+0100)
+Subject: Exception handling fixed.
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=9a89bb0a926a098a6e06a18c36881786f45d678b
+
+Exception handling fixed.
+---
+
+diff --git a/tests/Polyhedron/watchdog1.cc b/tests/Polyhedron/watchdog1.cc
+index 5254d53..dd7271e 100644
+--- a/tests/Polyhedron/watchdog1.cc
++++ b/tests/Polyhedron/watchdog1.cc
+@@ -81,6 +81,14 @@ timed_compute_open_hypercube_generators(dimension_type dimension,
+ nout << " s" << endl;
+ return false;
+ }
++#if !PWL_WATCHDOG_OBJECTS_ARE_SUPPORTED
++ // If Watchdog objects are not supported, an std::logic_error exception
++ // will be thrown: this is normal.
++ catch (const std::runtime_error& e) {
++ nout << "std::runtime_error exception caught: \n" << e.what() << std::endl;
++ exit(0);
++}
++#endif // !PWL_WATCHDOG_OBJECTS_ARE_SUPPORTED
+ catch (...) {
+ exit(1);
+ }
diff --git a/debian/patches/9b0ba93300fb829608d40e766b9f3f95c81962e1.debian b/debian/patches/9b0ba93300fb829608d40e766b9f3f95c81962e1.debian
new file mode 100644
index 0000000..bda545b
--- /dev/null
+++ b/debian/patches/9b0ba93300fb829608d40e766b9f3f95c81962e1.debian
@@ -0,0 +1,124 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Sun, 21 Feb 2010 11:49:16 +0000 (+0100)
+Subject: sigaction() is also needed, in addition to setitimer() in order to support Watchdog...
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=9b0ba93300fb829608d40e766b9f3f95c81962e1
+
+sigaction() is also needed, in addition to setitimer() in order to support Watchdog objects.
+We could check if signal() is available if there is request for such a feature.
+---
+
+diff --git a/Watchdog/src/Watchdog.cc b/Watchdog/src/Watchdog.cc
+index 84ccda3..93449be 100644
+--- a/Watchdog/src/Watchdog.cc
++++ b/Watchdog/src/Watchdog.cc
+@@ -26,7 +26,7 @@ site: http://www.cs.unipr.it/ppl/ . */
+
+ namespace PWL = Parma_Watchdog_Library;
+
+-#if PWL_HAVE_DECL_SETITIMER
++#if PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+
+ #include <csignal>
+ #include <iostream>
+@@ -244,4 +244,4 @@ PWL::Watchdog::finalize() {
+
+ unsigned int PWL::Init::count = 0;
+
+-#endif // PWL_HAVE_DECL_SETITIMER
++#endif // PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+diff --git a/Watchdog/src/Watchdog.defs.hh b/Watchdog/src/Watchdog.defs.hh
+index 674954d..7e0f6f5 100644
+--- a/Watchdog/src/Watchdog.defs.hh
++++ b/Watchdog/src/Watchdog.defs.hh
+@@ -61,7 +61,7 @@ public:
+ Watchdog(int units, void (*function)());
+ ~Watchdog();
+
+-#if PWL_HAVE_DECL_SETITIMER
++#if PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+
+ private:
+ friend class Init;
+@@ -133,10 +133,10 @@ private:
+
+ friend void PWL_handle_timeout(int signum);
+
+-#endif // PWL_HAVE_DECL_SETITIMER
++#endif // PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+ };
+
+-#if PWL_HAVE_DECL_SETITIMER
++#if PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+
+ class Init {
+ private:
+@@ -151,13 +151,13 @@ public:
+ ~Init();
+ };
+
+-#endif // PWL_HAVE_DECL_SETITIMER
++#endif // PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+
+ } // namespace Parma_Watchdog_Library
+
+ #include "Watchdog.inlines.hh"
+
+-#if PWL_HAVE_DECL_SETITIMER
++#if PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+
+ namespace {
+
+@@ -165,7 +165,7 @@ Parma_Watchdog_Library::Init Parma_Watchdog_Library_initializer;
+
+ } // namespace
+
+-#endif // PWL_HAVE_DECL_SETITIMER
++#endif // PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+
+ #endif // !defined(PWL_Watchdog_defs_hh)
+
+diff --git a/Watchdog/src/Watchdog.inlines.hh b/Watchdog/src/Watchdog.inlines.hh
+index 6cdd654..6591359 100644
+--- a/Watchdog/src/Watchdog.inlines.hh
++++ b/Watchdog/src/Watchdog.inlines.hh
+@@ -29,7 +29,7 @@ site: http://www.cs.unipr.it/ppl/ . */
+
+ namespace Parma_Watchdog_Library {
+
+-#if PWL_HAVE_DECL_SETITIMER
++#if PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION
+
+ template <typename Flag_Base, typename Flag>
+ Watchdog::Watchdog(int units, const Flag_Base* volatile& holder, Flag& flag)
+@@ -89,7 +89,7 @@ Init::~Init() {
+ }
+ }
+
+-#else // !PWL_HAVE_DECL_SETITIMER
++#else // !PWL_HAVE_DECL_SETITIMER !! !PWL_HAVE_DECL_SIGACTION
+
+ template <typename Flag_Base, typename Flag>
+ Watchdog::Watchdog(int /* units */,
+@@ -109,7 +109,7 @@ inline
+ Watchdog::~Watchdog() {
+ }
+
+-#endif // !PWL_HAVE_DECL_SETITIMER
++#endif // !PWL_HAVE_DECL_SETITIMER !! !PWL_HAVE_DECL_SIGACTION
+
+ } // namespace Parma_Watchdog_Library
+
+diff --git a/Watchdog/src/pwl_header.hh b/Watchdog/src/pwl_header.hh
+index 3a65df6..8df3a05 100644
+--- a/Watchdog/src/pwl_header.hh
++++ b/Watchdog/src/pwl_header.hh
+@@ -32,7 +32,8 @@ site: http://www.cs.unipr.it/ppl/ . */
+ #include "pwl_include_files.hh"
+
+ //! Defined to 1 if PWL::Watchdog objects are supported, to 0 otherwise.
+-#define PWL_WATCHDOG_OBJECTS_ARE_SUPPORTED PWL_HAVE_DECL_SETITIMER
++#define PWL_WATCHDOG_OBJECTS_ARE_SUPPORTED \
++ (PWL_HAVE_DECL_SETITIMER && PWL_HAVE_DECL_SIGACTION)
+
+ #ifdef PWL_SAVE_NDEBUG
+ # ifndef NDEBUG
diff --git a/debian/patches/9ba82c5fb51ff9f63818fa8c6f006a1900a70894 b/debian/patches/9ba82c5fb51ff9f63818fa8c6f006a1900a70894
new file mode 100644
index 0000000..a24d343
--- /dev/null
+++ b/debian/patches/9ba82c5fb51ff9f63818fa8c6f006a1900a70894
@@ -0,0 +1,88 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Tue, 16 Feb 2010 20:35:54 +0000 (+0100)
+Subject: Use the right preprocessor conditionals for PPL_HAVE_DECL_SIGACTION.
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=9ba82c5fb51ff9f63818fa8c6f006a1900a70894
+
+Use the right preprocessor conditionals for PPL_HAVE_DECL_SIGACTION.
+---
+
+diff --git a/Watchdog/tests/pwl_test.cc b/Watchdog/tests/pwl_test.cc
+index 4100e5b..94d4c3b 100644
+--- a/Watchdog/tests/pwl_test.cc
++++ b/Watchdog/tests/pwl_test.cc
+@@ -43,7 +43,7 @@ uncaught_exception_handler() {
+ exit(1);
+ }
+
+-#ifdef PWL_HAVE_DECL_SIGACTION
++#if PWL_HAVE_DECL_SIGACTION
+
+ #if defined(PWL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
+
+@@ -157,7 +157,7 @@ fpe_handler(int sig) {
+
+ #endif // !defined(PWL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
+
+-#endif // defined(PWL_HAVE_DECL_SIGACTION)
++#endif // PWL_HAVE_DECL_SIGACTION
+
+ } // namespace
+
+@@ -167,7 +167,7 @@ namespace Test {
+
+ void
+ set_handlers() {
+-#ifdef PWL_HAVE_DECL_SIGACTION
++#if PWL_HAVE_DECL_SIGACTION
+ struct sigaction action;
+ sigemptyset(&action.sa_mask);
+ #if defined(PWL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
+@@ -182,7 +182,7 @@ set_handlers() {
+ << std::endl;
+ abort();
+ }
+-#endif // defined(PWL_HAVE_DECL_SIGACTION)
++#endif // PWL_HAVE_DECL_SIGACTION
+
+ std::set_unexpected(unexpected_exception_handler);
+ std::set_terminate(uncaught_exception_handler);
+diff --git a/tests/ppl_test.cc b/tests/ppl_test.cc
+index 9ec9f23..df44e71 100644
+--- a/tests/ppl_test.cc
++++ b/tests/ppl_test.cc
+@@ -43,7 +43,7 @@ uncaught_exception_handler() {
+ exit(1);
+ }
+
+-#ifdef PPL_HAVE_DECL_SIGACTION
++#if PPL_HAVE_DECL_SIGACTION
+
+ #if defined(PPL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
+
+@@ -157,7 +157,7 @@ fpe_handler(int sig) {
+
+ #endif // !defined(PPL_HAVE_SIGINFO_T) || !defined(SA_SIGINFO)
+
+-#endif // defined(PPL_HAVE_DECL_SIGACTION)
++#endif // PPL_HAVE_DECL_SIGACTION
+
+ } // namespace
+
+@@ -167,7 +167,7 @@ namespace Test {
+
+ void
+ set_handlers() {
+-#ifdef PPL_HAVE_DECL_SIGACTION
++#if PPL_HAVE_DECL_SIGACTION
+ struct sigaction action;
+ sigemptyset(&action.sa_mask);
+ #if defined(PPL_HAVE_SIGINFO_T) && defined(SA_SIGINFO)
+@@ -182,7 +182,7 @@ set_handlers() {
+ << std::endl;
+ abort();
+ }
+-#endif // defined(PPL_HAVE_DECL_SIGACTION)
++#endif // PPL_HAVE_DECL_SIGACTION
+
+ std::set_unexpected(unexpected_exception_handler);
+ std::set_terminate(uncaught_exception_handler);
diff --git a/debian/patches/9bdd6617be52573d3252687844d32001e671a126.debian b/debian/patches/9bdd6617be52573d3252687844d32001e671a126.debian
new file mode 100644
index 0000000..0bca2e7
--- /dev/null
+++ b/debian/patches/9bdd6617be52573d3252687844d32001e671a126.debian
@@ -0,0 +1,79 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Wed, 17 Feb 2010 10:56:08 +0000 (+0100)
+Subject: Cater for systems where setitimer() is not provided (part 1).
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=9bdd6617be52573d3252687844d32001e671a126
+
+Cater for systems where setitimer() is not provided (part 1).
+---
+
+diff --git a/Watchdog/src/Watchdog.defs.hh b/Watchdog/src/Watchdog.defs.hh
+index eace4b3..3b1b3ba 100644
+--- a/Watchdog/src/Watchdog.defs.hh
++++ b/Watchdog/src/Watchdog.defs.hh
+@@ -61,6 +61,7 @@ public:
+ Watchdog(int units, void (*function)());
+ ~Watchdog();
+
++#if HAVE_DECL_SETITIMER
+
+ private:
+ friend class Init;
+@@ -130,6 +132,8 @@ private:
+ static volatile bool in_critical_section;
+
+ friend void PWL_handle_timeout(int signum);
++
++#endif // HAVE_DECL_SETITIMER
+ };
+
+ class Init {
+diff --git a/Watchdog/src/Watchdog.inlines.hh b/Watchdog/src/Watchdog.inlines.hh
+index 47340fc..a24dd35 100644
+--- a/Watchdog/src/Watchdog.inlines.hh
++++ b/Watchdog/src/Watchdog.inlines.hh
+@@ -29,10 +29,7 @@ site: http://www.cs.unipr.it/ppl/ . */
+
+ namespace Parma_Watchdog_Library {
+
+-inline void
+-Watchdog::reschedule() {
+- set_timer(reschedule_time);
+-}
++#if HAVE_DECL_SETITIMER
+
+ template <typename Flag_Base, typename Flag>
+ Watchdog::Watchdog(int units, const Flag_Base* volatile& holder, Flag& flag)
+@@ -58,6 +55,33 @@ Watchdog::Watchdog(int units, void (*function)())
+ in_critical_section = false;
+ }
+
++inline void
++Watchdog::reschedule() {
++ set_timer(reschedule_time);
++}
++
++#else // !HAVE_DECL_SETITIMER
++
++template <typename Flag_Base, typename Flag>
++Watchdog::Watchdog(int units,
++ const Flag_Base* volatile& holder, Flag& flag) {
++ used(units);
++ used(holder);
++ used(flag);
++ throw std::runtime_error("PWL::Watchdog objects not supported:"
++ " system does not provide setitimer()");
++}
++
++inline
++Watchdog::Watchdog(int units, void (*function)()) {
++ used(units);
++ used(function);
++ throw std::runtime_error("PWL::Watchdog objects not supported:"
++ " system does not provide setitimer()");
++}
++
++#endif // HAVE_DECL_SETITIMER
++
+ inline
+ Init::Init() {
+ // Only when the first Init object is constructed...
diff --git a/debian/patches/bad1f4e90af2d1368fee383f08c59316182de8dc b/debian/patches/bad1f4e90af2d1368fee383f08c59316182de8dc
new file mode 100644
index 0000000..e56f81e
--- /dev/null
+++ b/debian/patches/bad1f4e90af2d1368fee383f08c59316182de8dc
@@ -0,0 +1,133 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Tue, 16 Feb 2010 19:38:32 +0000 (+0100)
+Subject: Corrected several problems.
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=bad1f4e90af2d1368fee383f08c59316182de8dc
+
+Corrected several problems.
+---
+
+diff --git a/Watchdog/tests/pwl_test.cc b/Watchdog/tests/pwl_test.cc
+index f4b828c..4100e5b 100644
+--- a/Watchdog/tests/pwl_test.cc
++++ b/Watchdog/tests/pwl_test.cc
+@@ -112,7 +112,7 @@ fpe_sigaction(int sig, siginfo_t* sip, void*) {
+ std::cerr << "FE_INVALID ";
+ #endif
+ std::cerr << std::endl;
+-#endif
++#endif // defined(PWL_HAVE_FENV_H)
+ }
+ exit(1);
+ }
+@@ -129,30 +129,29 @@ fpe_handler(int sig) {
+ std::cerr << "SIGFPE caught"
+ << std::endl;
+ #if defined(PWL_HAVE_FENV_H)
+- std::cerr << "Inquire with fetestexcept(): ";
++ std::cerr << "Inquire with fetestexcept(): ";
+ #ifdef FE_INEXACT
+- if (fetestexcept(FE_INEXACT))
+- std::cerr << "FE_INEXACT ";
++ if (fetestexcept(FE_INEXACT))
++ std::cerr << "FE_INEXACT ";
+ #endif
+ #ifdef FE_DIVBYZERO
+- if (fetestexcept(FE_DIVBYZERO))
+- std::cerr << "FE_DIVBYZERO ";
++ if (fetestexcept(FE_DIVBYZERO))
++ std::cerr << "FE_DIVBYZERO ";
+ #endif
+ #ifdef FE_UNDERFLOW
+- if (fetestexcept(FE_UNDERFLOW))
+- std::cerr << "FE_UNDERFLOW ";
++ if (fetestexcept(FE_UNDERFLOW))
++ std::cerr << "FE_UNDERFLOW ";
+ #endif
+ #ifdef FE_OVERFLOW
+- if (fetestexcept(FE_OVERFLOW))
+- std::cerr << "FE_OVERFLOW ";
++ if (fetestexcept(FE_OVERFLOW))
++ std::cerr << "FE_OVERFLOW ";
+ #endif
+ #if FE_INVALID
+- if (fetestexcept(FE_INVALID))
+- std::cerr << "FE_INVALID ";
++ if (fetestexcept(FE_INVALID))
++ std::cerr << "FE_INVALID ";
+ #endif
+- std::cerr << std::endl;
+-#endif
+- }
++ std::cerr << std::endl;
++#endif // defined(PWL_HAVE_FENV_H)
+ exit(1);
+ }
+
+diff --git a/tests/ppl_test.cc b/tests/ppl_test.cc
+index c0ac87f..9ec9f23 100644
+--- a/tests/ppl_test.cc
++++ b/tests/ppl_test.cc
+@@ -89,7 +89,7 @@ fpe_sigaction(int sig, siginfo_t* sip, void*) {
+ else {
+ std::cerr << "SIGFPE caught (unknown si_code " << sip->si_code << ")"
+ << std::endl;
+-#if defined(PWL_HAVE_FENV_H)
++#if defined(PPL_HAVE_FENV_H)
+ std::cerr << "Inquire with fetestexcept(): ";
+ #ifdef FE_INEXACT
+ if (fetestexcept(FE_INEXACT))
+@@ -112,7 +112,7 @@ fpe_sigaction(int sig, siginfo_t* sip, void*) {
+ std::cerr << "FE_INVALID ";
+ #endif
+ std::cerr << std::endl;
+-#endif
++#endif // defined(PPL_HAVE_FENV_H)
+ }
+ exit(1);
+ }
+@@ -128,31 +128,30 @@ fpe_handler(int sig) {
+ }
+ std::cerr << "SIGFPE caught"
+ << std::endl;
+-#if defined(PWL_HAVE_FENV_H)
+- std::cerr << "Inquire with fetestexcept(): ";
++#if defined(PPL_HAVE_FENV_H)
++ std::cerr << "Inquire with fetestexcept(): ";
+ #ifdef FE_INEXACT
+- if (fetestexcept(FE_INEXACT))
+- std::cerr << "FE_INEXACT ";
++ if (fetestexcept(FE_INEXACT))
++ std::cerr << "FE_INEXACT ";
+ #endif
+ #ifdef FE_DIVBYZERO
+- if (fetestexcept(FE_DIVBYZERO))
+- std::cerr << "FE_DIVBYZERO ";
++ if (fetestexcept(FE_DIVBYZERO))
++ std::cerr << "FE_DIVBYZERO ";
+ #endif
+ #ifdef FE_UNDERFLOW
+- if (fetestexcept(FE_UNDERFLOW))
+- std::cerr << "FE_UNDERFLOW ";
++ if (fetestexcept(FE_UNDERFLOW))
++ std::cerr << "FE_UNDERFLOW ";
+ #endif
+ #ifdef FE_OVERFLOW
+- if (fetestexcept(FE_OVERFLOW))
+- std::cerr << "FE_OVERFLOW ";
++ if (fetestexcept(FE_OVERFLOW))
++ std::cerr << "FE_OVERFLOW ";
+ #endif
+ #if FE_INVALID
+- if (fetestexcept(FE_INVALID))
+- std::cerr << "FE_INVALID ";
++ if (fetestexcept(FE_INVALID))
++ std::cerr << "FE_INVALID ";
+ #endif
+- std::cerr << std::endl;
+-#endif
+- }
++ std::cerr << std::endl;
++#endif // defined(PPL_HAVE_FENV_H)
+ exit(1);
+ }
+
diff --git a/debian/patches/debian-changes-0.10.2-5 b/debian/patches/debian-changes-0.10.2-5
new file mode 100644
index 0000000..e86ddff
--- /dev/null
+++ b/debian/patches/debian-changes-0.10.2-5
@@ -0,0 +1,75 @@
+Description: Upstream changes introduced in version 0.10.2-5
+ This patch has been created by dpkg-source during the package build.
+ Here's the last changelog entry, hopefully it gives details on why
+ those changes were made:
+ .
+ ppl (0.10.2-5) unstable; urgency=low
+ .
+ * Dropped versioned build dep on libgmp3-dev as even etch has a sufficiently
+ new version.
+ * Dropped build dep on quilt.
+ * Added upstream patches to work around incomplete signal handling on hurd.
+ * Disable 2 Prolog tests as there is some failure on PowerPC only that I'm
+ unable to debug. Closes: #570387.
+ .
+ The person named in the Author field signed this changelog entry.
+Author: Michael Tautschnig <mt at debian.org>
+Bug-Debian: http://bugs.debian.org/570387
+
+---
+The information above should follow the Patch Tagging Guidelines, please
+checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
+are templates for supplementary fields that you might want to add:
+
+Origin: <vendor|upstream|other>, <url of original patch>
+Bug: <url in upstream bugtracker>
+Bug-Debian: http://bugs.debian.org/<bugnumber>
+Forwarded: <no|not-needed|url proving that it has been forwarded>
+Reviewed-By: <name and email of someone who approved the patch>
+Last-Update: <YYYY-MM-DD>
+
+--- ppl-0.10.2.orig/interfaces/Prolog/tests/ppl_interface_generator_prolog_generated_test_pl_code.m4
++++ ppl-0.10.2/interfaces/Prolog/tests/ppl_interface_generator_prolog_generated_test_pl_code.m4
+@@ -799,24 +799,24 @@ ppl_ at CLASS@_bounds_from_ at ABOVEBELOW@_2_t
+ TEST_DATA \= test05,
+ (
+ ppl_ at TOPOLOGY@@CLASS at _build_test_object(TEST_DATA, PS, Space_Dim),
+- ((
+- class_ at DISJUNCT@ \= class_Grid,
+- ppl_bounds_test_data(TEST_DATA, @CONSTRAINER at s, LE,
+- @ABOVEBELOW@, true))
+- ->
+- ppl_ at CLASS@_bounds_from_ at ABOVEBELOW@(PS, LE)
+- ;
+- true
+- ),
+- ((
+- class_ at DISJUNCT@ \= class_Grid,
+- ppl_bounds_test_data(TEST_DATA, @CONSTRAINER at s, LE1,
+- @ABOVEBELOW@, false))
+- ->
+- \+ ppl_ at CLASS@_bounds_from_ at ABOVEBELOW@(PS, LE1)
+- ;
+- true
+- ),
++dnl ((
++dnl class_ at DISJUNCT@ \= class_Grid,
++dnl ppl_bounds_test_data(TEST_DATA, @CONSTRAINER at s, LE,
++dnl @ABOVEBELOW@, true))
++dnl ->
++dnl ppl_ at CLASS@_bounds_from_ at ABOVEBELOW@(PS, LE)
++dnl ;
++dnl true
++dnl ),
++dnl ((
++dnl class_ at DISJUNCT@ \= class_Grid,
++dnl ppl_bounds_test_data(TEST_DATA, @CONSTRAINER at s, LE1,
++dnl @ABOVEBELOW@, false))
++dnl ->
++dnl \+ ppl_ at CLASS@_bounds_from_ at ABOVEBELOW@(PS, LE1)
++dnl ;
++dnl true
++dnl ),
+ ppl_ at CLASS@_OK(PS),
+ ppl_delete_ at CLASS@(PS)
+ ->
diff --git a/debian/patches/eab6ab2fd4e44c8e7348c26112e4c9e4190e88ee b/debian/patches/eab6ab2fd4e44c8e7348c26112e4c9e4190e88ee
new file mode 100644
index 0000000..1b1c4c4
--- /dev/null
+++ b/debian/patches/eab6ab2fd4e44c8e7348c26112e4c9e4190e88ee
@@ -0,0 +1,113 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Wed, 17 Feb 2010 11:22:12 +0000 (+0100)
+Subject: Cater for systems where setitimer() is not provided (part 3).
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=eab6ab2fd4e44c8e7348c26112e4c9e4190e88ee
+
+Cater for systems where setitimer() is not provided (part 3).
+---
+
+diff --git a/Watchdog/src/Watchdog.cc b/Watchdog/src/Watchdog.cc
+index 1b2fcb2..68ed01f 100644
+--- a/Watchdog/src/Watchdog.cc
++++ b/Watchdog/src/Watchdog.cc
+@@ -24,6 +24,8 @@ site: http://www.cs.unipr.it/ppl/ . */
+
+ #include "Watchdog.defs.hh"
+
++namespace PWL = Parma_Watchdog_Library;
++
+ #if PWL_HAVE_DECL_SETITIMER
+
+ #include <csignal>
+@@ -54,8 +56,6 @@ site: http://www.cs.unipr.it/ppl/ . */
+ #define THE_SIGNAL SIGPROF
+ #endif
+
+-namespace PWL = Parma_Watchdog_Library;
+-
+ using std::cerr;
+ using std::endl;
+
+@@ -222,11 +222,8 @@ PWL::Watchdog::remove_watchdog_event(WD_Pending_List::Iterator position) {
+
+ PWL::Time PWL::Watchdog::reschedule_time(1);
+
+-#endif // PWL_HAVE_DECL_SETITIMER
+-
+ void
+ PWL::Watchdog::initialize() {
+-#if PWL_HAVE_DECL_SETITIMER
+ signal_once.it_interval.tv_sec = 0;
+ signal_once.it_interval.tv_usec = 0;
+
+@@ -239,11 +236,12 @@ PWL::Watchdog::initialize() {
+ s.sa_flags = 0; // Was SA_ONESHOT: why?
+
+ my_sigaction(THE_SIGNAL, &s, 0);
+-#endif // PWL_HAVE_DECL_SETITIMER
+ }
+
+ void
+ PWL::Watchdog::finalize() {
+ }
+
++#endif // PWL_HAVE_DECL_SETITIMER
++
+ unsigned int PWL::Init::count = 0;
+diff --git a/Watchdog/src/Watchdog.inlines.hh b/Watchdog/src/Watchdog.inlines.hh
+index 016926d..80258dd 100644
+--- a/Watchdog/src/Watchdog.inlines.hh
++++ b/Watchdog/src/Watchdog.inlines.hh
+@@ -71,6 +71,24 @@ Watchdog::reschedule() {
+ set_timer(reschedule_time);
+ }
+
++inline
++Init::Init() {
++ // Only when the first Init object is constructed...
++ if (count++ == 0) {
++ // ... the library is initialized.
++ Watchdog::initialize();
++ }
++}
++
++inline
++Init::~Init() {
++ // Only when the last Init object is destroyed...
++ if (--count == 0) {
++ // ... the library is finalized.
++ Watchdog::finalize();
++ }
++}
++
+ #else // !PWL_HAVE_DECL_SETITIMER
+
+ template <typename Flag_Base, typename Flag>
+@@ -91,14 +109,11 @@ inline
+ Watchdog::~Watchdog() {
+ }
+
+-#endif // !PWL_HAVE_DECL_SETITIMER
+-
+ inline
+ Init::Init() {
+ // Only when the first Init object is constructed...
+ if (count++ == 0) {
+ // ... the library is initialized.
+- Watchdog::initialize();
+ }
+ }
+
+@@ -107,10 +122,11 @@ Init::~Init() {
+ // Only when the last Init object is destroyed...
+ if (--count == 0) {
+ // ... the library is finalized.
+- Watchdog::finalize();
+ }
+ }
+
++#endif // !PWL_HAVE_DECL_SETITIMER
++
+ } // namespace Parma_Watchdog_Library
+
+ #endif // !defined(PWL_Watchdog_inlines_hh)
diff --git a/debian/patches/f0cd7dc9899fc7dac2580a97da69e6282bfc0576 b/debian/patches/f0cd7dc9899fc7dac2580a97da69e6282bfc0576
new file mode 100644
index 0000000..22253e0
--- /dev/null
+++ b/debian/patches/f0cd7dc9899fc7dac2580a97da69e6282bfc0576
@@ -0,0 +1,86 @@
+From: Roberto Bagnara <bagnara at cs.unipr.it>
+Date: Wed, 17 Feb 2010 10:55:16 +0000 (+0100)
+Subject: Build the PWL unless not explicitly disabled at configuration time.
+X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=commitdiff_plain;h=f0cd7dc9899fc7dac2580a97da69e6282bfc0576
+
+Build the PWL unless not explicitly disabled at configuration time.
+---
+
+diff --git a/Watchdog/configure.ac b/Watchdog/configure.ac
+index b0d2f4b..d4e2b86 100644
+--- a/Watchdog/configure.ac
++++ b/Watchdog/configure.ac
+@@ -332,26 +332,14 @@ no)
+ esac
+ AM_CONDITIONAL(VALGRIND_TESTS_ENABLED, test x"$enable_valgrind_tests" = xyes)
+
+-# setitimer() is a strong requisite for the PWL.
+-AC_CHECK_FUNCS([setitimer], [have_setitimer=yes], [have_setitimer=no])
+-
+-enableval=default
++enableval=yes
+ AC_MSG_CHECKING([whether to build the Parma Watchdog Library])
+ AC_ARG_ENABLE(watchdog,
+ AS_HELP_STRING([--enable-watchdog],
+ [build also the Parma Watchdog Library]))
+ case "${enableval}" in
+ yes)
+- if test x"$have_setitimer" = xyes
+- then
+- build_watchdog_library=yes
+- else
+- AC_MSG_ERROR([CANNOT BUILD THE WATCHDOG LIBRARY
+-*** THE SYSTEM DOES NOT PROVIDE THE SETITIMER FUNCTION.])
+- fi
+- ;;
+-default)
+- build_watchdog_library=$have_setitimer
++ build_watchdog_library=yes
+ ;;
+ no)
+ build_watchdog_library=no
+@@ -371,6 +359,11 @@ then
+
+ # Checks for the availability of C library functions in C++.
+ AC_CHECK_DECLS([getenv], , , [#include <cstdlib>])
++ AC_CHECK_DECLS([setitimer], [], [], [[
++#ifdef HAVE_SYS_TIME_H
++# include <sys/time.h>
++#endif
++ ]])
+ AC_CHECK_DECLS([sigaction], , , [#include <csignal>])
+
+ # Checks for typedefs, structures, and compiler characteristics.
+diff --git a/configure.ac b/configure.ac
+index d67f0ff..13fc9e8 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -762,26 +762,14 @@ fi
+ extra_includes="${extra_includes}${extra_includes:+ }${gmp_includes_option}"
+ extra_libraries="${extra_libraries}${extra_libraries:+ }${gmp_library_option}"
+
+-# setitimer() is a strong requisite for the PWL.
+-AC_CHECK_FUNCS([setitimer], [have_setitimer=yes], [have_setitimer=no])
+-
+-enableval=default
++enableval=yes
+ AC_MSG_CHECKING([whether to build the Parma Watchdog Library])
+ AC_ARG_ENABLE(watchdog,
+ AS_HELP_STRING([--enable-watchdog],
+ [build also the Parma Watchdog Library]))
+ case "${enableval}" in
+ yes)
+- if test x"$have_setitimer" = xyes
+- then
+- build_watchdog_library=yes
+- else
+- AC_MSG_ERROR([CANNOT BUILD THE WATCHDOG LIBRARY
+-*** THE SYSTEM DOES NOT PROVIDE THE SETITIMER FUNCTION.])
+- fi
+- ;;
+-default)
+- build_watchdog_library=$have_setitimer
++ build_watchdog_library=yes
+ ;;
+ no)
+ build_watchdog_library=no
diff --git a/debian/patches/series b/debian/patches/series
index cd26973..155c022 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,4 +2,17 @@ dfff7e13e8817970647c38289b1f4e8d94999ea2
b52a2d273f4f96eec4a2ac5bb453756906e52a88
325ba80abd8c06c5dd740d35064302bbe65e251b
21c69b39730e0fb032395b07467b2ac3936ca124
+7ba6445b1c5adb835e27d2f005779d4343721d21
+bad1f4e90af2d1368fee383f08c59316182de8dc
+9ba82c5fb51ff9f63818fa8c6f006a1900a70894
+f0cd7dc9899fc7dac2580a97da69e6282bfc0576
+9bdd6617be52573d3252687844d32001e671a126.debian
+8ac2c64c2e9fa2da2d02428fe51c34b8dca3d6ff.debian
+eab6ab2fd4e44c8e7348c26112e4c9e4190e88ee
+777f298702f1005f6c4f026fb7a4663bb8dadd0e.debian
+1fa465112d1f5519310f47de08494b765c420b8f.debian
+9b0ba93300fb829608d40e766b9f3f95c81962e1.debian
+3bbfa4bc9da9558d0b538c95c00607b2928bb9d1
+9a89bb0a926a098a6e06a18c36881786f45d678b.debian
+debian-changes-0.10.2-5
diff --git a/debian/rules b/debian/rules
index 5966aa0..fcb21dc 100755
--- a/debian/rules
+++ b/debian/rules
@@ -29,7 +29,7 @@ endif
# FOR AUTOCONF 2.52 AND NEWER ONLY
confflags += --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE)
-# only build the C and C++ interfaces
+# only build the C,C++,SWI-Prolog interfaces
confflags += --enable-interfaces=c,cxx,swi_prolog --disable-ppl_lpsol --disable-ppl_lcdd
ifneq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
@@ -77,7 +77,6 @@ ifeq ($(with_check),yes)
else
$(MAKE) $(NJOBS) check
endif
-# -$(MAKE) $(NJOBS) -C Watchdog check
else
@echo "Testsuite not run: $(with_check)."
endif
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/ppl.git
More information about the debian-science-commits
mailing list