Closed didzis-berenis closed 5 months ago
Hi Didzis,
I am not sure about the flag. Please explain in more detail what would be the right solution.
Juris
On Wed, Apr 3, 2024, 08:48 didzis-berenis @.***> wrote:
- Header fvCFD.H is no longer defined in OF11. The bare minimum to compile EOF-Library is to include fvMesh.H instead.
- OF11 uses c++14 standard, so the flag -std=gnu++0x cannot be used. I did not specify here that c++14 standard is required though. Should I add -std=gnu++1y in the if statement for OF11?
You can view, comment on, or merge this pull request online at:
https://github.com/jvencels/EOF-Library/pull/12 Commit Summary
- bd678e9 https://github.com/jvencels/EOF-Library/pull/12/commits/bd678e92cf5a8d62503ee258dac96dfe8b4a11e8 Added OpenFOAM-11 compatibility
File Changes
(2 files https://github.com/jvencels/EOF-Library/pull/12/files)
- M libs/coupleElmer/Elmer.H https://github.com/jvencels/EOF-Library/pull/12/files#diff-ac40fc98b7a9f2d6e1093fd15ddc008506c10542633771b4af27c2a471a4ef28 (8)
- M libs/coupleElmer/Make/options https://github.com/jvencels/EOF-Library/pull/12/files#diff-827f882c2f7663780422acfba32a14ab8022535e562c3f48a63023072bb3c391 (7)
Patch Links:
- https://github.com/jvencels/EOF-Library/pull/12.patch
- https://github.com/jvencels/EOF-Library/pull/12.diff
— Reply to this email directly, view it on GitHub https://github.com/jvencels/EOF-Library/pull/12, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABHP7QILS4J3UDRCJ6PGOTDY3OJ2RAVCNFSM6AAAAABFUTV5JSVHI2DSMVQWIX3LMV43ASLTON2WKOZSGIZDCOJVGM4DGMQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>
It's just that OF11 doesn't compile with the flag -std=gnu++0x that is currently in the compile options. The current option corresponds to c++11, but the OF11 needs c++14. Also, turns out my proposed -std=gnu++1y flag is deprecated See here so -std=gnu++14 should be used instead.
I find that for me omitting this flag altogether and letting the compiler decide works fine. I think in the most common case the user will be installing OF11, which uses c++14, so EOF-Library should also compile fine.
So I propose in case of OF11: either 1) omit c++11 flag (current commit) or 2) add -std=gnu++14 flag to compiler and explicitly demand c++14
1) Header fvCFD.H is no longer defined in OF11. The bare minimum to compile EOF-Library is to include fvMesh.H instead. 2) OF11 uses c++14 standard, so the flag -std=gnu++0x cannot be used. I did not specify here that c++14 standard is required though. Should I add -std=gnu++1y in the if statement for OF11?