[omniORB] The STL errors when I build omniEvent ...

steven#staff steven@jpc.com.tw
Tue, 14 Sep 1999 13:27:46 +0800


After I add the -I/.../.../... for STL in the dir.mk
It still can't find the <list> and <set> like before.
Then I change the include file in the CosEvent_i.h:
#include <list> ---> #include <list.h>
#include <set> ---> #include <set.h>
Then the include files could be found.
But the new error message become :
....
+ rm -f libomniEvents.a
+ ar cq libomniEvents.a CosEvent_i.o
+ ranlib libomniEvents.a
CC -c -O2 -fsimple  -D__OMNIORB2__ -I../../../stub -DUsePthread -D_REENTRANT
 -mt
 -D__STL_NO_NAMESPACES -I/jpc/tim/stl  -I.  -I../../../include -D__sparc__ -
D__s
unos__ -D__OSVERSION__=5 -o eventd.o eventd.cc
"eventd.cc", line 89: Error: The function signal must have a prototype.
1 Error(s) detected.
make: *** [eventd.o] Error 1

Then I remark the two lines below in the CosEvent_i.h:
// #ifdef __linux__
#include <signal.h>
file:// #endif

This "signal" problem seem solved. But I am not sure it is a right way to
slove this problem.
And I re-make it . The new problem become:
....
+ rm -f eventd
+ CC -o eventd -O2 -fsimple -R
../../../lib/sun4_sosV_5.6 -L../../../lib/sun4_so
sV_5.6 eventd.o ../../../stub/NamingSK.o ../../../stub/CosLifeCycleSK.o
../../..
/stub/CosEventCommSK.o ../../../stub/CosEventChannelAdminSK.o
../../../stub/Even
tChannelAdminSK.o ../../../stub/NamingDynSK.o
../../../stub/CosLifeCycleDynSK.o
../../../stub/CosEventCommDynSK.o ../../../stub/CosEventChannelAdminDynSK.o
../.
./../stub/EventChannelAdminDynSK.o -lomniORB2 -lomniDynamic2 -lomnithread -l
pthr
ead -lposix4 -mt -lsocket -lnsl -ltcpwrapGK libomniEvents.a
ld: fatal: symbol `operator new(unsigned int, void*)' is multiply defined:
        (file eventd.o and file libomniEvents.a(CosEvent_i.o));
ld: fatal: File processing errors. No output written to eventd
make: *** [eventd] Error 1

This time I have no any idea.
What's wrong ?
Any one can help me ?
Thank you very much.
Thank you.



----- Original Message -----
From: Sai-Lai Lo <S.Lo@uk.research.att.com>
To: steven#staff <steven@jpc.com.tw>
Cc: <omniorb-list@uk.research.att.com>
Sent: Tuesday, September 14, 1999 5:09 AM
Subject: Re: [omniORB] The STL errors when I build omniEvent ...


Looks like your compiler (Sun C++ 4.2?) does not have STL. If you have STL
installed in /usr/local/STL for example:

Just edit <top>/mk/platforms/sun4_sosV_5.6.mk:

CXXOPTIONS = -I/usr/local/STL

Alternatively, edit the individual dir.mk (where the compilation failed):

DIR_CPPFLAGS += -I/usr/local/STL.

Sai-Lai


>>>>> steven#staff  writes:

> Hi:

> I download the omniEvent and build it on sun4_sosV_5.6.

> I got the error below:

> "CosEvent_i.h", line 68: Error: Could not open include file <list>.
> "CosEvent_i.h", line 69: Error: Could not open include file <set>.
> "CosEvent_i.h", line 177: Error: Type name expected instead of "list".

> ...

> I think these errors is caused by not finding the .h of STL.

> What should I do ? Repare it in the dir.mk ? Which line to rewrite ?

> Or should I put something in the dir.mk ? Or any other method to solve
this simple problem?

>

> Thank you for your help for such easy problem!!

> Thank you !!!

>

--
Sai-Lai Lo                                   S.Lo@uk.research.att.com
AT&T Laboratories Cambridge           WWW:   http://www.uk.research.att.com
24a Trumpington Street                Tel:   +44 1223 343000
Cambridge CB2 1QA                     Fax:   +44 1223 313542
ENGLAND