[omniORB] Linking Problems

Alfonso Tames alfonso@tames.com
Thu Nov 28 03:27:01 2002


This works for me using omniORB_3.0.5:

g++ myprogram.cc -D__OMNIORB3__ -D_REENTRANT -D__x86__ -D__linux__
-D__OSVERSION__=2 -I/usr/local/omni/include -I./
-L/usr/local/omni/lib/i586_linux_2.0_glibc2.1 -lomniDynamic3 -lomniORB3
-lomnithread -ltcpwrapGK objectsSK.o -o myprogram

I have omniORB in /usr/local/omni

Hope this helps...

On Wed, 2002-11-27 at 20:23, bido@mac.com wrote:
> I just got my new CORBA book and I'm trying to build a basic 
> client-server example. The files compiled fine with just some seemingly 
> harmless warnings i.e.,
> 
> $ g++ -c -I. -I/usr/local/include server.cc
> cc1plus: warning: changing search order for system directory 
> "/usr/local/include"
> cc1plus: warning:   as it has already been specified as a non-system 
> directory
> 
> $ ls
> client.cc server.cc server.o  time.idl  timeSK.o
> client.o  server.hh time.hh   timeSK.cc
> 
> linking is not working, I figured that I'm missing lib paths, flags 
> -you name it. Must I mimic the make files from the omniORB examples? 
> This approach seems very tedious. In any event, here's what I get:
> 
> $ g++ -o myserver timeSK.o server.o -L/usr/local/lib
> ld: Undefined symbols:
> _CORBA_use_nil_ptr_as_nil_objref()
> omniObjRef::_unMarshal(char const*, cdrStream&)
> omniObjRef::_realNarrow(char const*)
> omniObjRef::_enableShortcut(omniServant*, bool const*)
> omniObjRef::_uncheckedNarrow(char const*)
> omniObjRef::_localServantTarget()
> ...
> 
> Thanks!
> -FB
> 
> _______________________________________________
> omniORB-list mailing list
> omniORB-list@omniorb-support.com
> http://www.omniorb-support.com/mailman/listinfo/omniorb-list
-- 
Alfonso Tames <alfonso@tames.com>
Mercadio