[omniORB] omniidl2 code generation
Steven W. Brenneis
brennes1@rjrt.com
Wed, 09 Jun 1999 13:36:13 -0400
Stefan Seefeld wrote:
>
> Bruce Visscher wrote:
> >
> > David Riddoch wrote:
> >
> > > On Tue, 1 Jun 1999, Stefan Seefeld wrote:
> > >
> > > > And, while we are at it, I have a little wish list for omniidl2.
> > > > I'd like to be able to set with an option the prefix for generated
> > > > '#include <Foo.hh>' lines so they become '#include <prefix/Foo.hh>'
> > > > when 'prefix' is given as a command line option.
> >
> > Maybe I'm missing something, but what's wrong with "omniidl2 -Iprefix/"?
>
> the -I flag is used by omniidl2 (the preprocessor called by omniidl2) to
> locate the includes in the IDL file. For example if you have
>
> #ifndef _A_idl
> #define _A_idl
>
> #include <B.idl>
>
> interface A : A {};
>
> #endif
>
> then 'omniidl2 -Iprefix A.idl' would look in prefix for B.idl. However, it
> would generate code such as
>
> #ifndef __A_hh__
> #define __A_hh__
>
> #include <B.hh>
>
> ....
>
This may not be helpful, but if your A.idl has:
#include <prefix/B.idl>
omniidl2 will produce:
#ifndef _prefix_B_hh_EXTERNAL_GUARD
#define _prefix_B_hh_EXTERNAL_GUARD
#include <prefix/B.hh>
You may need a "-I../" (or whatever your preprocessor is looking for) on
the command line if A.idl and B.idl are actually in the same directory.
> but I want it to produce an include statement
>
> #include <prefix/B.hh>
>
> by some flag.
>
> Stefan
>
> _______________________________________________________
>
> Stefan Seefeld
> Departement de Physique
> Universite de Montreal
> email: seefelds@magellan.umontreal.ca
>
> _______________________________________________________
>
> ...ich hab' noch einen Koffer in Berlin...