ROOT Version: root_v6.20.04
Platform: Linux Mint 19.3 Tricia
Compiler: gcc 7.5.0
Hi everybody.
I’m trying to use Delphes and ExRootAnalysis along side with ROOT, but I’m having sobre issues compiling the macro.
I’ve installed both Delphes and ExRootAnalysis using MadGraph, and so their directories are inside the main MadGraph directory:
When I tried to compile the macro, I receveid a error messagem saying that the ROOT was not able to find the headers Delphes.h, ExRootTreeReader.h and SortableObject.h, so I added this three files to the include directory of ROOT (in my computer this directory is at the location “/opt/ParticlePhysics/ROOT/root-6.20.04/build/include”) and then I added the headers to my macro:
#include <DelphesClasses.h>
#include <ExRootTreeReader.h>
#include <SortableObject.h>
After this, ROOT stopped showing error massages about Delphes.h and ExRootTreeReader.h headers but it’s still not finding SortableObject.h:
coweh@TARDIS:~/Codes/Jets$ root -l jet.cpp'("jet.root")'
root [0]
Processing jet.cpp("jet.root")...
In file included from input_line_103:1:
In file included from /home/coweh/Codes/Jets/jet.cpp:9:
/opt/ParticlePhysics/ROOT/root-6.20.04/build/include/DelphesClasses.h:39:10: fatal error: 'classes/SortableObject.h' file not found
#include "classes/SortableObject.h"
I’ve attached my macro, but the begining of my code is this:
#include "TROOT.h"
#include "TChain.h"
#include "TFile.h"
#include "TH1F.h"
#include "TCanvas.h"
#include <iostream>
#include <fstream>
#include <DelphesClasses.h>
#include <ExRootTreeReader.h>
#include <SortableObject.h>
//------------------------------------------------------------------------------
void jet(const char *inputFile)
{
gSystem->Load("libDelphes.so");
// Create chain of root trees
TChain chain("Delphes");
chain.Add(inputFile);
// Create object of class ExRootTreeReader
ExRootTreeReader *treeReader = new ExRootTreeReader(&chain);
Long64_t numberOfEntries = treeReader->GetEntries();
Thank’s in advance
jet.cpp (2.1 KB)