summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2013-02-27 17:59:19 (GMT)
committerJunio C Hamano <gitster@pobox.com>2013-02-27 17:59:19 (GMT)
commitc054ef9be2dd1ea722130628b2feb46d0ac88f6d (patch)
tree831f1ef6a294c5840cc1db4c8987ea610d5dd2b0 /Makefile
parent31e54bb94a8acb0fa4fa5099bc455ea8355db621 (diff)
parent7f1b69763272f9d07e612309f53190da0c97ca70 (diff)
downloadgit-c054ef9be2dd1ea722130628b2feb46d0ac88f6d.zip
git-c054ef9be2dd1ea722130628b2feb46d0ac88f6d.tar.gz
git-c054ef9be2dd1ea722130628b2feb46d0ac88f6d.tar.bz2
Merge branch 'jn/less-reconfigure' into maint
* jn/less-reconfigure: Makefile: avoid infinite loop on configure.ac change
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile14
1 files changed, 8 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 4bb3cf1..ec58d5c 100644
--- a/Makefile
+++ b/Makefile
@@ -2272,12 +2272,14 @@ $(patsubst %.py,%,$(SCRIPT_PYTHON)): % : unimplemented.sh
mv $@+ $@
endif # NO_PYTHON
+CONFIGURE_RECIPE = $(RM) configure configure.ac+ && \
+ sed -e 's/@@GIT_VERSION@@/$(GIT_VERSION)/g' \
+ configure.ac >configure.ac+ && \
+ autoconf -o configure configure.ac+ && \
+ $(RM) configure.ac+
+
configure: configure.ac GIT-VERSION-FILE
- $(QUIET_GEN)$(RM) $@ $<+ && \
- sed -e 's/@@GIT_VERSION@@/$(GIT_VERSION)/g' \
- $< > $<+ && \
- autoconf -o $@ $<+ && \
- $(RM) $<+
+ $(QUIET_GEN)$(CONFIGURE_RECIPE)
ifdef AUTOCONFIGURED
# We avoid depending on 'configure' here, because it gets rebuilt
@@ -2286,7 +2288,7 @@ ifdef AUTOCONFIGURED
# do want to recheck when the platform/environment detection logic
# changes, hence this depends on configure.ac.
config.status: configure.ac
- $(QUIET_GEN)$(MAKE) configure && \
+ $(QUIET_GEN)$(CONFIGURE_RECIPE) && \
if test -f config.status; then \
./config.status --recheck; \
else \