Compiling error.

297 views
Skip to first unread message

Gilberto Montiel

unread,
Mar 2, 2021, 10:24:22 PM3/2/21
to Nek5000
Hello!
I'm just starting with nek5000 and I followed the instructions in the Quickstart: "Running your very first simulation".

First issue I had was with the command:
cd ~/Nek5000/tools; ./maketools genmap

Then I installed gfortran (I'm on Ubuntu 16.04) with the shell command:
sudo apt-get install gfortran

After that, I can continue, but then when I pass the command
makenek eddy_uv
I get the answer:
using source path: /home/hp/Nek5000
generating makefile ... done
building 3rd-party dependencies ...
An ERROR occured, see build.log for details

When I open build.log, the reported error is:
In file included from src/sarray_transfer.c:9:0:
src/comm.h:67:10: fatal error: mpi.h: No such file or directory
 #include <mpi.h>

          ^~~~~~~

Do you have any suggestion? I appreciate a lot your time and attention.


Gilberto Montiel.

Fischer, Paul

unread,
Mar 2, 2021, 11:23:46 PM3/2/21
to Gilberto Montiel, Nek5000

Dear Gilberto,

Have you installed mpi (either openmpi or mpich) ?

Paul Fischer


From: nek...@googlegroups.com <nek...@googlegroups.com> on behalf of Gilberto Montiel <jose.gil...@gmail.com>
Sent: Tuesday, March 2, 2021 9:24 PM
To: Nek5000 <nek...@googlegroups.com>
Subject: [nek5000] Compiling error.
 
--
You received this message because you are subscribed to the Google Groups "Nek5000" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nek5000+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nek5000/837b2b20-d75a-4bd9-9b08-b64b67f3510en%40googlegroups.com.

Gilberto Montiel

unread,
Mar 5, 2021, 10:05:24 PM3/5/21
to Nek5000
Hi, Paul! Sorry about the delay.

I tried to install open mpi manually but I've been struggling during the week, so I ended installing it with:

sudo apt-get install openmpi-bin openmpi-common openssh-client openssh-server libopenmpi1.10 libopenmpi-dbg libopenmpi-dev

Unfortunately,  I keep getting an error and an instruction to look at build.log, and again it shows:

In file included from src/sarray_transfer.c:9:0:
src/comm.h:67:10: fatal error: mpi.h: No such file or directory
 #include <mpi.h>
          ^~~~~~~


Do you recommend keep trying manual installation or remove open mpi and install mpich?
Any other idea?

Thanks a lot. Hope you are fine, best wishes.

Gilberto Montiel.

Gilberto Montiel

unread,
Mar 5, 2021, 10:10:27 PM3/5/21
to Nek5000
Hi Byron.

Thanks a los for your response; I’m still getting the same error although I installed open mpi. Do you suggest mpich? 

Best wishes,
Gilberto

You received this message because you are subscribed to a topic in the Google Groups "Nek5000" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/nek5000/LZkv0nh8av8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to nek5000+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nek5000/ce93478c-18d3-4aeb-880c-9980c5e5ec73n%40googlegroups.com.

Arsen Iskhakov

unread,
Mar 5, 2021, 10:15:04 PM3/5/21
to Gilberto Montiel, Nek5000
I also encountered this error today compiling Nek5000 on NCSU Henry 2 machine. My solution was to try to use different compilers... If I remember correctly “pure” Openmpi and intel mpi did not work at all. Some sort of old versions of mixed openmpi/gcc compiler worked (I do not remember exactly the version and the name of the compiler). If you are interested - I will check it tomorrow when I get my laptop...

Anyway, mpich should work (use stable version). If you have opportunity to install it, it should solve your problems.

Good luck!

--
Sincerely,

Arsen Iskhakov, PhD                     isk...@ncsu.edu
PhD-student                             (984) 255-3069
Department of Nuclear Engineering       Campus Box 7909
North Carolina State University         Raleigh, NC 27695

Guillaume Chauvat

unread,
Mar 6, 2021, 4:12:36 AM3/6/21
to nek...@googlegroups.com
Hi Gilberto,

Sorry if I missed it, but did you use the MPI compiler in the makenek? Something like
FC="mpif77"
CC="mpicc"


Guillaume

Stefan K.

unread,
Mar 6, 2021, 5:09:54 AM3/6/21
to Guillaume Chauvat, Nek5000
This list is not intended to discuss general MPI questions/issues.
> To view this discussion on the web visit https://groups.google.com/d/msgid/nek5000/36f67ba7-4815-d944-6638-10c56249fc0c%40mech.kth.se.

Gilberto Montiel

unread,
Mar 8, 2021, 7:24:04 PM3/8/21
to Nek5000
Hi, Guillaume. Thanks a lot for your response.

I didn't indicate those at the beggining, but now that I've done it, I get another error:

gcc: error: unrecognized command line option ‘-fno-plt’

I'm trying to solve this, meanwhile, do you have any thoughts?

Best,
Gilberto

Gilberto Montiel

unread,
Mar 8, 2021, 7:28:42 PM3/8/21
to Nek5000
Hi, Arsen.

Thanks a lot for your response; I’ll try that.
Best wishes!

Gilberto.

You received this message because you are subscribed to a topic in the Google Groups "Nek5000" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/nek5000/LZkv0nh8av8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to nek5000+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nek5000/f56f759f-e9e2-44ab-bde8-8faa25cc54ccn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages