Diff options
Diffstat (limited to 'source/cgit.mk')
| -rw-r--r-- | source/cgit.mk | 13 |
1 file changed, 10 insertions, 3 deletions
diff --git a/source/cgit.mk b/source/cgit.mk index 629c111..a62e4fd 100644 --- a/source/cgit.mk +++ b/source/cgit.mk @@ -5,19 +5,26 @@ # # make -C vendor/git -f ../../source/cgit.mk ../../build/cgit +CGIT_ROOT = ../.. + +# Read again here because a sub make inherits only the variables the top level +# Makefile exports, which leaves out the build options this file and Git's +# Makefile read. It comes ahead of Git's Makefile, which acts on an option such +# as NO_REGEX as soon as it reads it. +-include $(CGIT_ROOT)/cgit.conf + include Makefile # BUILDDIR is named relative to the project root because the version recipe # changes into the root before using it. CGIT_SRC and CGIT_BUILD lead to the # sources and the output from vendor/git, where everything else here runs. -CGIT_ROOT = ../.. SRCDIR = source BUILDDIR = build CGIT_SRC = $(CGIT_ROOT)/$(SRCDIR) CGIT_BUILD = $(CGIT_ROOT)/$(BUILDDIR) -# Read again here because a sub make inherits only the variables the top level -# Makefile exports, which leaves out the build options this file reads. +# And once more, since Git's Makefile and the lines above set CC, CFLAGS, +# BUILDDIR and the like over whatever was read before them. -include $(CGIT_ROOT)/cgit.conf # The CGIT_ values used below are exported by the top level Makefile. git |
