Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-48966

Ninja generator does not emit dependencies on template inputs

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.4.1, 4.7.0
    • Affects Version/s: None
    • Component/s: Build
    • Labels:
      None
    • Fully Compatible
    • ALL
    • v4.4
    • Hide

      Generate a ninja file, build libwiredtiger.so, then edit wiredtiger.in, and rebuild libwiredtiger.so. Ninja will report that the file is up to date, when in fact SCons should have been re-invoked to regenerate wiredtiger.h from wiredtiger.in.

      Show
      Generate a ninja file, build libwiredtiger.so , then edit wiredtiger.in , and rebuild libwiredtiger.so . Ninja will report that the file is up to date, when in fact SCons should have been re-invoked to regenerate wiredtiger.h from wiredtiger.in .
    • Dev Platform 2020-06-29

      The Ninja Generator has logic to fall back to SCons to produce generated sources that are produced via "template" like mechanisms that are available only to SCons, most notable SubstFile.

      The current ninja generator neglects to declare that these files depend on their inputs. As a result, if, say wiredtiger.h.in is itself updated, SCons will not be re-invoked by the generated Ninja file to produce an updated wiredtiger.h

      The fix is to include the source files as dependencies of the generated templates.

            Assignee:
            daniel.moody@mongodb.com Daniel Moody
            Reporter:
            andrew.morrow@mongodb.com Andrew Morrow (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: