Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation issue #99

Open
SeiDPierre opened this issue Aug 30, 2023 · 4 comments
Open

Compilation issue #99

SeiDPierre opened this issue Aug 30, 2023 · 4 comments

Comments

@SeiDPierre
Copy link

SeiDPierre commented Aug 30, 2023

Hi everyone,
I have trouble compiling ParMmg on my computer. Before compiling, both Metis and Mmg were already installed.
I followed the instructions you provided but got some issues:
The first error message I got was : metis.h could not be found. Though I previously set the path with the command:
cmake -DDOWNLOAD_METIS=OFF -DMETIS_DIR=/home/pclouzet/local ..
So I manually edited the file here:
CMakeFiles/libparmmg_a.dir/flags.make and added a -I/home/pclouzet/local which solved the error message.

The second error message I got was : mmg3d.h could not be found. In deed I don't have such file in mmg directory but have libmmg3d.h. So I though it was a typo and modified
#include "mmg3d.h" to #include "libmmg3d.h" in the file ParMmg/src/parmmg.h
However that last step lead to a lot of warning messages ending with error of compilation.

This last error message (see attached file) is very generic and dont provide any hint on what went wrong so I'm sharing this with the community!

My setup:
cmake version 3.22.1
gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
mmg 5.7.0
metis latest version

Attached are the warning messages I got
compilation.log

Please do tell if you need any other information!
Thanks in advance
Pierre

@lcirrottola
Copy link
Contributor

For whoever will continue to debug it: we checked together that compilation with -DDOWNLOAD_MMG=OFF still works with the old Mmg release https://github.com/MmgTools/mmg/releases/tag/v5.6.0 on Parmmg 2abacd7 (latest master).
It could be worth investigating the changes in Mmg CMakeList.txt from v5.6.0 to v5.7.1.

Thanks,
Luca

@SeiDPierre
Copy link
Author

I tried with the downloading option and it failed too.
In ParMmg/src/parmmg.h the compiler complained that many functions were not declared:
MMG5_FMT_MeditASCII, MMG5_FMT_MeditBinary, MMG5_FMT_GmshASCII, MMG5_FMT_GmshBinary, MMG5_FMT_VtkPvtp, MMG5_FMT_VtkPvtu, MMG5_FMT_VtkVtu, MMG5_FMT_VtkVtp, MMG5_FMT_VtkVtk, MMG5_FMT_Tetgen and many other starting by MMG5_FMT.
In the current mmg version (5.7.1) they are present in libmmgtype.h. It's not the case when you the use the download option of ParMmg. To solve this, I added:
#include "mmgcommon.h" in parmmg.h
Finally, MMG5_idir is missing too, I added :
#include "mmg3d.h" in parmmg.h and ParMmmg successfully compiled.

@lcirrottola
Copy link
Contributor

Hello Pierre,
As a follow-up of our "offline" conversation, I write down here too that since the ParMmg-Mmg coupling goes quite further than just using the Mmg API, support of Mmg into ParMmg is guaranteed only for the Mmg commit used in the CMakeLists.txt here

GIT_TAG 889d408419b5c48833c249695987cf6ec699d399

which is now Mmg v5.6.0. Since Mmg v5.7.0 introduced some changes in header files, it is possible that some work will be needed to make ParMmg support it.
Please do not hesitate to post here any other problems in compiling with Mmg v5.6.0! I will probably open another post for the v5.7.0 support (or a pull request, when I will find some time to test).

Cheers,
Luca

@SeiDPierre
Copy link
Author

Hi Luca,
Thanks! I switched to 5.6.0 and it compiled just fine!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants