Skip to content

Conversation

@VincentVanlaer
Copy link
Member

This PR reintroduces proper dynamic linking support for the new build system.

Remaining tasks:

  • Testing on darwin systems (see Unable to compile with USE_SHARED = YES on a modern Mac #846)
  • Ensure make install or similar commands work (useful for pymesa). The currently implementation uses rpath to allow the libraries to find each other. This will need to be fixed with chrpath or patchelf on install. Alternatively, pymesa would need to be changed to look for modules and libraries in the build folder, if there is no need otherwise to support a make install command.

This is the last main part of #662.

Originally, only the include directories were passed to forum and gyre,
disregarding any compile flags set by the forum and gyre makefiles.
Instead, set all compile flags used by mesa, but set the language
standard to Fortran 2018
@VincentVanlaer
Copy link
Member Author

@rhdtownsend I am currently forcing all compile flags for the normal MESA modules onto forum and gyre, as I need to propagate the linker and include flags. Once gyre and forum switch to pkg-config for their dependencies, I can remove that part. Alternatively, it would also be possible to patch build/Makefile in gyre & forum to not set FFLAGS unconditionally.

@VincentVanlaer VincentVanlaer mentioned this pull request Jan 1, 2026
2 tasks
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

Successfully merging this pull request may close these issues.

2 participants