Re: ROOT-5.24.00 vs ROOT-5.22.00 with reflex dictionary

From: Xinchun Tian <tianxc_at_fnal.gov>
Date: Thu, 12 Nov 2009 15:15:09 -0500


HI Roel,

Following your suggestions, the compile fails with the following errors which are the same between v5.22.00 and v5.24.00.

Any ideas?

Thanks,
Xinchun

#CMT---> building static library ../x86_64-sl5-gcc41-dbg/libEventDataModel.a #CMT---> building shared library ../x86_64-sl5-gcc41-dbg/libEventDataModel.so EventDataModeltemp_shlib/Event.o: In function `__static_initialization_and_destruction_0': /home/tianxc/offline/nova-trunk/fmwk/EventDataModel/cmt/../src/Event.cxx:15: undefined reference to `ROOT::GenerateInitInstance(edm::Event const*)' EventDataModeltemp_shlib/Event.o: In function `edm::Event::IsA() const': /home/tianxc/offline/nova-trunk/fmwk/EventDataModel/EventDataModel/Event.h:41: undefined reference to `edm::Event::Class()' EventDataModeltemp_shlib/Event.o: In function `EventHeader':

/home/tianxc/offline/nova-trunk/fmwk/EventDataModel/EventDataModel/EventHeader.h:15: undefined reference to `vtable for edm::EventHeader'
EventDataModeltemp_shlib/Event.o:(.data.rel.ro._ZTVN3edm5EventE[vtable for edm::Event]+0x1d0): undefined reference to `edm::Event::ShowMembers(TMemberInspector&, char*)'
EventDataModeltemp_shlib/Event.o:(.data.rel.ro._ZTVN3edm5EventE[vtable for edm::Event]+0x1d8): undefined reference to `edm::Event::Streamer(TBuffer&)'
collect2: ld returned 1 exit status
make[3]: *** [../x86_64-sl5-gcc41-dbg/libEventDataModel.so] Error 1
make[2]: *** [EventDataModel] Error 2
make[1]: *** [common_target] Error 2

make: *** [check_config] Error 2

On Thu, Nov 12, 2009 at 2:24 AM, Roel Aaij <Roel.Aaij_at_cern.ch> wrote:

    Hi Xinchun,

> The reflex dictionary was generated successfully with ROOT-5.22.00(a,c), but with the following errors with 5.24.00, 5.24.00b and 5.25.02. Any help? Thank.
> The OS is SL Fermi 5.2/4.6, GCC4.1.2/3.4.6, similar on mac 10.5.8.
>
> # Now trying [make] in /home/tianxc/offline/nova-trunk/fmwk/EventDataModel/cmt (9/17)
> #--------------------------------------------------------------
> ..............snipped..................
> #CMT---> (constituents.make) install_more_includes done
> #CMT---> (constituents.make) Building EventDataModelGen.make
> #CMT---> Info: Document EventDataModelGen
> #CMT---> (constituents.make) Creating EventDataModelGen.lock and Starting EventDataModelGen
> ../x86_64-sl5-gcc41-dbg/dict/EventDataModel/dict_dict.cpp dict.h
> --->> genreflex: INFO: Parsing file /home/tianxc/offline/nova-trunk/fmwk/EventDataModel/dict/dict.h with GCC_XML OK
> --->> genreflex: INFO: Generating Reflex Dictionary
> --->> genreflex: ERROR: class edm::EventHeader derives from TObject but does not use ClassDef!
> --->> You MUST put ClassDef(edm::EventHeader, 1); into the class definition.
> --->> genreflex: ERROR: class edm::Event derives from TObject but does not use ClassDef!
> --->> You MUST put ClassDef(edm::Event, 1); into the class definition.

    All ROOT objects inherit from TObject and contain the ClassDef and     ClassImp macros in their source code. It takes care of things like     streamers, schema evolution and integration with ROOT. A good example is     the Event class in the $ROOTSYS/test directory. I guess reflex has     become stricter in the newer releases.

    To fix this error, add ClassDef(edm::Event, 1) to your Event and     EventHeader classes inside a private section of their definitions. When     you change a class, don't forget to increment its integer.

    Also add ClassImp( edm::Event ) to their implementation files. If you     define the class methods in the same file as the class, add ClassImp     outside and after a class' definition.

> class edm::EventHandle
> class edm::EventHeader
> class edm::Event
> Running merge_rootmap EventDataModelGen
> #CMT---> (constituents.make) EventDataModelGen done
> #CMT---> (constituents.make) Building EventDataModelDict.make
> #CMT---> Info: Library EventDataModelDict
> #CMT---> (constituents.make) Starting EventDataModelDict
> #CMT---> (EventDataModelDict.make) Rebuilding ../x86_64-sl5-gcc41-dbg/EventDataModelDict_dependencies.make
> #CMT---> compiling ../x86_64-sl5-gcc41-dbg/dict/EventDataModel/dict_dict.cpp
> #CMT---> building static library ../x86_64-sl5-gcc41-dbg/libEventDataModelDict.a
> #CMT---> building shared library ../x86_64-sl5-gcc41-dbg/libEventDataModelDict.so
> #CMT---> EventDataModelDict : library ok
> #CMT---> EventDataModelDict ok
> .............snipped.........

    Greetz, Roel Received on Thu Nov 12 2009 - 21:15:13 CET

This archive was generated by hypermail 2.2.0 : Tue Nov 17 2009 - 05:50:04 CET