summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: beeb456)
raw | patch | inline | side by side (parent: beeb456)
author | Jonathan Nieder <jrnieder@gmail.com> | |
Tue, 26 Jan 2010 15:51:24 +0000 (09:51 -0600) | ||
committer | Jonathan Nieder <jrnieder@gmail.com> | |
Tue, 26 Jan 2010 16:08:55 +0000 (10:08 -0600) |
The git makefile never uses any default implicit rules.
Unfortunately, if a prerequisite for one of the intended rules is
missing, a default rule can be used in its place:
$ make var.s
CC var.s
$ rm var.c
$ make var.o
as -o var.o var.s
Avoiding the default rules avoids this hard-to-debug behavior.
It also should speed things up a little in the normal case.
Future patches may restrict the scope of the %.o: %.c pattern.
This patch would then ensure that for targets not listed, we do
not fall back to the default rule.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Unfortunately, if a prerequisite for one of the intended rules is
missing, a default rule can be used in its place:
$ make var.s
CC var.s
$ rm var.c
$ make var.o
as -o var.o var.s
Avoiding the default rules avoids this hard-to-debug behavior.
It also should speed things up a little in the normal case.
Future patches may restrict the scope of the %.o: %.c pattern.
This patch would then ensure that for targets not listed, we do
not fall back to the default rule.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Makefile | patch | blob | history |
diff --git a/Makefile b/Makefile
index 1811a9e74eaec83a83f2803f70a41e03e4d95786..8d3299a8f0ab388b8b1f23e180a65b411f7d6f39 100644 (file)
--- a/Makefile
+++ b/Makefile
XDIFF_OBJS = xdiff/xdiffi.o xdiff/xprepare.o xdiff/xutils.o xdiff/xemit.o \
xdiff/xmerge.o xdiff/xpatience.o
+.SUFFIXES:
+
%.o: %.c GIT-CFLAGS
$(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) $<
%.s: %.c GIT-CFLAGS FORCE