Re: Linking (Again)



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thursday 05 June 2003 08:42, Murray Cumming Comneon com wrote:
> > From: Johan Cronje [mailto:jcronje dsp sun ac za]
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > Hello
> >
> > I sorted out most of my linking troubles (didn't see the
> > "extern" functions in
> > some of the generated files). I was wondering if someone
> > could please point
> > me in the right direction with the last few. Included is an
> > extract of my
> > generated sdr_corba.h file (generated using orbit-idl-2
> > --noskels --nostubs
> > - --nocommon sdr_corba.idl):
> >
> > #ifdef ORBIT_IDL_C_IMODULE_sdr_corba
> >    static
> > #else
> >    extern
> > #endif
> >    const struct CORBA_TypeCode_struct
> > TC_sdr_corba_component_name_struct;
> > #define TC_sdr_corba_component_name
> > ((CORBA_TypeCode)&TC_sdr_corba_component_name_struct)
> >
> > Now, the linker complains that "sdr_corba.o(.rodata+0x78):
> > undefined reference
> > to `TC_sdr_corba_component_name_struct'". So I suspect that I must
> > instanciate this variable, but my question is: how and where?
> >
> > Sorry if this seems trivial, but I'm quite new to all this. I
> > get similar
> > errors when I try to compile the examples in the "test"
> > directory that comes
> > with the orbitcpp source, so working through them didn't
> > solve my problem.
>
> Maybe you are not generating/building/linking the C stubs/skels. Do look at
> the libbonobomm makefiles for clues.

Figured it out! I wasn't aware that you should also generate the C stub, 
skeleton and common files. The problem was solved when I included the 
- -common.c file.

Thank you

Johan
- -- 
     "Let your conversation be without covetousness; and be 
      content with such things as ye have. For he hath said,
      I will never leave thee, nor forsake thee."      
                                             Hebrews 13:5 

- --------------------------------------------------------------------------------

"There is beauty in simplicity"		-- Johan Cronje

- --------------------------------------------------------------------------------
Johan Cronje

Digital Signal Processing / Telecommunications Group
Room E355
Department Electrical and Electronic Engineering
University of Stellenbosch

jcronje dsp sun ac za
http://www.dsp.sun.ac.za/~jcronje
GPG Key: http://www.dsp.sun.ac.za/~jcronje/jcronje.asc
- --------------------------------------------------------------------------------

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2-rc1-SuSE (GNU/Linux)

iD8DBQE+3wcbtFKZVBigPpsRAsEiAKCBdzN+sKVznAsJVPgSL8y1pDrWqQCgqKNq
E/qUDsaFN2azqUv8e8qlExA=
=+Jsh
-----END PGP SIGNATURE-----




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]