Problem with dynamic libraries with ROOT 5.34 and ubuntu 14

Hello all,

I am having some trouble with the dynamic libraries. I successfully installed ROOT 5.34 in SO Ubuntu 14.04. I tried the example in root.cern.ch/drupal/content/how- … -libraries

In my $ROOTSYS/test directory I compiled by doing,

$ make Event,

this produced the shared library libEvent.so and executable Event. I then generated 200 events saved in the Event.root file by doing

$ ./Event 200

Then I tried to run the macros eventa.cxx by doing,

$ .L eventload.cxx
$ .L eventa.cxx

and I get the following error message,

Warning in TClass::TClass: no dictionary for class Event is available
Warning in TClass::TClass: no dictionary for class EventHeader is available
Warning in TClass::TClass: no dictionary for class Track is available
Error: Symbol Event is not defined in current scope eventa.cxx:28:
Error: Symbol Event is not defined in current scope eventa.cxx:28:
Error: type Event not defined FILE:/home/aperez/root/test/./eventa.cxx LINE:28
Warning: Automatic variable Eventevent is allocated eventa.cxx:28:
Error: Undeclared variable Event
event eventa.cxx:28:
*** Interpreter error recovered ***

It seems that the system doesn’t recognize the ligEvent.so shared libraries.

Does anyone have an idea of what is going on?

Many thanks,

Alejandro

.x eventload.cxx
.x eventa.cxx

Ciao Wile,

When I do,

.x eventload.cxx
.x eventa.cxx

it works. Thank you. But I am still curious why whe I do,
.L eventload.cxx
.L eventa.cxx

it doesn’t work? I am asking because I am trying to use some other code which compiles and links ROOT libreries to define new libreries which are a set of tools (clases) to be used later. The code compiles OK, but when I try to load the libraries root don’t recognize the new clases. I obtain a quite similar error to the one in my first post. Do you have any suggestion on how to sircunvent this problem?

Many thanks,

Alejandro

See:

  1. root [0] .?
  2. ROOT User’s Guide -> CINT the C++ Interpreter
  3. ROOT User’s Guide -> Adding a Class
  4. grep -r rootcint ${ROOTSYS}/test