[PATCH 2/2] Makefile: add NO_GIT_SVN knob to skip building/installing git-svn
This option also implies that NO_SVN_TESTS is enabled.
Signed-off-by: Wesley Schwengle <wesleys@opperschaap.net>
---
Makefile | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/Makefile b/Makefile
index d4b775953d..e4b2f5fa0b 100644
--- a/Makefile
+++ b/Makefile
@@ -81,20 +81,23 @@ include shared.mak
#
# Define NO_SYS_SELECT_H if you don't have sys/select.h.
#
# Define NO_SYMLINK_HEAD if you never want .git/HEAD to be a symbolic link.
# Enable it on Windows. By default, symrefs are still used.
#
# Define NO_SVN_TESTS if you want to skip time-consuming SVN interoperability
# tests. These tests take up a significant amount of the total test time
# but are not needed unless you plan to talk to SVN repos.
#
+# Define NO_GIT_SVN if you don't want git-svn built or installed at all.
+# Implies NO_SVN_TESTS.
+#
# Define NO_FINK if you are building on Darwin/Mac OS X, have Fink
# installed in /sw, but don't want GIT to link against any libraries
# installed there. If defined you may specify your own (or Fink's)
# include directories and library directories by defining CFLAGS
# and LDFLAGS appropriately.
#
# Define NO_DARWIN_PORTS if you are building on Darwin/Mac OS X,
# have DarwinPorts (which is an old name for MacPorts) installed
# in /opt/local, but don't want GIT to
# link against any libraries installed there. If defined you may
@@ -741,21 +744,23 @@ SCRIPT_SH += git-web--browse.sh
SCRIPT_LIB += git-mergetool--lib
SCRIPT_LIB += git-sh-i18n
SCRIPT_LIB += git-sh-setup
SCRIPT_PERL += git-archimport.perl
SCRIPT_PERL += git-cvsexportcommit.perl
SCRIPT_PERL += git-cvsimport.perl
SCRIPT_PERL += git-cvsserver.perl
SCRIPT_PERL += git-send-email.perl
+ifndef NO_GIT_SVN
SCRIPT_PERL += git-svn.perl
+endif
SCRIPT_PYTHON += git-p4.py
# Generated files for scripts
SCRIPT_SH_GEN = $(patsubst %.sh,%,$(SCRIPT_SH))
SCRIPT_PERL_GEN = $(patsubst %.perl,%,$(SCRIPT_PERL))
SCRIPT_PYTHON_GEN = $(patsubst %.py,%,$(SCRIPT_PYTHON))
# Individual rules to allow e.g.
# "make -C ../.. SCRIPT_PERL=contrib/foo/bar.perl build-perl-script"
@@ -3408,20 +3413,23 @@ $(test_bindir_programs): bin-wrappers/%: bin-wrappers/wrap-for-bin.sh
-e 's|@GITPERLLIB@|$(shell pwd)/perl/build/lib|' \
-e 's|@MERGE_TOOLS_DIR@|$(shell pwd)/mergetools|' \
-e 's|@TEMPLATE_DIR@|$(shell pwd)/templates/blt|' \
-e 's|@PROG@|$(shell pwd)/$(patsubst test-%,t/helper/test-%,$(@F))$(if $(filter-out $(BINDIR_PROGRAMS_NO_X),$(@F)),$(X),)|' < $< > $@ && \
chmod +x $@
# GNU make supports exporting all variables by "export" without parameters.
# However, the environment gets quite big, and some programs have problems
# with that.
+ifdef NO_GIT_SVN
+NO_SVN_TESTS = YesPlease
+endif
export NO_SVN_TESTS
export TEST_NO_MALLOC_CHECK
### Testing rules
test: all
$(MAKE) -C t/ all
ifdef TEST_CONTRIB_TOO
$(MAKE) -C contrib/ test
endif
--
2.55.0.827.g48ce2c92dc