-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Added support ccache for speedup compilation on Linux #14173
Conversation
I did not measure CI build speed, I was interested in local build on computer. |
A complete rebuild takes 2m12s on my 2019 laptop. Do we really need to add complexity to this? |
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've already been using ccache for years (I have /usr/lib/ccache/bin/
in my $PATH), and I consider it essential. Waiting minutes at rebuilding each time you checkout a different branch is awful.
=> I support this.
Please add a build option to enable this. One might still want to compile without ccache every now and then, e.g. for benchmarking build speed.
Probably not. The cached build artifacts needs to be stored somewhere, you won't get this without modifying the CI stuff. |
What's the benefit of making changes to our Maybe we should just recommend |
Do you suggest entering -D parameter every time? I think most people will forget. |
This is just needed at "configure time", e.g. when invoking And if people do "forget" to use (BTW, I removed the linked issue, since that concerned CI, and this PR does not make necessary CI changes.) |
A simple Either way, we should have some doc explaining how one can compile minetest with ccache. |
(Nitpick: The C files aren't really relevant for performance. We have only one C file ( What I like about Anyways, if it's such a trivial shorthand I wouldn't mind; there is virtually no risk in merging that, though I'd be wary of a default of
Agreed. |
The option is still missing. |
@sfan5 more information:
https://ccache.dev/
https://en.wikipedia.org/wiki/Ccache