[omniORB] Conflict with "StructMember"

Mike Ladwig mike@twinpeaks.prc.com
Thu, 15 Apr 1999 10:27:24 -0400


Sorry - I made a minor error in my posting; I'm not including "ir.idl"
to get TypeCode, but rather to get the InterfaceDef type.  The rest of
the problem remains the same.

I have been able to reproduce the problem using the echo example in the
distribution.  I modified echo.idl to include <ir.idl>, and added the
appropriate -I directives (mine have "mike" in them) in config/unix.mk.

OMNIORB2_IDL_ANY_FLAGS = -a -I/home/mike/omniORB_2.7.1/idl
OMNIORB2_IDL = $(OMNIORB2_IDL_ONLY) $(OMNIORB2_IDL_ANY_FLAGS)
OMNIORB2_CPPFLAGS = -D__OMNIORB2__ -I$(CORBA_STUB_DIR)
$(OMNITHREAD_CPPFLAGS) -I/home/mike/omniORB_2.7.1/include/omniORB2

mike.

David Riddoch wrote:
> 
> You do not need to include ir.idl to use TypeCode. It is automatically
> pre-defined by the compiler. You should refer to it with its fully
> qualified name, CORBA::TypeCode.
> 
> David
> 
> On Wed, 14 Apr 1999, Mike Ladwig wrote:
> 
> > Hi.  I am porting some code from Orbix, and have had generally decent
> > luck so far.  I am stuck, however, on a problem porting my
> > implementation of the Query service.  I've looked in the mailing list
> > archives without luck.
> >
> > In my "CosQuery.idl" file, I need the definition of TypeCode, so I
> > include "ir.idl" to get it.  The idl compiler generates a stub/skeleton
> > file that includes the generated "CosQuery.hh" file, which in turn
> > includes "ir.hh".
> >
> > The "ir.hh" file includes both CORBA.h and corbaidl.hh.  These files
> > both attempt to define several conflicting names (starting with
> > ::CORBA::StructMember), and my compilation fails.
> >
> > Any suggestions?  I'm sure I'm missing something because this seems to
> > be a common thing to wish to accomplish, but I can't figure out what...
> >
> > Thanks,
> > mike.
> >
> >