@matheusbsbs / matheus-bagliano / commits / f188e33e8a
Fork 0

Makefile: dependencies for vcs-svn tests

The vcs-svn tests (test-treap.o et al) depend on the vcs-svn headers for declarations and inline functions. Declare the dependency. While at it, declare a dependency of the vcs-svn objects (vcs-svn/string_pool.o et al) on $(LIB_H) to reflect use within the vcs-svn library of git-compat-util.h and cache.h. Without this change, tweaks to inline functions in those headers do not provoke rebuilds of the corresponding tests[*], making such changes unnecessarily difficult to test. Before: $ touch vcs-svn/*.h && make test-treap $ After: $ touch vcs-svn/*.h && make test-treap CC test-treap.o LINK test-treap $ [*] unless COMPUTE_HEADER_DEPENDENCIES is enabled Detected with "make CHECK_HEADER_DEPENDENCIES=1". Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jonathan Nieder committed Oct 10, 2010 at 00:50 UTC f188e33e8a4112ce26cee94f5533f5459e62879f
1 file changed +5 -1
Makefile
+5 -1
@@ -1823,6 +1823,8 @@ XDIFF_OBJS = xdiff/xdiffi.o xdiff/xprepare.o xdiff/xutils.o xdiff/xemit.o \
1823 xdiff/xmerge.o xdiff/xpatience.o
1824 VCSSVN_OBJS = vcs-svn/string_pool.o vcs-svn/line_buffer.o \
1825 vcs-svn/repo_tree.o vcs-svn/fast_export.o vcs-svn/svndump.o
1826 +VCSSVN_TEST_OBJS = test-obj-pool.o test-string-pool.o \
1827 + test-line-buffer.o test-treap.o
1828 OBJECTS := $(GIT_OBJS) $(XDIFF_OBJS) $(VCSSVN_OBJS)
1829
1830 dep_files := $(foreach f,$(OBJECTS),$(dir $f).depend/$(notdir $f).d)
@@ -1946,10 +1948,12 @@ xdiff-interface.o $(XDIFF_OBJS): \
1948 xdiff/xinclude.h xdiff/xmacros.h xdiff/xdiff.h xdiff/xtypes.h \
1949 xdiff/xutils.h xdiff/xprepare.h xdiff/xdiffi.h xdiff/xemit.h
1950
1949 -$(VCSSVN_OBJS): \
1951 +$(VCSSVN_OBJS) $(VCSSVN_TEST_OBJS): $(LIB_H) \
1952 vcs-svn/obj_pool.h vcs-svn/trp.h vcs-svn/string_pool.h \
1953 vcs-svn/line_buffer.h vcs-svn/repo_tree.h vcs-svn/fast_export.h \
1954 vcs-svn/svndump.h
1955 +
1956 +test-svn-fe.o: vcs-svn/svndump.h
1957 endif
1958
1959 exec_cmd.s exec_cmd.o: EXTRA_CPPFLAGS = \