[RETRY} help in compiling the thread example in linux

Ramana K Ramachandran ramana@ix.netcom.com
Thu, 06 Nov 1997 19:04:37 -0600


<HTML>
hi
<BR>My earlier mail yesterday somehow never made it to the list. Sorry
if its a duplicate.

<P>I had the omniorb2 working and later I reinstalled RedHat 4.2 and now
I am
<BR>unable to compile. Its giving problems in the threads
<BR>I have LinuxThreads 0.5.1 installed&nbsp; and also I have timers.h
in the threads directory(pthread/mit/sys), So its not the problem listed
in the omniorb patches.

<P>$&nbsp; rpm -qa|grep -i thread
<BR>linuxthreads-0.5-1

<P>$ gcc -v
<BR>Reading specs from /usr/lib/gcc-lib/i386-linux/2.7.2.1/specs
<BR>gcc version 2.7.2.1
<BR>&nbsp;
<BR>&nbsp;

<P>When I run make on the /usr/local/omniORB_2.2.0/src/examples/thread
dir
<BR>I get ...

<P>gcc -c&nbsp; -fhandle-exceptions -Wall -Wno-unused -I../../../include
-D_REENTRANT -D__linux__ -D__i86__
<BR>-D__OSVERSION__=2 -o diner.o diner.cc
<BR>In file included from ../../../include/omnithread.h:116,
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
from diner.cc:32:
<BR>../../../include/omnithread/posix.h:37: pthread.h: No such file or
directory
<BR>make: *** [diner.o] Error 1

<P>I see that pthread is in dir "/usr/include/pthread/mit" so I try including
that
<BR>in the include path and I get...

<P>gcc -c&nbsp; -fhandle-exceptions -Wall -Wno-unused -c&nbsp; -fhandle-exceptions
-Wall -Wno
<BR>-unused -I../../../include -D_REENTRANT -D__linux__ -D__i86__ -D__OSVERSION__=2
<BR>-I/usr/include/pthread/mit -o diner.o diner.cc
<BR>In file included from /usr/include/pthread/mit/machdep.h:10,
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
from /usr/include/pthread/mit/pthread.h:49,
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
from ../../../include/omnithread/posix.h:37,
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
from ../../../include/omnithread.h:116,
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
from diner.cc:32:
<BR>/usr/include/pthread/mit/unistd.h:46: type specifier omitted for parameter
<BR>[...]

<P>Please help
<BR>thanks
<BR>ramana
<PRE>--&nbsp;
Ramana Ramachandran&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; off: 972-498-1029 ramana.ramachandran@mci.com
9468 E Valley Ranch pkwy #1052&nbsp;&nbsp;&nbsp; res: 972-830-9360 ramana@ix.netcom.com
Irving TX 75063</PRE>
&nbsp;</HTML>