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

Use GNU autoconf or cmake for build configuration #1013

Closed
uweseimet opened this issue Dec 1, 2022 · 3 comments
Closed

Use GNU autoconf or cmake for build configuration #1013

uweseimet opened this issue Dec 1, 2022 · 3 comments

Comments

@uweseimet
Copy link
Contributor

uweseimet commented Dec 1, 2022

On a Raspberry Pi files that are specific to the BananaPi platform are compiled, and vice versa.
By using GNU autoconf it should be possible to create a platform-specific Makefile. Benefits:

  • The make process only compiles files relevant for the target platform (Banana/Raspberry Pi)
  • Shorter compilation times as a result
  • The GNU compiler version check in the Makefile can removed. Currently it works more or less by accident, because it checks a g++ version number and does not consider that clang++ version numbers are different.

There may be other benefits.

@akuker
Copy link
Member

akuker commented Dec 1, 2022

I'm in favor of coming up with a different build system/approach.

But, I don't agree with segregating Banana/Raspberry pi functionality into different executables. IMHO, the code isn't that big for the differences, especially when/if we add different variants of Banana Pi. One of the more requested thing from users is to have pre-built executables, since it does take a long time to compile. I'd like to ultimately combine the different board types (Standard/Fullspec/Aibom/Gamernium) into a single executable as well.

Now that we're "really" using C++ (one could argue the original code was more like C than C++), I think we should also look at CMake. I think it could also provide some of these benefits.

@uweseimet
Copy link
Contributor Author

uweseimet commented Dec 1, 2022

I agree that cmake is an alternative. The current build mechanism may not be sufficient anymore, or at least not in the future, that's the main point I want to make.
Regarding pre-built binaries IMO the most user-friendly approach is a package solution as proposed in #740.

@uweseimet uweseimet changed the title Use GNU autoconf for build configuration Use GNU autoconf or cmake for build configuration Dec 2, 2022
@uweseimet
Copy link
Contributor Author

Closing my ticket, because over time the build process has become less dynamic and less platform dependent, e.g. by making use of portable C++ functionality. There is also no need anymore for a compiler check in the Makefile.
Thus all in all using anything but a regular Makefile would make the build process more complicated without providing a benefit.

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

2 participants