Your message dated Tue, 16 Jul 2013 08:50:52 +0200
with message-id <[email protected]>
and subject line
has caused the Debian Bug report #715166,
regarding check: FTBFS on hurd-i386
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.)
--
715166: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=715166
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Source: check
Version: 0.9.10-3
Severity: important
Tags: patch
User: [email protected]
Usertags: hurd
Control: forwarded -1 https://sourceforge.net/p/check/patches/49/
Hi,
check 0.9.10-3 does not build on hurd-i386 [1].
The problem is due to the second-only precision which is available with
alarm in the replacement for the timer_* functions (not implemented yet
on Hurd), which causes few check failures in two tests.
I just reported the issue upstream [2] with a clean patch for the issue;
since that requires autoreconf, I'm providing a simplier patch which
just unconditionally switches the timer_settimer replacement to
setitimer; should cause no issues on Linux and kFreeBSD, since both
implement the timer_* functions.
Both patches (the one sent upstream and the one attached here) fix the
issue on Hurd.
[1]
https://buildd.debian.org/status/fetch.php?pkg=check&arch=hurd-i386&ver=0.9.10-3&stamp=1373106835
[2] https://sourceforge.net/p/check/patches/49/
Thanks,
--
Pino
--- a/lib/timer_settime.c
+++ b/lib/timer_settime.c
@@ -1,22 +1,18 @@
#include "libcompat.h"
+#include <sys/time.h>
+
int timer_settime(timer_t timerid CK_ATTRIBUTE_UNUSED,
int flags CK_ATTRIBUTE_UNUSED,
const struct itimerspec *new_value,
struct itimerspec * old_value CK_ATTRIBUTE_UNUSED)
{
- int seconds = new_value->it_value.tv_sec;
-
- /*
- * As the alarm() call has only second precision, if the caller
- * specifies partial seconds, we round up to the nearest second.
- */
- if(new_value->it_value.tv_nsec > 0)
- {
- seconds += 1;
- }
-
- alarm(seconds);
-
- return 0;
+ struct itimerval new;
+
+ new.it_value.tv_sec = new_value->it_value.tv_sec;
+ new.it_value.tv_usec = new_value->it_value.tv_nsec / 1000;
+ new.it_interval.tv_sec = new_value->it_interval.tv_sec;
+ new.it_interval.tv_usec = new_value->it_interval.tv_nsec / 1000;
+
+ return setitimer(ITIMER_REAL, &new, NULL);
}
--- End Message ---
--- Begin Message ---
Version: 0.9.10-4
Seems that there was a temporary issue with the hurd buildd.
--- End Message ---