Makefile: add missing header file dependencies
LIB_H is missing exec_cmd.h and color.h. cache.h includes SHA1_HEADER, and thus so does almost everything else, so add that to LIB_H, too. xdiff-interface.h is not included by any header files, but so many source files use xdiff that it is simplest to include it in LIB_H, too. xdiff-interface.o uses the xdiff library heavily; let it depend on all xdiff headers to avoid needing to keep track of which headers it uses. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Jonathan Nieder committed
Jan 26, 2010 at 09:44 UTC
21528abc3612e3dae0c195b81848dd9aa18d2a02
1 file changed
+20
-3
Makefile
+20
-3
@@ -447,6 +447,7 @@ LIB_H += blob.h
447
LIB_H += builtin.h
448
LIB_H += cache.h
449
LIB_H += cache-tree.h
450
+LIB_H += color.h
451
LIB_H += commit.h
452
LIB_H += compat/bswap.h
453
LIB_H += compat/cygwin.h
@@ -457,6 +458,7 @@ LIB_H += delta.h
458
LIB_H += diffcore.h
459
LIB_H += diff.h
460
LIB_H += dir.h
461
+LIB_H += exec_cmd.h
462
LIB_H += fsck.h
463
LIB_H += git-compat-util.h
464
LIB_H += graph.h
@@ -499,6 +501,8 @@ LIB_H += unpack-trees.h
501
LIB_H += userdiff.h
502
LIB_H += utf8.h
503
LIB_H += wt-status.h
504
+LIB_H += xdiff-interface.h
505
+LIB_H += xdiff/xdiff.h
506
507
LIB_OBJS += abspath.o
508
LIB_OBJS += advice.o
@@ -1281,10 +1285,12 @@ endif
1285
ifdef BLK_SHA1
1286
SHA1_HEADER = "block-sha1/sha1.h"
1287
LIB_OBJS += block-sha1/sha1.o
1288
+ LIB_H += block-sha1/sha1.h
1289
else
1290
ifdef PPC_SHA1
1291
SHA1_HEADER = "ppc/sha1.h"
1292
LIB_OBJS += ppc/sha1.o ppc/sha1ppc.o
1293
+ LIB_H += ppc/sha1.h
1294
else
1295
SHA1_HEADER = <openssl/sha.h>
1296
EXTLIBS += $(LIB_4_CRYPTO)
@@ -1620,9 +1626,9 @@ git-imap-send$X: imap-send.o $(GITLIBS)
1626
$(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) \
1627
$(LIBS) $(OPENSSL_LINK) $(OPENSSL_LIBSSL)
1628
1623
-http.o http-walker.o http-push.o: http.h
1629
+http.o http-walker.o http-push.o remote-curl.o: http.h
1630
1625
-http.o http-walker.o: $(LIB_H)
1631
+http.o http-walker.o remote-curl.o: $(LIB_H)
1632
1633
git-http-fetch$X: revision.o http.o http-walker.o http-fetch.o $(GITLIBS)
1634
$(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) \
@@ -1637,14 +1643,25 @@ git-remote-curl$X: remote-curl.o http.o http-walker.o $(GITLIBS)
1643
1644
$(LIB_OBJS) $(BUILTIN_OBJS): $(LIB_H)
1645
$(patsubst git-%$X,%.o,$(PROGRAMS)) git.o: $(LIB_H) $(wildcard */*.h)
1646
+builtin-branch.o builtin-checkout.o builtin-clone.o builtin-reset.o branch.o: branch.h
1647
+builtin-bundle.o bundle.o transport.o: bundle.h
1648
+builtin-bisect--helper.o builtin-rev-list.o bisect.o: bisect.h
1649
+builtin-clone.o builtin-fetch-pack.o transport.o: fetch-pack.h
1650
+builtin-send-pack.o transport.o: send-pack.h
1651
+builtin-log.o builtin-shortlog.o: shortlog.h
1652
+builtin-prune.o builtin-reflog.o reachable.o: reachable.h
1653
builtin-revert.o wt-status.o: wt-status.h
1654
+builtin-tar-tree.o archive-tar.o: tar.h
1655
+builtin-pack-objects.o: thread-utils.h
1656
+http-fetch.o http-walker.o remote-curl.o transport.o walker.o: walker.h
1657
1658
$(LIB_FILE): $(LIB_OBJS)
1659
$(QUIET_AR)$(RM) $@ && $(AR) rcs $@ $(LIB_OBJS)
1660
1661
XDIFF_OBJS=xdiff/xdiffi.o xdiff/xprepare.o xdiff/xutils.o xdiff/xemit.o \
1662
xdiff/xmerge.o xdiff/xpatience.o
1647
-$(XDIFF_OBJS): xdiff/xinclude.h xdiff/xmacros.h xdiff/xdiff.h xdiff/xtypes.h \
1663
+xdiff-interface.o $(XDIFF_OBJS): \
1664
+ xdiff/xinclude.h xdiff/xmacros.h xdiff/xdiff.h xdiff/xtypes.h \
1665
xdiff/xutils.h xdiff/xprepare.h xdiff/xdiffi.h xdiff/xemit.h
1666
1667
$(XDIFF_LIB): $(XDIFF_OBJS)