GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » CBM » CBM computing and communication infrastructure » CINT -> g++
CINT -> g++ [message #4519] Wed, 20 June 2007 13:56 Go to next message
Konstantin Antipin is currently offline  Konstantin Antipin
Messages: 3
Registered: May 2007
Location: Frankfurt
occasional visitor

From: *ikf.physik.uni-frankfurt.de
Hi all,

I have a question concerning migration from CINT to g++.

Usually I am using root to load and execute macros with my tasks
for analysing data. So, I am using cint interpreter.

But currently I am interested to make a stand-alone program and thus use g++ for compiling.
So, I wrote a makefile (see attachment) and compiled my program. But when I am trying to execute it, it fails with segmentation error on loading libraries. I figured out, that the problem is in libParBase library in CbmRuntimeDb class. It fails when trying to access variable 'contFactories' (static TList) in function 'addContFactory'.

I can't find the reason why when I load this library under ROOT session all works perfectly.

So, if anybody has any suggestion how to make it work (if is it actually possible?), I would be very grateful.

Regards,
Konstantin
  • Attachment: Makefile
    (Size: 1.42KB, Downloaded 708 times)
  • Attachment: test.C
    (Size: 4.66KB, Downloaded 739 times)


Konstantin
Re: CINT -> g++ [message #4528 is a reply to message #4519] Thu, 21 June 2007 14:17 Go to previous messageGo to next message
Konstantin Antipin is currently offline  Konstantin Antipin
Messages: 3
Registered: May 2007
Location: Frankfurt
occasional visitor

From: *ikf.physik.uni-frankfurt.de
Hi all!

Due to Denis Bertini the problem is solved now.
The trouble was in the proper order of the loading library.
It is working now with the following order:
(-lSts -lGen -lRich -lTrd -lTof -lMvd -lGlobal -lKF -lDilept -lMuch -lBase -lField -lMCStack -lPassive -lGeoBase -lParBase)

Regards,
Konstantin


Konstantin
Why? [message #4540 is a reply to message #4519] Fri, 22 June 2007 19:37 Go to previous messageGo to next message
Volker Friese is currently offline  Volker Friese
Messages: 365
Registered: April 2004
Location: GSI CBM
first-grade participant
From: *gsi.de
Nice to note it's working now, but is there an explanantion why the order of the linked libraries in the compile command matters at all?
Re: Why? [message #4541 is a reply to message #4540] Fri, 22 June 2007 19:51 Go to previous message
Konstantin Antipin is currently offline  Konstantin Antipin
Messages: 3
Registered: May 2007
Location: Frankfurt
occasional visitor

From: *ikf.physik.uni-frankfurt.de
Well, the problem probably is occurs due to the following:
There are some dependencies between this libraries. And when I am loading libraries not in the proper order - some of the static member are not initialized. And when on loading library constructor of this library is executed, segmentation error appears.
This is only guess - but it seems to be the true.


Konstantin
Previous Topic: files on /u/cbmgast1
Next Topic: Error on running much_sim.C
Goto Forum:
  


Current Time: Fri Oct 04 20:10:00 CEST 2024

Total time taken to generate the page: 0.00692 seconds