Using NGPT per-application rather than distro-wide
Scott Anderson <[email protected]> 16 Jan 2003 12:33:54 -0500
| Newsgroups | gmane.linux.ngpt.user |
|---|---|
| Organization | BondDesk Group, LLC |
| Message-ID | <[email protected]> |
Hi all,
I'm a new user of NGPT, mainly because we need proper signal handling
and PID identification in our application (it runs across Win2K,
Solaris, and hopefully soon Linux as well).
I need to use the NGPT libpthread for compiling our application only, as
we use several JDKs that do not seem to work under NGPT.
I'm using gcc 3.2.1, glibc 2.3.1, and kernel 2.4.20 (with futex patch
applied).
With the following command line:
gcc -g -I/usr/local/dev/ngpt/include -malign-double -rdynamic
-finline-functions -D_REENTRANT -Wno-deprecated -fPIC
-I/usr/local/src/DEV1/include -o ./obj/file.o -c file.cpp
I'm getting this error:
gcc -g -I/usr/local/dev/ngpt/include -malign-double -rdynamic
-finline-functions -D_REENTRANT -Wno-deprecated -DBEXOS_LOCAL_INCLUDES
-fPIC -I/usr/local/src/DEV1/include -o ./obj/BDEvent.o -c BDEvent.cpp
In file included from /usr/local/dev/ngpt/include/pthread.h:122,
from
/usr/local/dev/gcc-3.2.1/include/c++/3.2.1/i686-pc-linux-gnu/bits/gthr-default.h:37,
from
/usr/local/dev/gcc-3.2.1/include/c++/3.2.1/i686-pc-linux-gnu/bits/gthr.h:98,
from
/usr/local/dev/gcc-3.2.1/include/c++/3.2.1/i686-pc-linux-gnu/bits/c++io.h:37,
from
/usr/local/dev/gcc-3.2.1/include/c++/3.2.1/bits/fpos.h:44,
from
/usr/local/dev/gcc-3.2.1/include/c++/3.2.1/bits/char_traits.h:46,
from
/usr/local/dev/gcc-3.2.1/include/c++/3.2.1/string:47,
from
/usr/local/dev/gcc-3.2.1/include/c++/3.2.1/stdexcept:45,
from /usr/local/src/DEV1/include/somefile.h:5,
from someheader.h:16,
from file.cpp:10:
/usr/include/bits/libc-lock.h:42: syntax error before `;' token
/usr/include/bits/libc-lock.h:221: `pthread_mutex_t' was not declared in
this
scope
/usr/include/bits/libc-lock.h:221: `__mutex' was not declared in this
scope
/usr/include/bits/libc-lock.h:222: parse error before `*' token
/usr/include/bits/libc-lock.h:224: `pthread_mutex_t' was not declared in
this
scope
[more of the same repeated for a while]
If I include <pthread.h> before the someheader.h include (which includes
stdexcept.h):
In file included from /usr/local/dev/ngpt/include/pthread.h:122,
from file.cpp:7:
/usr/include/bits/libc-lock.h:42: syntax error before `;' token
/usr/include/bits/libc-lock.h:221: `pthread_mutex_t' was not declared in
this
scope
/usr/include/bits/libc-lock.h:221: `__mutex' was not declared in this
scope
/usr/include/bits/libc-lock.h:222: parse error before `*' token
/usr/include/bits/libc-lock.h:224: `pthread_mutex_t' was not declared in
this
scope
/usr/include/bits/libc-lock.h:224: `__mutex' was not declared in this
scope
/usr/include/bits/libc-lock.h:226: `pthread_mutex_t' was not declared in
this
scope
etc.
Are there instructions somewhere that I have missed detailing how to use
NGPT for a single application only?
Any help you can provide in this is greatly appreciated; the thread
library is one of my final hurdles in my porting effort.
Regards,
-scott