[Webkit-unassigned] [Bug 170169] New: pthread_t not properly detected
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Mar 28 00:39:17 PDT 2017
https://bugs.webkit.org/show_bug.cgi?id=170169
Bug ID: 170169
Summary: pthread_t not properly detected
Product: WebKit
Version: WebKit Local Build
Hardware: PC
OS: Other
Status: NEW
Severity: Major
Priority: P2
Component: Tools / Tests
Assignee: webkit-unassigned at lists.webkit.org
Reporter: ajacoutot at gnome.org
CC: lforschler at apple.com
Hi.
WebKit checks for the pthread_np include file using:
_HAVE_CHECK_INCLUDE(HAVE_PTHREAD_NP_H pthread_np.h)
However, on at least OpenBSD this will always fail because this file is not usable by itself.
It is usually used in conjunction with '<pthread.h>'.
Determining if the include file pthread_np.h exists failed with the following output:
Change Dir: /hack/objdirs/pobj/webkitgtk4-2.16.0/build-amd64/CMakeFiles/CMakeTmp
Run Build Command:"/usr/local/bin/ninja" "cmTC_05d43"
[1/2] Building C object CMakeFiles/cmTC_05d43.dir/CheckIncludeFile.c.o
FAILED: CMakeFiles/cmTC_05d43.dir/CheckIncludeFile.c.o
/hack/objdirs/pobj/webkitgtk4-2.16.0/bin/cc -O2 -pipe -I/usr/X11R6/include -fno-exceptions -fno-strict-aliasing -o CMakeFiles/cmTC_05d43.dir/CheckIncludeFile.c.o -c /hack/objdirs/pobj/webk
itgtk4-2.16.0/build-amd64/CMakeFiles/CMakeTmp/CheckIncludeFile.c
In file included from /hack/objdirs/pobj/webkitgtk4-2.16.0/build-amd64/CMakeFiles/CMakeTmp/CheckIncludeFile.c:1:0:
/usr/include/pthread_np.h:46:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
int pthread_mutexattr_getkind_np(pthread_mutexattr_t);
^
/usr/include/pthread_np.h:47:34: error: unknown type name 'pthread_mutexattr_t'
int pthread_hmutexattr_setkind_np(pthread_mutexattr_t *, int);
^
/usr/include/pthread_np.h:48:37: error: expected ')' before 'const'
void pthread_set_name_np(pthread_t, const char *);
^
/usr/include/pthread_np.h:49:44: error: expected ')' before '*' token
int pthread_stackseg_np(pthread_t, stack_t *);
^
/hack/objdirs/pobj/webkitgtk4-2.16.0/build-amd64/CMakeFiles/CMakeTmp/CheckIncludeFile.c:9:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
int main(void)
^
ninja: build stopped: subcommand failed.
Previous versions did not have this issue because it was explicitely declared under Source/WTF/wtf/Platform.h:
#if (OS(FREEBSD) || OS(OPENBSD)) && !defined(__GLIBC__)
#define HAVE_PTHREAD_NP_H 1
#endif
I am not sure how (or even if) it is possible to add a dependent include to _HAVE_CHECK_INCLUDE.
Using autoconf, I'd do something like:
AC_CHECK_HEADERS([pthread_np.h],,,
[#ifdef HAVE_PTHREAD_H
#include <pthread.h.h>
#endif])
Thanks.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20170328/874f780c/attachment-0001.html>
More information about the webkit-unassigned
mailing list