Thanks Remi, But I already solved the problem. Effectively the link : " -Xlinker -bind_at_load -flat_namespace" was missing!! Now everything works fine. Thanks for all Pierre On Fri, 19 Sep 2003, Remi Mommsen wrote: > Hi Pierre, > > How do you compile this program? If I use > g++ -Wall -fPIC -g -c main.cxx `root-config --cflags` > g++ -g -Xlinker -bind_at_load -flat_namespace -o main main.o > `root-config --libs` > > and add the missing includes > #include "TApplication.h" > #include "TH1F.h" > > It works as expected. I use root 3.05.07 compiled from fink on Mac OS X > 10.2 > > Cheers, > Remi > > > On Friday, September 19, 2003, at 02:30 AM, Pierre Da Silva wrote: > > > Hello ROOTERS, > > > > I resent a mail because my problem is still not resolved. I > > have problems when I try to run my program under MacOSX with ROOT > > version 3.05.05. I can reproduce the problem with this very simplified > > program: > > > > int main (int argc, char *argv[]) > > { > > TApplication theApp ("App", NULL, 0); > > TH1F *histo; > > double xp[151]; > > for(int j=0; j<100; j++) xp[j] =3D j+56; > > for(int j=0; j<51; j ++) xp[100+j] = 100+3*j+56; > > histo = new TH1F("myhisto","histo",50,0,1000); > > for(int j=0; j<151; j++) histo->Fill(xp[j]); > > histo->Draw(); > > > > theApp.Run (); > > return 0; > > } > > > > When running this, the execution stops in the creation of the object > > TApplication, but the program doesn't crash, it is simply stucked, and > > nothing else is done (CPU: 0%). I still have the same problem even if I > > comment the TApplication, the program is stucked at : > > > > histo = new TH1F("myhisto","histo",50,0,1000). > > > > Can anyone help me? > > > > > > ############################### > > Pierre Da Silva > > Email: pdasilva@lpnhep.in2p3.fr > > Tel.: 01 44 27 62 74 > > > > LPNHE > > 4, place Jussieu > > Tour 33 - Rez de Chaussee > > 75252 PARIS Cedex 05 - FRANCE > > Tel.: 01 44 27 63 13 > > Fax: 01 44 27 46 38 > > ############################### > > > > > > > --------------------------------------------------------------------- > Q: How many kinds of physicists are there? > A: Three. Those who can count and those who can't. > > ********************************************************************* > Remigius K. Mommsen e-mail: mommsen@slac.stanford.edu > University of California, Irvine URL: http://cern.ch/mommsen > c/o SLAC voice: ++1 (650) 926-3595 > 2575 Sand Hill Road #35 fax: ++1 (650) 926-3882 > Menlo Park, CA 94025, US home: ++1 (650) 233-9041 > ********************************************************************* > -- ############################### Pierre Da Silva Email: pdasilva@lpnhep.in2p3.fr Tel.: 01 44 27 62 74 LPNHE 4, place Jussieu Tour 33 - Rez de Chaussee 75252 PARIS Cedex 05 - FRANCE Tel.: 01 44 27 63 13 Fax: 01 44 27 46 38 ###############################
This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:15 MET