-
Notifications
You must be signed in to change notification settings - Fork 15
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
Fix CMake circular dependencies for external use #273
Conversation
@climbfuji said this worked for him. So I'll undraft. |
I hope this can make up so 11.5.3 version of the model - very important for GEOS-JEDI development. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for thes updates @mathomp4 . This works fine for us (JCSDA)!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand these changes very well, but if it works it works!
As found by @climbfuji, if you build GEOSgcm, you get three sets of CMake files for doing
find_package
: MAPL, GEOSgcm, and GOCART. This then causes circular dependencies as GOCART requires things "provided" by GEOSgcm and GEOSgcm requires GOCART.So this PR tries to "detect" if GOCART is being built as a standalone project or as part of GEOS.
ETA: In tests trying to build GOCART with MAPL-as-library-from-spack, it was found that you need to protect against the chance MAPL is found as a library. Then you can't add MAPL as a new subdirectory as targets will be duplicated.