Build system doesn't notice source changes #3955

issue luke-jr opened this issue on March 25, 2014
  1. luke-jr commented at 3:16 AM on March 25, 2014: member

    To reproduce:

    • make src/bitcoind
    • touch src/checkpoints.cpp
    • make src/bitcoind # notice it doesn't rebuild anything
  2. laanwj added the label Build system on Mar 25, 2014
  3. rebroad commented at 11:49 PM on April 7, 2014: contributor

    #3989 - moving away from a recursive Makefile may be the solution to this.

  4. laanwj commented at 10:45 AM on April 8, 2014: member

    Just that you have a hammer (woohoo! non-recursive makefiles!) doesn't mean that everything is a nail.

    As this involves two files in the same directory it should be perfectly possible to get this right with the current build system.

  5. rebroad commented at 8:08 AM on May 2, 2014: contributor

    So.. what is the way forwards with this? If I can get a better idea I can at least know where I need to extend my knowledge for helping to find a solution. If it's not non-recursive Makefiles, then what is it?

  6. Diapolo commented at 8:11 AM on May 2, 2014: none

    Perhaps dumb, but why isn't a simple hash of a source file used and if that differs we trigger a clean and a normal make for example?

  7. laanwj commented at 9:17 AM on May 2, 2014: member

    I see I was wrong above: I didn't notice the src/ before the targets passed to make. This is building an executable in another directory.

    The following make rule is triggered: https://github.com/bitcoin/bitcoin/blob/master/Makefile.am#L56 Notice that there are no dependencies specified. If the executables exist at all, make will assume rule is satisfied. Specifying them as phony targets may be one solution here: https://www.gnu.org/software/make/manual/html_node/Phony-Targets.html .

  8. laanwj cross-referenced this on May 28, 2014 from issue Non-recursive make by theuni
  9. theuni referenced this in commit 77a055d049 on Jun 11, 2014
  10. theuni cross-referenced this on Jun 11, 2014 from issue build: Add a top-level forwarding target for src/* objects by theuni
  11. laanwj closed this on Jun 11, 2014

  12. wtogami referenced this in commit 406e6616b6 on Sep 19, 2014
  13. wtogami referenced this in commit 9f8b82a94f on Oct 2, 2014
  14. MathyV referenced this in commit 9d50a62197 on Nov 3, 2014
  15. wtogami referenced this in commit 9128bea913 on Nov 14, 2014
  16. wtogami referenced this in commit d3f90baedc on Dec 23, 2014
  17. reddink referenced this in commit 85faa5d4f6 on May 27, 2020
  18. bitcoin locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-05-19 06:55 UTC