From 6925863122068b099e10ff5d0a09d982a463bfbe Mon Sep 17 00:00:00 2001 From: "commit-queue@webkit.org" Date: Tue, 21 Feb 2012 02:12:24 +0000 Subject: [PATCH] Does not build on GNU Hurd https://bugs.webkit.org/show_bug.cgi?id=79045 Patch by Pino Toscano on 2012-02-20 Reviewed by Gustavo Noronha Silva. * wtf/Platform.h: define WTF_OS_HURD. * wtf/ThreadIdentifierDataPthreads.cpp: adds a band-aid fix for the lack of PTHREAD_KEYS_MAX definition, with a value which should not cause issues. git-svn-id: http://svn.webkit.org/repository/webkit/trunk@108279 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- Source/JavaScriptCore/ChangeLog | 12 ++++++++++++ Source/JavaScriptCore/wtf/Platform.h | 6 ++++++ Source/JavaScriptCore/wtf/ThreadIdentifierDataPthreads.cpp | 4 ++-- 3 files changed, 20 insertions(+), 2 deletions(-) diff --git a/Source/JavaScriptCore/ChangeLog b/Source/JavaScriptCore/ChangeLog index 1c6e30d..170fd13 100644 --- a/Source/JavaScriptCore/ChangeLog +++ b/Source/JavaScriptCore/ChangeLog @@ -1,3 +1,15 @@ +2012-02-20 Pino Toscano + + Does not build on GNU Hurd + https://bugs.webkit.org/show_bug.cgi?id=79045 + + Reviewed by Gustavo Noronha Silva. + + * wtf/Platform.h: define WTF_OS_HURD. + * wtf/ThreadIdentifierDataPthreads.cpp: adds a band-aid fix + for the lack of PTHREAD_KEYS_MAX definition, with a value which + should not cause issues. + 2012-02-20 Gavin Barraclough Unreviewed windows build fix. diff --git a/Source/JavaScriptCore/wtf/Platform.h b/Source/JavaScriptCore/wtf/Platform.h index 8d02445..faa0c08 100644 --- a/Source/JavaScriptCore/wtf/Platform.h +++ b/Source/JavaScriptCore/wtf/Platform.h @@ -351,6 +351,11 @@ #define WTF_OS_FREEBSD 1 #endif +/* OS(HURD) - GNU/Hurd */ +#ifdef __GNU__ +#define WTF_OS_HURD 1 +#endif + /* OS(LINUX) - Linux */ #ifdef __linux__ #define WTF_OS_LINUX 1 @@ -394,6 +399,7 @@ || OS(ANDROID) \ || OS(DARWIN) \ || OS(FREEBSD) \ + || OS(HURD) \ || OS(LINUX) \ || OS(NETBSD) \ || OS(OPENBSD) \ diff --git a/Source/JavaScriptCore/wtf/ThreadIdentifierDataPthreads.cpp b/Source/JavaScriptCore/wtf/ThreadIdentifierDataPthreads.cpp index b3b690f..0badf93 100644 --- a/Source/JavaScriptCore/wtf/ThreadIdentifierDataPthreads.cpp +++ b/Source/JavaScriptCore/wtf/ThreadIdentifierDataPthreads.cpp @@ -36,8 +36,8 @@ #include "Threading.h" -#if OS(ANDROID) -// PTHREAD_KEYS_MAX is not defined in bionic, so explicitly define it here. +#if OS(ANDROID) || OS(HURD) +// PTHREAD_KEYS_MAX is not defined in bionic nor in Hurd, so explicitly define it here. #define PTHREAD_KEYS_MAX 1024 #else #include -- 2.7.4