|Summary:||Definition for _POSIX_THREAD_PROCESS_SHARED missing ?|
|Product:||Red Hat Enterprise Linux 3||Reporter:||Martin Michalecz <mm.sgi>|
|Component:||glibc-kernheaders||Assignee:||Arjan van de Ven <arjanv>|
|Status:||CLOSED NOTABUG||QA Contact:||Brian Brock <bbrock>|
|Fixed In Version:||Doc Type:||Bug Fix|
|Doc Text:||Story Points:||---|
|Last Closed:||2004-01-09 12:51:56 UTC||Type:||---|
|oVirt Team:||---||RHEL 7.3 requirements from Atomic Host:|
Description Martin Michalecz 2004-01-09 09:14:57 UTC
From Bugzilla Helper: User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 4.0; T312461) Description of problem: ES 3 supports Native POSIX Thread Library (NPTL). Thus pthread_condattr_setpshared is supports. If this (optional) Posix features are available and support shared processes _POSIX_THREAD_PROCESS_SHARED should be defined after including unistd.h. That's my knowlegde (This might be incorrect. Sorry if so.) In any case _POSIX_THREAD_PROCESS_SHARED is not defined. -) Is my knowlegde incorrect ? -) Does I have to include some other *.h file (ptherad.h does not defione it either, grep did not find a match) ? -) Does ES 3 *NOT* support condition variables across processes ? -) Or is the definition simply missing ? Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1.Compile a source including <unistd.h> 2.Check presence using #ifdef ... 3. Actual Results: _POSIX_THREAD_PROCESS_SHARED is not defined Expected Results: _POSIX_THREAD_PROCESS_SHARED should be defined Additional info:
Comment 1 Martin Michalecz 2004-01-09 12:40:19 UTC
It looks like **I** make some mistake. I located alternate includefiles at /usr/include/nptl. In /usr/include/nptl/bits/posix_opt.h the desired #define is included. But I could not detect (until now) how to correctly include this file. I added -I /usr/include/nptl, but this does not work. I do not like to directly include some file from deeper directories and I think switching to ntpl must work withou editing sources (as long as no documented changes are required). I do not expect editing sources is required to get the correct includes. Please could someone give me some advice - or a pointer to the correct documentation. Thanks Martin Michalecz
Comment 2 Martin Michalecz 2004-01-09 12:51:56 UTC
--------------- PLEASE CLOSE ---------------- There was a simple typo in the include string. Adding -I/usr/include/nptl solves the problem. So if there is no information to be added from Redhat's side, this "bug" can be closed. Sorry for the effort I caused at your site.
Comment 3 Jakub Jelinek 2004-01-09 13:49:12 UTC
When you don't use -I/usr/include/nptl -L/usr/lib/nptl, the resulting program will run with both NPTL and LinuxThreads. Because LT doesn't support pshared primitives, _POSIX_THREAD_PROCESS_SHARED is not defined on purpose. If you build with -I/usr/include/nptl -L/usr/lib/nptl, ie. build a NPTL only program, then it is defined.