Problems Linking lhapdf-5.9.1 on MG5 v2_3_2_2

Asked by Richard Ruiz

Dear Experts,

I am having trouble linking my LHAPDF library (5.9.1) to MG5 (v2_3_2_2) and cannot seem to find my problem (details below). Any suggestions on how to resolve my problem would be greatly appreciated. Using the default PDFs does work without any problem.

Best Wishes,
Richard

When executing
$ ./bin/generate_events -f

I obtain the following output:
... default output...
generate_events -f
Generating 50000 events with run name run_05
survey run_05
INFO: compile directory
INFO: Using LHAPDF v5.9.1 interface for PDFs
run_card missed argument lhe_version. Takes default: 3.0
run_card missed argument dynamical_scale_choice. Takes default: -1
compile Source Directory
Error detected in "generate_events -f"
write debug file ... (directory) ... /run_05_tag_1_debug.log
If you need help with this issue please contact us on https://answers.launchpad.net/madgraph5
MadGraph5Error : A compilation Error occurs when trying to compile /.../MG5_aMC_v2_3_2_2/.../Source.
 The compilation fails with the following output message:
     gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -c -o combine_events.o combine_events.f
     gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -o ../bin/internal/combine_events combine_events.o rw_events.o ranmar.o kin_functions.o open_file.o rw_routines.o alfas_functions.o setrun.o -L../lib/ -lmodel -lpdf -lLHAPDF -lstdc++
     ../lib//libLHAPDF.a(wrapNNPDF20grid.o): In function `master.0.nnpdfint20evolve_':
     wrapNNPDF20grid.f:(.text+0x59c): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf20cnrep_' defined in COMMON section in ../lib//libLHAPDF.a(wrapNNPDF20grid.o)
     ../lib//libLHAPDF.a(wrapNNPDF20qedgrid.o): In function `master.0.nnpdfint20qedevolve_':
     wrapNNPDF20qedgrid.f:(.text+0x59a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf20cnrep_' defined in COMMON section in ../lib//libLHAPDF.a(wrapNNPDF20grid.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_alphamz_':
     EVLNNPDF.f:(.text+0x3a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10beta_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_initevln2lha_':
     EVLNNPDF.f:(.text+0x15a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10eevln2lha_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_initpar2evln_':
     EVLNNPDF.f:(.text+0x603): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10ppar2evln_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_pdfevolxint_ns24_':
     EVLNNPDF.f:(.text+0x761): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10xevk_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_pdfevolxint_ns_':
     EVLNNPDF.f:(.text+0x90a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10xevk_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_pdfevolxint_sg_':
     EVLNNPDF.f:(.text+0xab6): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10xevk_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_andim_nlo_':
     EVLNNPDF.f:(.text+0x1d68): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10consts_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     EVLNNPDF.f:(.text+0x5feb): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10colfact_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
     ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_andim_lo_':
     EVLNNPDF.f:(.text+0x741d): additional relocation overflows omitted from the output
     collect2: error: ld returned 1 exit status
     make: *** [../bin/internal/combine_events] Error 1

 Please try to fix this compilations issue and retry.
 Help might be found at https://answers.launchpad.net/madgraph5.
 If you think that this is a bug, you can report this at https://bugs.launchpad.net/madgraph5
quit
INFO:

INFO:
------------------------------------------

Relevant information:
$ echo $LHAPDFSYS
~/Packages

$ which lhapdf-config
~/Packages/bin/lhapdf-config

$ ls -l lib/
lrwxrwxrwx. 1 rruiz rruiz 39 Oct 8 13:23 lib/libLHAPDF.a -> ~/Packages/lib/libLHAPDF.a
lrwxrwxrwx. 1 rruiz rruiz 44 Oct 7 10:26 PDFsets -> ~/Packages/share/lhapdf/PDFsets

In my bash_profile file, I have also the line
 export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$LHAPDFSYS/lib

Question information

Language:
English Edit question
Status:
Solved
For:
MadGraph5_aMC@NLO Edit question
Assignee:
No assignee Edit question
Solved by:
Richard Ruiz
Solved:
Last query:
Last reply:
Revision history for this message
Olivier Mattelaer (olivier-mattelaer) said :
#1

Hi Richard,

My guess is that the pdf are not compiled with the same compiler as the one that you use for MG5.
I’ll be back on Monday, we can look at that together if you want to.

Olivier

On 08 Oct 2015, at 14:32, Richard Ruiz <email address hidden> wrote:

> New question #272198 on MadGraph5_aMC@NLO:
> https://answers.launchpad.net/mg5amcnlo/+question/272198
>
> Dear Experts,
>
> I am having trouble linking my LHAPDF library (5.9.1) to MG5 (v2_3_2_2) and cannot seem to find my problem (details below). Any suggestions on how to resolve my problem would be greatly appreciated. Using the default PDFs does work without any problem.
>
> Best Wishes,
> Richard
>
>
> When executing
> $ ./bin/generate_events -f
>
> I obtain the following output:
> ... default output...
> generate_events -f
> Generating 50000 events with run name run_05
> survey run_05
> INFO: compile directory
> INFO: Using LHAPDF v5.9.1 interface for PDFs
> run_card missed argument lhe_version. Takes default: 3.0
> run_card missed argument dynamical_scale_choice. Takes default: -1
> compile Source Directory
> Error detected in "generate_events -f"
> write debug file ... (directory) ... /run_05_tag_1_debug.log
> If you need help with this issue please contact us on https://answers.launchpad.net/madgraph5
> MadGraph5Error : A compilation Error occurs when trying to compile /.../MG5_aMC_v2_3_2_2/.../Source.
> The compilation fails with the following output message:
> gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -c -o combine_events.o combine_events.f
> gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -o ../bin/internal/combine_events combine_events.o rw_events.o ranmar.o kin_functions.o open_file.o rw_routines.o alfas_functions.o setrun.o -L../lib/ -lmodel -lpdf -lLHAPDF -lstdc++
> ../lib//libLHAPDF.a(wrapNNPDF20grid.o): In function `master.0.nnpdfint20evolve_':
> wrapNNPDF20grid.f:(.text+0x59c): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf20cnrep_' defined in COMMON section in ../lib//libLHAPDF.a(wrapNNPDF20grid.o)
> ../lib//libLHAPDF.a(wrapNNPDF20qedgrid.o): In function `master.0.nnpdfint20qedevolve_':
> wrapNNPDF20qedgrid.f:(.text+0x59a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf20cnrep_' defined in COMMON section in ../lib//libLHAPDF.a(wrapNNPDF20grid.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_alphamz_':
> EVLNNPDF.f:(.text+0x3a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10beta_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_initevln2lha_':
> EVLNNPDF.f:(.text+0x15a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10eevln2lha_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_initpar2evln_':
> EVLNNPDF.f:(.text+0x603): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10ppar2evln_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_pdfevolxint_ns24_':
> EVLNNPDF.f:(.text+0x761): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10xevk_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_pdfevolxint_ns_':
> EVLNNPDF.f:(.text+0x90a): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10xevk_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_pdfevolxint_sg_':
> EVLNNPDF.f:(.text+0xab6): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10xevk_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_andim_nlo_':
> EVLNNPDF.f:(.text+0x1d68): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10consts_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> EVLNNPDF.f:(.text+0x5feb): relocation truncated to fit: R_X86_64_PC32 against symbol `nnpdf10colfact_' defined in COMMON section in ../lib//libLHAPDF.a(EVLNNPDF.o)
> ../lib//libLHAPDF.a(EVLNNPDF.o): In function `lh_andim_lo_':
> EVLNNPDF.f:(.text+0x741d): additional relocation overflows omitted from the output
> collect2: error: ld returned 1 exit status
> make: *** [../bin/internal/combine_events] Error 1
>
> Please try to fix this compilations issue and retry.
> Help might be found at https://answers.launchpad.net/madgraph5.
> If you think that this is a bug, you can report this at https://bugs.launchpad.net/madgraph5
> quit
> INFO:
>
> INFO:
> ------------------------------------------
>
> Relevant information:
> $ echo $LHAPDFSYS
> ~/Packages
>
> $ which lhapdf-config
> ~/Packages/bin/lhapdf-config
>
> $ ls -l lib/
> lrwxrwxrwx. 1 rruiz rruiz 39 Oct 8 13:23 lib/libLHAPDF.a -> ~/Packages/lib/libLHAPDF.a
> lrwxrwxrwx. 1 rruiz rruiz 44 Oct 7 10:26 PDFsets -> ~/Packages/share/lhapdf/PDFsets
>
> In my bash_profile file, I have also the line
> export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$LHAPDFSYS/lib
>
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Revision history for this message
Zhuoni (sdalyqian) said :
#2

Hi Richard, Olivier,

Was the issue resolved after reconfiguring LHAPDF?

I am having the same issue on Mac (el capitan), while default pdf don't have a problem. I have home-brew installed gcc-4.9.3, MG5-2.3.3 and LHAPDF-6.1.5. I can't seem to resolve this by reconfiguring LHAPDF?

Best,
Zhuoni

Revision history for this message
Richard Ruiz (rruiz) said :
#3

Recompiling the LHAPDF libraries solved my problem.

best,
richard

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

Otherwise

For LHAPDF 6.1.5, the compilation is also working nicely with the built-in clang.
So you do not need to install gcc at all actually.

Cheers,

Olivier

> On Jan 23, 2016, at 05:02, Zhuoni <email address hidden> wrote:
>
> Question #272198 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/272198
>
> Zhuoni requested more information:
> Hi Richard, Olivier,
>
> Was the issue resolved after reconfiguring LHAPDF?
>
> I am having the same issue on Mac (el capitan), while default pdf don't
> have a problem. I have home-brew installed gcc-4.9.3, MG5-2.3.3 and
> LHAPDF-6.1.5. I can't seem to resolve this by reconfiguring LHAPDF?
>
> Best,
> Zhuoni
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Revision history for this message
Zhuoni (sdalyqian) said :
#5

Hi,
I solved this by reinstalling lhapdf and compile it with my default gcc/gfortran on the machine.

My guess is that the homebrew installed version of lhapdf was somehow picking up a different compiler, even though I defined my default gcc/gfortran in the login ".bash_profile" file.
Anyway it's working now.

Best, Zhuoni