Troubles installing ExRotAnalsys

Asked by Guglielmo Coloretti

Dear all,

I have already used and installed successfully madgaph several times. Now I changed laptop and while installing ExRootAnalysis, I receive some obscure errors.

MG5_aMC>install ExRootAnalysis
Downloading http://madgraph.phys.ucl.ac.be//Downloads/ExRootAnalysis/ExRootAnalysis_V1.1.2.tar.gz
--2022-10-10 19:17:53-- http://madgraph.phys.ucl.ac.be//Downloads/ExRootAnalysis/ExRootAnalysis_V1.1.2.tar.gz
Resolving madgraph.phys.ucl.ac.be (madgraph.phys.ucl.ac.be)... 130.104.1.243
Connecting to madgraph.phys.ucl.ac.be (madgraph.phys.ucl.ac.be)|130.104.1.243|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 124186 (121K) [application/x-gzip]
Saving to: ‘ExRootAnalysis.tgz’

ExRootAnalysis.tgz 100%[===================>] 121.28K --.-KB/s in 0.08s

2022-10-10 19:17:53 (1.42 MB/s) - ‘ExRootAnalysis.tgz’ saved [124186/124186]

compile ExRootAnalysis. This might take a while.
>> Generating tmp/src/ExRootAnalysisDict.cc
>> Compiling tmp/src/ExRootAnalysisDict.cc
>> Compiling src/ExRootFilter.cc
>> Compiling src/ExRootSTDHEPReader.cc
>> Compiling src/ExRootFactory.cc
>> Compiling src/ExRootTreeWriter.cc
>> Compiling src/ExRootResult.cc
>> Compiling src/ExRootStream.cc
>> Compiling src/ExRootClasses.cc
>> Compiling src/ExRootTreeBranch.cc
>> Compiling src/ExRootTreeReader.cc
>> Compiling src/ExRootProgressBar.cc
>> Compiling src/ExRootLHEFReader.cc
>> Compiling src/ExRootUtilities.cc
>> Building libExRootAnalysis.so
>> Copying ExRootAnalysisDict_rdict.pcm
>> Compiling test/ExRootLHEFConverter.cpp
>> Building ExRootLHEFConverter
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::SkipArray(unsigned int)':
ExRootSTDHEPReader.cc:(.text+0x159): undefined reference to `xdr_u_int'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::ReadFileHeader()':
ExRootSTDHEPReader.cc:(.text+0x1b8): undefined reference to `xdr_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x1e1): undefined reference to `xdr_string'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x269): undefined reference to `xdr_u_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x289): undefined reference to `xdr_u_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x29f): undefined reference to `xdr_u_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x32d): undefined reference to `xdr_u_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x34d): undefined reference to `xdr_u_int'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::SetInputFile(_IO_FILE*)':
ExRootSTDHEPReader.cc:(.text+0x3b5): undefined reference to `xdrstdio_create'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::ReadEventTable()':
ExRootSTDHEPReader.cc:(.text+0x3ec): undefined reference to `xdr_string'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::ReadEventHeader()':
ExRootSTDHEPReader.cc:(.text+0x50c): undefined reference to `xdr_string'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x56c): undefined reference to `xdr_u_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x5c2): undefined reference to `xdr_u_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x5e5): undefined reference to `xdr_u_int'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::ReadSTDCM1()':
ExRootSTDHEPReader.cc:(.text+0x686): undefined reference to `xdr_string'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::ReadSTDHEP()':
ExRootSTDHEPReader.cc:(.text+0x759): undefined reference to `xdr_string'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x766): undefined reference to `xdr_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x773): undefined reference to `xdr_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x797): undefined reference to `xdr_opaque'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::ReadSTDHEP4()':
ExRootSTDHEPReader.cc:(.text+0x896): undefined reference to `xdr_double'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x8a3): undefined reference to `xdr_double'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x8b0): undefined reference to `xdr_double'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x8bd): undefined reference to `xdr_u_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0x8df): undefined reference to `xdr_double'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::AnalyzeParticles(ExRootTreeBranch*)':
ExRootSTDHEPReader.cc:(.text+0xab9): undefined reference to `xdrmem_create'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xaea): undefined reference to `xdrmem_create'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xb1b): undefined reference to `xdrmem_create'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xb49): undefined reference to `xdrmem_create'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xb79): undefined reference to `xdrmem_create'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o:ExRootSTDHEPReader.cc:(.text+0xba5): more undefined references to `xdrmem_create' follow
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::AnalyzeParticles(ExRootTreeBranch*)':
ExRootSTDHEPReader.cc:(.text+0xc41): undefined reference to `xdr_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xc50): undefined reference to `xdr_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xc62): undefined reference to `xdr_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xc6f): undefined reference to `xdr_int'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xc7c): undefined reference to `xdr_int'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o:ExRootSTDHEPReader.cc:(.text+0xc89): more undefined references to `xdr_int' follow
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::AnalyzeParticles(ExRootTreeBranch*)':
ExRootSTDHEPReader.cc:(.text+0xc96): undefined reference to `xdr_double'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xca3): undefined reference to `xdr_double'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xcb0): undefined reference to `xdr_double'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xcc0): undefined reference to `xdr_double'
/usr/bin/ld: ExRootSTDHEPReader.cc:(.text+0xcd0): undefined reference to `xdr_double'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o:ExRootSTDHEPReader.cc:(.text+0xce0): more undefined references to `xdr_double' follow
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::ReadBlock(ExRootTreeBranch*)':
ExRootSTDHEPReader.cc:(.text+0xfc9): undefined reference to `xdr_int'
/usr/bin/ld: tmp/src/ExRootSTDHEPReader.o: in function `ExRootSTDHEPReader::SkipBytes(unsigned int)':
ExRootSTDHEPReader.cc:(.text+0x123): undefined reference to `xdr_opaque'
collect2: error: ld returned 1 exit status
make: *** [Makefile:258: ExRootLHEFConverter] Error 1
Error detected during the compilation. Please check the compilation error and run make manually.

I tried to look in the /usr/include/rpc folder and actually realized there were no types.h or xdr.h files.
I installed the tirpc package and move what found in /usr/include/tirpc/rpc in /usr/include/rpc.

Now both types.h and xdr.h files appears in the /usr/include/rpc folder and within the xdr.h file there are listed the types xdr_u_int and all the others the compiler is complaining about.

Have you ever faced the same problem?

Thanks!

Best regards,
Guglielmo Coloretti

Question information

Language:
English Edit question
Status:
Solved
For:
MadGraph5_aMC@NLO Edit question
Assignee:
Pavel Demin Edit question
Solved by:
Guglielmo Coloretti
Solved:
Last query:
Last reply:
Revision history for this message
Olivier Mattelaer (olivier-mattelaer) said :
#1

I have seen multiple report for such error.
I have assign the author of ExRootAnalysis to this bug. But I'm not sure that he will receive the notification.

Cheers,

Olivier

Revision history for this message
Guglielmo Coloretti (guglielmocoloretti) said :
#2

Dear Olivier,

As for my question, I have accidentally found the answer.

In the Makefile of ExRootAnalysis (located in ~/MG5_aMC_v3_4_1/ExRootAnalysis if installed via MG5), one has to replace the line

LIBS = $(ROOTLIBS) $(SYSLIBS)

with

 LIBS = $(ROOTLIBS) -ltirpc $(SYSLIBS)

and then manually run make on this Makefile.
With latest version of MG5 (3.4.1), ExRootAnalysis works perfectly.

Hope it helps!

Best,
Guglielmo

Revision history for this message
Guglielmo Coloretti (guglielmocoloretti) said :
#3
Revision history for this message
Yang Ma (mayangluon) said (last edit ):
#4

Hi Guglielmo,

I believe you were using a Makefile that is different from the one that people could download from the webpage, since it reads
`LIBS = $(ROOTLIBS) $(SYSLIBS)` in your Makefile but it is now `LIBS = $(ROOTLIBS) ` in the public one. I suppose you are using v1.1.5?

Just to add a comment, one could solve this problem by the following two changes for ExRootAnalysis v1.1.2
1. `CXXFLAGS += $(ROOTCFLAGS) -Wno-write-strings -D_FILE_OFFSET_BITS=64 -DDROP_CGAL -I. ` to `CXXFLAGS += $(ROOTCFLAGS) -Wno-write-strings -D_FILE_OFFSET_BITS=64 -DDROP_CGAL -I. -I/usr/include/tirpc`
2. `LIBS = $(ROOTLIBS)` to `LIBS = $(ROOTLIBS) -ltirpc`

Best,
Yang

Revision history for this message
Aviral (elf-legolas) said :
#5

Hello,

I am installing ExRootAnalysis on Ubuntu 22.04 with Madgraph version 3.5.1.

I am facing the same compilation error during installation. Have tried the changes in the makefile but when I install again after the changes, the make file reverts the changes.

Revision history for this message
Pavel Demin (pavel-demin) said :
#6

Please do not use ExRootAnalysis.

As far as I know, it currently has no useful functionality. The file formats it supports are no longer produced by MadGraph.

The solution to all these problems would be for MadGraph to simply stop installing ExRootAnalysis.

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) said :
#7

For StdHep format, I agree that the format is technically dead now.
For HepMC2 and (in the future) HepMC3, they are likely no need for exrootanalysis since alternative should exists.

Now ExRootLHEFConverter has interest for some users.
But I guess alternatives also exists (like https://github.com/danphan/lhe-to-root).

> The solution to all these problems would be for MadGraph to simply stop installing ExRootAnalysis.

Note that we do not install ExRootAnalysis by default. The use has to type "install exrootanalysis" to have it install.
So the user should have
1) hear about it.
2) think that it will help him.

Now, I could put exrootanalysis at the same level as the pythia-pgs package (deprecated warning + advise to do something else)
when the user tries to install it. To state that support for that package has ended --this is might understanding of your statement--.

I can also be more extreme and remove the tarball of exrootanalysis to prevent any further installation but this might be too extreme no?

Cheers,

Olivier

Revision history for this message
Pavel Demin (pavel-demin) said :
#8

> 1) hear about it.

It is actually displayed as one of the first three options when running the install command with no arguments:

MG5_aMC>install
syntax: install Delphes|MadAnalysis4|ExRootAnalysis|update|Golem95|QCDLoop|maddm|maddump|looptools|MadSTR|pythia8|zlib|boost|lhapdf6|lhapdf5|collier|hepmc|mg5amc_py8_interface|ninja|oneloop|MadAnalysis5

Sometimes when I get a question about ExRootAnalysis I ask why and how it will be used and no one has ever told me that they plan to use ExRootLHEFConverter.

I think that completely removing ExRootAnalysis from MadGraph will only help.