1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
Description: Fix test failures on hurd-i386.
Make madvise() no-op, not implemented on Hurd.
Skip threads tests, thread implementation problematic.
Author: Bas Couwenberg <sebastic@debian.org>
Forwarded: https://github.com/Leont/file-map/pull/6
--- a/lib/File/mmap-compat.c
+++ b/lib/File/mmap-compat.c
@@ -84,7 +84,7 @@ static size_t page_size() {
return pagesize;
}
-#ifdef VMS
+#if defined(VMS) || defined(__GNU__)
# define madvise(address, length, advice) 0
#elif defined(__CYGWIN__) || defined(__QNX__)
# define madvise posix_madvise
--- a/t/20-threads.t
+++ b/t/20-threads.t
@@ -5,7 +5,7 @@ use warnings;
use Config;
BEGIN {
# Yes, this is really necessary
- if ($Config{useithreads}) {
+ if ($Config{useithreads} && $^O ne 'gnu') {
require threads;
threads->import();
require Test::More;
|