Message: problems adding TH1F histogram to the persistency example Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None problems adding TH1F histogram to the persistency example 

Forum: Persistency
Date: 27 Feb, 2007
From: <marco.serra@roma1.infn.it>

Hello,
I am trying to create a 1D histogram in the persistency example
(Geant-4.8.2 / root_v5.14.00b / clhep-2.0.3.1) adding a simple line

TH1F* h1 = new TH1F("hist1","CalHit",100,0,100.);

to the "readHits.cc" class.

But when I try to create an executable I have the error
 
: undefined reference to `TH1F::TH1F(char const*, char const*, int, double, double)'
collect2: ld returned 1 exit status
make: *** [dictionary] Error 1

I have added #include TH1F.h in readHits.cc but it does not help. 

Note that for example the creation of a new file via:
TFile* hf = new TFile("Histo.root", "RECREATE");
works fine. 

With older versions of the persistency example (up to Geant 4.8.0.p01) 
it was always possible to add histrograms, but now the example was 
rewritten (and the makefile changed a lot) and I am not able anymore 
to obtain plots.

Could someone help me?
thanks, regards Marco Serra 

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Ok: Re: problems adding TH1F histogram to the persistency example   (marco.serra@roma1.infn.it - 27 Feb, 2007)
 Add Message Add Message
to: "problems adding TH1F histogram to the persistency example"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]