{"thread":{"id":"12454","subject":"Header files not mentioned in the makefile","startedAt":"2008-03-03T07:24:24Z","lastAt":"2008-03-03T19:22:55Z","messageCount":4,"participants":["Martin Koegler","Johannes Schindelin","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"70756","messageId":"20080303072424.GA25623@auto.tuwien.ac.at","threadId":"12454","inReplyTo":null,"subject":"Header files not mentioned in the makefile","fromName":"Martin Koegler","fromEmail":"mkoegler@auto.tuwien.ac.at","sentAt":"2008-03-03T07:24:24Z","receivedAt":"2008-03-03T07:24:24Z","isPatch":false,"sender":{"key":"mkoegler@auto.tuwien.ac.at","avatar":null},"body":"When I modified fetch-pack.h I was surprised by the fact, that it does\nnot result in rebuilding all object files. In fact, no file was\nrebuilt. It turned out, that fetch-pack.h was not mentioned in the\nMakefile.\n\nA quick search (on next) showed, that other header files are also not\ntaking part in dependency checking:\n\n$for a in `ls *.h`; do grep \"$a\" Makefile >/dev/null || (echo \"missing: $a\"; grep \"$a\" *.c|grep include) ; done\nmissing: branch.h\n  branch.c:#include \"branch.h\"\n  builtin-branch.c:#include \"branch.h\"\n  builtin-checkout.c:#include \"branch.h\"\n  builtin-reset.c:#include \"branch.h\"\nmissing: bundle.h\n  builtin-bundle.c:#include \"bundle.h\"\n  bundle.c:#include \"bundle.h\"\n  transport.c:#include \"bundle.h\"\nmissing: color.h\n  builtin-branch.c:#include \"color.h\"\n  builtin-commit.c:#include \"color.h\"\n  builtin-config.c:#include \"color.h\"\n  builtin-diff.c:#include \"color.h\"\n  builtin-log.c:#include \"color.h\"\n  color.c:#include \"color.h\"\n  diff.c:#include \"color.h\"\n  wt-status.c:#include \"color.h\"\nmissing: exec_cmd.h\n  builtin-add.c:#include \"exec_cmd.h\"\n  builtin-archive.c:#include \"exec_cmd.h\"\n  builtin-cat-file.c:#include \"exec_cmd.h\"\n  builtin-describe.c:#include \"exec_cmd.h\"\n  builtin-fetch-pack.c:#include \"exec_cmd.h\"\n  builtin-init-db.c:#include \"exec_cmd.h\"\n  builtin-revert.c:#include \"exec_cmd.h\"\n  config.c:#include \"exec_cmd.h\"\n  daemon.c:#include \"exec_cmd.h\"\n  exec_cmd.c:#include \"exec_cmd.h\"\n  git.c:#include \"exec_cmd.h\"\n  help.c:#include \"exec_cmd.h\"\n  http-push.c:#include \"exec_cmd.h\"\n  receive-pack.c:#include \"exec_cmd.h\"\n  run-command.c:#include \"exec_cmd.h\"\n  shell.c:#include \"exec_cmd.h\"\n  upload-pack.c:#include \"exec_cmd.h\"\nmissing: fetch-pack.h\n  builtin-fetch-pack.c:#include \"fetch-pack.h\"\n  transport.c:#include \"fetch-pack.h\"\nmissing: interpolate.h\n  builtin-merge-recursive.c:#include \"interpolate.h\"\n  daemon.c:#include \"interpolate.h\"\n  interpolate.c:#include \"interpolate.h\"\n  ll-merge.c:#include \"interpolate.h\"\nmissing: merge-recursive.h\n  builtin-checkout.c:#include \"merge-recursive.h\"\n  builtin-merge-recursive.c:#include \"merge-recursive.h\"\nmissing: reachable.h\n  builtin-prune.c:#include \"reachable.h\"\n  builtin-reflog.c:#include \"reachable.h\"\n  reachable.c:#include \"reachable.h\"\nmissing: send-pack.h\n  builtin-send-pack.c:#include \"send-pack.h\"\n  transport.c:#include \"send-pack.h\"\nmissing: shortlog.h\n  builtin-log.c:#include \"shortlog.h\"\n  builtin-shortlog.c:#include \"shortlog.h\"\nmissing: tar.h\n  archive-tar.c:#include \"tar.h\"\n  builtin-tar-tree.c:#include \"tar.h\"\nmissing: thread-utils.h\n  builtin-pack-objects.c:#include \"thread-utils.h\"\nmissing: walker.h\n  builtin-http-fetch.c:#include \"walker.h\"\n  http-walker.c:#include \"walker.h\"\n  transport.c:#include \"walker.h\"\n  walker.c:#include \"walker.h\"\nmissing: xdiff-interface.h\n  builtin-blame.c:#include \"xdiff-interface.h\"\n  builtin-merge-file.c:#include \"xdiff-interface.h\"\n  builtin-merge-recursive.c:#include \"xdiff-interface.h\"\n  builtin-rerere.c:#include \"xdiff-interface.h\"\n  combine-diff.c:#include \"xdiff-interface.h\"\n  diff.c:#include \"xdiff-interface.h\"\n  grep.c:#include \"xdiff-interface.h\"\n  ll-merge.c:#include \"xdiff-interface.h\"\n  merge-file.c:#include \"xdiff-interface.h\"\n  merge-tree.c:#include \"xdiff-interface.h\"\n  xdiff-interface.c:#include \"xdiff-interface.h\"\n\nAdding this header files to LIB_H should fix the problem.\n\nmfg Martin Kögler\n"},{"id":"70772","messageId":"alpine.LSU.1.00.0803031146310.22527@racer.site","threadId":"12454","inReplyTo":"20080303072424.GA25623@auto.tuwien.ac.at","subject":"Re: Header files not mentioned in the makefile","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2008-03-03T11:47:01Z","receivedAt":"2008-03-03T11:47:01Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Mon, 3 Mar 2008, Martin Koegler wrote:\n\n> When I modified fetch-pack.h I was surprised by the fact, that it does \n> not result in rebuilding all object files. In fact, no file was rebuilt. \n> It turned out, that fetch-pack.h was not mentioned in the Makefile.\n> \n> A quick search (on next) showed, that other header files are also not\n> taking part in dependency checking:\n> \n> $for a in `ls *.h`; do grep \"$a\" Makefile >/dev/null || (echo \"missing: $a\"; grep \"$a\" *.c|grep include) ; done\n> missing: branch.h\n\nSomehow I miss \"wt-status.h\" in your list.\n\nCiao,\nDscho\n"},{"id":"70825","messageId":"20080303185524.GA26790@auto.tuwien.ac.at","threadId":"12454","inReplyTo":"alpine.LSU.1.00.0803031146310.22527@racer.site","subject":"Re: Header files not mentioned in the makefile","fromName":"Martin Koegler","fromEmail":"mkoegler@auto.tuwien.ac.at","sentAt":"2008-03-03T18:55:24Z","receivedAt":"2008-03-03T18:55:24Z","isPatch":false,"sender":{"key":"mkoegler@auto.tuwien.ac.at","avatar":null},"body":"On Mon, Mar 03, 2008 at 11:47:01AM +0000, Johannes Schindelin wrote:\n> On Mon, 3 Mar 2008, Martin Koegler wrote:\n> \n> > When I modified fetch-pack.h I was surprised by the fact, that it does \n> > not result in rebuilding all object files. In fact, no file was rebuilt. \n> > It turned out, that fetch-pack.h was not mentioned in the Makefile.\n> > \n> > A quick search (on next) showed, that other header files are also not\n> > taking part in dependency checking:\n> > \n> > $for a in `ls *.h`; do grep \"$a\" Makefile >/dev/null || (echo \"missing: $a\"; grep \"$a\" *.c|grep include) ; done\n> > missing: branch.h\n> \n> Somehow I miss \"wt-status.h\" in your list.\n\nThere is a dependency for wt-status.h, so it does not show up in\nmy grep:\n builtin-revert.o wt-status.o: wt-status.h\n\nBut this is complete:\n$ grep wt-status.h *.c\nbuiltin-commit.c:#include \"wt-status.h\"\nbuiltin-revert.c:#include \"wt-status.h\"\nwt-status.c:#include \"wt-status.h\"\n\n\nmfg Martin Kögler\n"},{"id":"70830","messageId":"7vr6erhasw.fsf@gitster.siamese.dyndns.org","threadId":"12454","inReplyTo":"20080303185524.GA26790@auto.tuwien.ac.at","subject":"Re: Header files not mentioned in the makefile","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2008-03-03T19:22:55Z","receivedAt":"2008-03-03T19:22:55Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"mkoegler@auto.tuwien.ac.at (Martin Koegler) writes:\n\n> On Mon, Mar 03, 2008 at 11:47:01AM +0000, Johannes Schindelin wrote:\n>> On Mon, 3 Mar 2008, Martin Koegler wrote:\n>> \n>> > When I modified fetch-pack.h I was surprised by the fact, that it does \n>> > not result in rebuilding all object files. In fact, no file was rebuilt. \n>> > It turned out, that fetch-pack.h was not mentioned in the Makefile.\n>> > \n>> > A quick search (on next) showed, that other header files are also not\n>> > taking part in dependency checking:\n>> > \n>> > $for a in `ls *.h`; do grep \"$a\" Makefile >/dev/null || (echo \"missing: $a\"; grep \"$a\" *.c|grep include) ; done\n>> > missing: branch.h\n>> \n>> Somehow I miss \"wt-status.h\" in your list.\n>\n> There is a dependency for wt-status.h, so it does not show up in\n> my grep:\n>  builtin-revert.o wt-status.o: wt-status.h\n>\n> But this is complete:\n> $ grep wt-status.h *.c\n> builtin-commit.c:#include \"wt-status.h\"\n> builtin-revert.c:#include \"wt-status.h\"\n> wt-status.c:#include \"wt-status.h\"\n\nI've been meaning to do a Makefile clean-up.\n\n * Various lists (SCRIPT_SH, SCRIPT_PERL, PROGRAMS, LIB_H, ...).  Make\n   them into a sorted one-item-per-line of the form \"LIB_H += foo.h\".\n\n * Dependencies.  We probably should auto-maintain them (\"gcc -M\",\n   makedepend etc).\n\n * Removing libgit.a; it used to be that what we had was a collection of\n   independent programs that link various but not all object files, and it\n   was a very easy and low maintenance way to tell the linker \"grab\n   whatever you need from libgit.a\".  These days, however, we roll almost\n   everything into \"git\" as built-ins, and the private library outlived\n   its usefulness.  We can instead just link in *.o files to build \"git\"\n   directly.\n\nI'd probably do the first item from the above list, immediately after all\nthe 1.5.5 topics graduat to 'master' and v1.5.5-rc1 is tagged; at that\npoint, by definition, we will not have new topics on 'master' until the\nfinal.  This conversion should not be difficult nor disruptive from\ntechnical point of view, but it needs to be done at the right moment when\neverything is quiescent.\n\n\n"}]}