Extracting used compiler flags
Functionality to add/problem to solve
When compiling third-party applications that are to be used together with OpenFOAM it is reasonable to use the same compiler flags as wmake
does. To provide a concrete example, I want to compile Google Test using wmake
flags. Sourceflux provides a tutorial on that, see refs, where they use a pretty simple python script to extract the compiler flags. The script doesn't work with OpenFOAM-plus, however, because the flags are spread across multiple files and imported using includes in the rule-file.
Target audience
Developers looking to compile third-party applications with the same compiler flags as OpenFOAM
Proposal
There is a $WM_CXXFLAGS variable defined, but it doesn't contain the warning flags. I could not find a variable containing all the flags. Perhaps, such a variable could be created?
What does success look like, and how can we measure that?
An easy way to obtain all the compiler flags.