Skip to content

Makefile: build optimized Git binary

Patrick Steinhardt requested to merge pks-build-optimized-git into master

The make git target can be used to build a custom Git version. While we currently only use this target for development work, we eventually want to use it to distribute a single Git version across GitLab components from a single location. But the version we're currently building is unfit for any production usecase, most importantly because compiler optimizations are turned off and developer checks are turned on. The result is an executable which is a lot slower compared to what we typically ship and use right now.

Remove both CFLAGS and DEVELOPER=1 from our Git build options to fix this, instead using the default -g -O2 -Wall CFLAGS provided by the project itself. Like this we still have debug symbols available to analyze what Git's been doing, but still have an optimized binary.

Merge request reports