************************* Makefile ROOTCFLAGS = $(shell root-config --cflags) ROOTLIBS = $(shell root-config --libs) -lNew ROOTGLIBS = $(shell root-config --glibs) CXXFLAGS = -O2 -fPIC -I$(ROOTSYS)/include -DCOMPILED_ROOT CC = gcc OPTIM= -O2 -fexpensive-optimizations -funroll-loops CXXFLAGS +=$(ROOTCFLAGS) LIBS = $(LIBM) $(ROOTLIBS) $(ROOTGLIBS) hprod: hprod.o $(CC) $(CXXFLAGS) -o hprod hprod.o $(LIBS) ********************* producer code. hprod.C #include #include #include #include #include #include #include #include #include #include #include using namespace std; int main() { TApplication app("app",0,0); TMapFile::SetMapAddress(0x4125c000); TMapFile* mfile = TMapFile::Create("hsimple.map","RECREATE", 100000, "Demo memory mapped file with histograms"); TH1F* hpx = new TH1F("hpx","This is the px distribution",100,-4,4); hpx->SetFillColor(48); mfile->Print(); Float_t px, py, pz; int ii = 0; while (1) { gRandom->Rannor(px,py); hpx->Fill(px); if (!(ii % 10)) { mfile->Update(); // updates all objects in shared memory if (!ii) mfile->ls(); // print contents of mapped file after } // first update ii++; gSystem->Sleep(100); } } ****************************** producer compilation went ok. g++ -O2 -fPIC -I/work/hallc/gzero/jianglai/ROOT/root/include -DCOMPILED_ROOT -D_REENTRANT -I/work/hallc/gzero/jianglai/ROOT/root/include -c -o hprod.o hprod.C gcc -O2 -fPIC -I/work/hallc/gzero/jianglai/ROOT/root/include -DCOMPILED_ROOT -D_REENTRANT -I/work/hallc/gzero/jianglai/ROOT/root/include -o hprod hprod.o -L/work/hallc/gzero/jianglai/ROOT/root/lib -lCore -lCint -lHist -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lpthread -lm -ldl -rdynamic -lNew -L/work/hallc/gzero/jianglai/ROOT/root/lib -lCore -lCint -lHist -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lGui -lpthread -lm -ldl -rdynamic ******************************* what I get from $ROOTSTS/lib libASImage.so libGpad.so libMinuit.so libThread.so libAfterImage.a libGraf.so libMySQL.so libTree.so libCint.so libGraf3d.so libNew.so libTreePlayer.so libCore.so libGui.so libPhysics.so libTreeViewer.so libEG.so libHbook.so libPostscript.so libVMC.so libFumili.so libHist.so libProof.so libX3d.so libGX11.so libHistPainter.so libProofGui.so libfreetype.a libGX11TTF.so libHtml.so libRGL.so libGeom.so libKrb5Auth.so libRLDAP.so libGeomPainter.so libMatrix.so libRint.so ***************************** Error messages Error in : no memory mapped file capability available Use rootn.exe or link application against "-lNew" Memory mapped file: hsimple.map Title: Demo memory mapped file with histograms Option: file closed ********** Error messages if I ran it in rootn.exe/cint Error in : only one instance of TApplication allowed Memory mapped file: hsimple.map Title: Demo memory mapped file with histograms Option: CREATE Mapped Memory region: 0x4125c000 - 0x41275000 (0.10 MB) Current breakval: 0x41264000 Object Class Size hpx TH1F 1024 *** Break *** segmentation violation Generating stack trace... BFD: Dwarf Error: Invalid or unhandled FORM value: 14. BFD: Dwarf Error: Invalid or unhandled FORM value: 14.