gfortran related error when compiling LAMMPS

Dear Lammps-Users,

I encountered the following error when attempting to compile LAMMPS with REAX, on a CentOS 6.4 machine with OpenMPI, compiling the REAX library did not seem to have any issues:

/usr/bin/ld: warning: Cannot create .eh_frame_hdr section, --eh-frame-hdr ignored.
/usr/bin/ld: error in /usr/bin/gfortran(.eh_frame); no .eh_frame_hdr table will be created.
size …/lmp_linux
text data bss dec hex filename
8782380 12312 1612293952 1621088644 609fd984 …/lmp_linux
make[1]: Leaving directory `/opt/lammps-14Aug13/src/Obj_linux’

May I know how do I resolve this error? I have attached the makefiles for further reference.

Best Regards,
Jingjie Yeo
Ph.D. Student
School of Mechanical and Aerospace Engineering
Nanyang Technological University, Singapore

Makefile.lammps.gfortran (152 Bytes)

Makefile.linux (2.65 KB)

Dear Lammps-Users,

I encountered the following error when attempting to compile LAMMPS with
REAX, on a CentOS 6.4 machine with OpenMPI, compiling the REAX library did
not seem to have any issues:

/usr/bin/ld: warning: Cannot create .eh_frame_hdr section, --eh-frame-hdr
ignored.
/usr/bin/ld: error in /usr/bin/gfortran(.eh_frame); no .eh_frame_hdr table
will be created.
size ../lmp_linux
   text data bss dec hex filename
8782380 12312 1612293952 1621088644 609fd984 ../lmp_linux
make[1]: Leaving directory `/opt/lammps-14Aug13/src/Obj_linux'

May I know how do I resolve this error? I have attached the makefiles for
further reference.

this is a low-level compiler or machine installation issue and not a
LAMMPS issue.
i would suspect that somehow somewhere, inconsistently compiled object
files are combined.
but it is impossible to tell this from remote and without knowing the
machine itself.

axel.

on top of that. USER-REAXC supersedes REAX, so there is no real need
to include this in the first place.

axel.

Dear Dr. Kohlmeyer,

That is indeed a better solution, thank you very much! Compiles properly now.

Best Regards,
Jingjie Yeo
Ph.D. Student
School of Mechanical and Aerospace Engineering
Nanyang Technological University, Singapore