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

Refactor build logic to lib/Makefile #110

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

nbren12
Copy link
Contributor

@nbren12 nbren12 commented Aug 11, 2020

This commit refactors some pure fortran routines from templates/_wrapper.pyx to lib/tracers.f90. These routines will be used in a future PR to add getters/setters for the physics tracers data.

Since this required modifying the build system, I took the opportunity to refactor that a bit. The responsibility of building/linking code was split between the setup.py and lib/Makefile, and there was a fair amount of complexity associated with handling the linking arguments for the fortran model outputs.

Now, the lib/Makefile builds a single static library lib/libcoupler.a that combines all of static fortran objects. The setup.py for the wrapper then adds the link arguments -Llib -lcoupler. I also restructured the logic of setup.py into a few functions.

the responsibility of building/linking code was split between the setup.py
and lib/Makefile. This commit combines all the fortran static objects
into a single libcoupler.a archive, which simplifies the setup.py.
This archive is built by lib/Makefile
It was too hard to combine .a files into a single archive. The linker does this.
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.

1 participant