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

LIBDEPS library ordering instability can drive spurious rebuilds of mongod and mongos

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Build
    • None
    • ALL
    • Hide

      With a clean 'build' directory, and with the enterprise repo enabled, build mongod (don't use --mute):

      > scons ./mongod

      At the end, have a look at the libraries on the link line:
      -ldl -lgsasl -lnetsnmpagent -lnetsnmpmibs -lnetsnmp -lgsasl -lssl -lcrypto

      Rebuild the target. This should be a no-op, but if you do it enough times, it will get rebuilt. Note the libraries on the link line:

      -lnetsnmpagent -lnetsnmpmibs -lnetsnmp -lgsasl -ldl -lgsasl -lssl -lcrypto

      They are different, forcing a rebuild

      Show
      With a clean 'build' directory, and with the enterprise repo enabled, build mongod (don't use --mute): > scons ./mongod At the end, have a look at the libraries on the link line: -ldl -lgsasl -lnetsnmpagent -lnetsnmpmibs -lnetsnmp -lgsasl -lssl -lcrypto Rebuild the target. This should be a no-op, but if you do it enough times, it will get rebuilt. Note the libraries on the link line: -lnetsnmpagent -lnetsnmpmibs -lnetsnmp -lgsasl -ldl -lgsasl -lssl -lcrypto They are different, forcing a rebuild

      The mongod and mongos targets are occasionally rebuilt even when no changes have been made, because the ordering of libraries on the link line is not consistent. SCons sees the library ordering difference as requiring a rebuild.

            Assignee:
            jonathan.reams@mongodb.com Jonathan Reams
            Reporter:
            andrew.morrow@mongodb.com Andrew Morrow (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: