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

Manual Makefiles: Do we want them and how to maintain them? #36

Closed
milancurcic opened this issue Dec 22, 2019 · 4 comments
Closed

Manual Makefiles: Do we want them and how to maintain them? #36

milancurcic opened this issue Dec 22, 2019 · 4 comments

Comments

@milancurcic
Copy link
Member

Related to #2 and #7. Let's discuss here whether we should maintain manual Makefiles (besides CMake).

First some pros and cons to this.

Pros:

  • People who don't have CMake can still build the code with just make;
  • Comes built-in on most Linux systems;
  • Others?

Cons:

  • Need to be maintained and updated often. This is especially problematic with fast-moving and experimental APIs.
  • Others?

Second, how much is this desired by the community? Use this issue to speak up.

Overall I like the convenience of plain Makefiles, and I like being able to see exactly what they're doing. However, in presence of a working CMake setup, I'm not likely to use them so I don't care as much for it. I never ever use systems that don't have access to CMake.

Third, if we do want manual Makefiles, how to we develop and maintain them? Should every contributor be responsible for adding their code to the Makefile? Otherwise, would we need a volunteer Makefile maintainer?

@certik
Copy link
Member

certik commented Dec 22, 2019

I think the most important advantage of manual Makefiles is:

  • Explicitly shows how to build the project with all the compiler options pretty much spelled out explicitly. Thus providing a clean and clear instructions how to build the project --- i.e., how to copy the stdlib_*.f90 files into production codes and how to update the production code's build system to build those.

Regarding how to maintain it, that's easy: our CI will build both CMake and manual Makefiles. Contributors submit a PR. If they forgot to update the Makefiles, then the CI fails, so they will get alerted, and most contributors will know how to fix it up, if they add a new module or add a new test file. For anything more complicated, we help them.

Yes, I am very happy to volunteer as a Makefile maintainer, in addition to all the other things I already implicitly volunteered for: CMake maintainer, git maintainer (helping contributors with git), etc. So by keeping things simple, I hope we can have lots of people being able to maintain our infrastructure.

@certik
Copy link
Member

certik commented Dec 22, 2019

It seems the most common changes to the build system that occasional contributors have to do are:

  • adding a new module
  • adding a test (possibly with some test data files)

I think that's pretty much it. A change like adding a new dependency (say Lapack, or FFTW) would have to be handled by us anyway, as it requires changes to our CI, documentation, etc.

@certik certik mentioned this issue Dec 22, 2019
3 tasks
@gronki
Copy link

gronki commented Dec 23, 2019

Please have a look at my fortdep project. It can auto-generate dependencies and entire makefiles. If there are any issues i can fix/implement them in priority mode.

@certik
Copy link
Member

certik commented Dec 23, 2019

@gronki thanks! Here is the direct link: https://github.com/gronki/fortdep

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

No branches or pull requests

3 participants