CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Installation

[] Compiling v2006, mpicc -- broken

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree3Likes
  • 2 Post By fertinaz
  • 1 Post By aendres

LinkBack Thread Tools Search this Thread Display Modes
Old   July 3, 2020, 06:31
Cool Compiling v2006, mpicc -- broken
New Member
Join Date: Jan 2016
Posts: 3
Rep Power: 6
broccolibadger is on a distinguished road

Hopyfully this is the right place to ask such a question as a beginner.

I'm trying to compile the source code for v2006 and openmpi on a Ubuntu 20.04 machine, getting this error:

Everything beforehand works just fine, it is this part just at the start of the OpenFOAM compiling process that a problem occurs.

Done ThirdParty Allwmake

Compile OpenFOAM libraries

    ln: OpenFOAM/lnInclude
    ln: OSspecific/POSIX/lnInclude


OpenFOAM/OpenFOAM-v2006/platforms/linux64GccDPInt32OptOPENMPI/lib \
    -L/home/henrik/OpenFOAM/ThirdParty-v2006/platforms/linux64Gcc/openmpi-4.0.3/lib64 -L/home/henrik/OpenFOAM/ThirdParty-v2006/platforms/linux64Gcc/openmpi-4.0.3/lib -lmpi  -o /home/henrik/OpenFOAM/OpenFOAM-v2006/platforms/linux64GccDPInt32Opt/lib/openmpi-4.0.3/
g++: error: /home/henrik/OpenFOAM/OpenFOAM-v2006/build/linux64GccDPInt32OptOPENMPI/src/Pstream/mpi/UOPwrite.o: No such file or directory
g++: error: /home/henrik/OpenFOAM/OpenFOAM-v2006/build/linux64GccDPInt32OptOPENMPI/src/Pstream/mpi/UIPread.o: No such file or directory
g++: error: /home/henrik/OpenFOAM/OpenFOAM-v2006/build/linux64GccDPInt32OptOPENMPI/src/Pstream/mpi/UPstream.o: No such file or directory
g++: error: /home/henrik/OpenFOAM/OpenFOAM-v2006/build/linux64GccDPInt32OptOPENMPI/src/Pstream/mpi/PstreamGlobals.o: No such file or directory
make: *** [/home/henrik/OpenFOAM/OpenFOAM-v2006/wmake/makefiles/general:184: /home/henrik/OpenFOAM/OpenFOAM-v2006/platforms/linux64GccDPInt32Opt/lib/openmpi-4.0.3/] Error 1
Any help or hint on how to proceed would make my day.

Some trouble regarding AIDOS compilation was alleviated by:
sudo apt install --reinstall #_mpi libraries here_#
perhaps it is related?

Compilation has previously worked fine for OF version 19.06, though since then the ubuntu distro has been upgraded.

broccolibadger is offline   Reply With Quote

Old   July 4, 2020, 14:48
Fatih Ertinaz
Join Date: Feb 2011
Location: Istanbul
Posts: 62
Rep Power: 11
fertinaz is on a distinguished road
Hello Henrik,

The problem is the objects under Pstream is not created properly which indicates an MPI related problem.

I recently compiled OF-2006, but I did by installing openmpi manually. New OF is shipped with openmpi-4.0.3, which I believe is not the version installed using the package manager. I assumed that's what you did.

So you got two options here:
  1. Manually install openmpi-4.0.3: You'll have to download and build it by yourself. If you're a beginner this may sound daunting, but I assure you it's not. One thing that you need to be careful with is updating the OS environment variables PATH and LD_LIBRARY_PATH. If you choose to do this, you don't need to change anything in the OF configuration files. But I guess you might have set "MPI_ARCH_PATH" to your MPI installation path.
  2. Use openmpi-4.0.3 that is shipped with ThirdParty: If you want OF to install openmpi for you, then you need to find the following line in the etc/bashrc:
    and change it to
    This is gonna (supposedly, haven't tried myself) find the openmpi-4.0.3 directory under the ThirdParty folder, and build openmpi from scratch. I don't think you need to change anything else if you follow this approach.

Hope this helps
broccolibadger and TonyZ like this.
fertinaz is offline   Reply With Quote

Old   July 5, 2020, 05:31
New Member
Join Date: Jan 2016
Posts: 3
Rep Power: 6
broccolibadger is on a distinguished road
Hi again, and thanks!

I solved the problem by compiling the MPI that comes in ThirdParty. Apparently compiling the package with the flag -k such as below is what's needed for the libraries to be built fully.

./Allwmake -k
broccolibadger is offline   Reply With Quote

Old   July 9, 2020, 11:35
New Member
Miguel Castellano
Join Date: Jun 2020
Posts: 4
Rep Power: 2
michu5696 is on a distinguished road
No that just skips the errors so compilation is not interrupted but you still have to build it again without -k option to make sure everything went fine.
michu5696 is offline   Reply With Quote

Old   July 14, 2020, 06:09
New Member
Aaron Endres
Join Date: Jun 2016
Posts: 6
Rep Power: 6
aendres is on a distinguished road
Hi Henrik,

I just had the same issue. In my case, it was caused by the -q flag for Allwmake, which is recommended in the build guide. When omitting the -q flag (just running ./Allwmake -j -s -l), the compilation even worked with the systems openmpi (WM_MPLIB=SYSTEMOPENMPI). This could explain why "./Allwmake -k" resolved the issue in your case.
TonyZ likes this.
aendres is offline   Reply With Quote


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
[] Cannot open configuration file mpicc-wrapper-data.txt mpicc: Not found wenjuny OpenFOAM Installation 0 November 25, 2019 09:01
OpenFOAM 1.6 ext fportela OpenFOAM Installation 11 December 26, 2013 18:55
mpirun fails achim OpenFOAM Installation 16 August 27, 2013 08:00
OpenFoam 1.6-ext - RPM build errors preibie OpenFOAM 12 September 8, 2011 03:12
Help with KIVA4 source code compiling geothokar Main CFD Forum 0 September 3, 2010 05:40

All times are GMT -4. The time now is 16:04.