Messages in this thread | | | Date | Wed, 6 Mar 1996 11:31:50 -0500 (EST) | From | Eric Plante <> | Subject | Problem compiling w/POSIX threads (fwd) |
| |
I'm resending this, semms that vger ate it (I haven't received a copy of it and I usually do, and I haven't had replies either :-) )
---------- Forwarded message ---------- Date: Fri, 1 Mar 1996 18:07:35 -0500 From: Eric Plante <planteer@jsp.umontreal.ca> To: linux-kernel@vger.rutgers.edu Newgroups: comp.os.linux.development, comp.os.linux.development.apps Subject: Problem compiling w/POSIX threads
Are posix threads part of linux? It does look so because /usr/include/pthread.h does exist on my system (dated june 95 though, that might be old -- where to get newer stuff?), however the file looks a bit wierd. It contains essentially this:
#ifdef _MIT_POSIX_THREADS #include <pthread/mit/pthread.h> #endif
So I understand that _MIT_POSIX_THREADS must be defined for anything using posix threads to compile. So that's what I did, and here's what comes out of it:
monLinux:~/xrec$ gcc -c xrec_main.c -D_MIT_POSIX_THREADS In file included from /usr/include/pthread/mit/cond.h:45, from /usr/include/pthread/mit/pthread.h:56, from /usr/include/pthread.h:9, from xrec_main.c:3: /usr/include/pthread/mit/sys/timers.h:46: redefinition of `struct timespec'
What xrec_main does is irrelevent, since this happens on line 3 of the source which is "#include <pthread.h>".I've taken a quick look, and in the file /usr/include/pthread/mit/fd.h there is a line that goes:
struct timespec;
And in the file /usr/include/pthread/mit/sys/timer.h there is a line that goes:
struct timespec { time_t ts_sec; long ts_nsec; };
SO.. Am I doing something stupid?
(Please reply directly to my address, or to linux-kernel)
+--Eric Plante------------------------------------------------------+ | «Des femmes nues se jetaient dans ses bras avec une joie démente» | | - Boris Vian | +-http://www.jsp.umontreal.ca/~planteer/ ---------------------------+
| |