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

Format Macros bug when building the server w/ static linking

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 6.0.0-rc3, 6.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Fully Compatible
    • ALL
    • v6.0
    • Dev Platform 2022-04-18, Dev Platform 2022-05-02

      I ran into an issue trying to build the server on my ubuntu1804-workstation with static linking.

      scons command:
      ./buildscripts/scons.py --ninja generate-ninja --modules= --variables-files=etc/scons/mongodbtoolchain_stable_gcc.vars --link-model=static --dbg=on --opt=off ICECC=icecc CCACHE=ccache

      then running ninja resulted in this error:
      [405/4643 ( 8%) 29.614s] Compiling build/debug/mongo/db/index/duplicate_key_tracker.o
      ICECC[8003] 17:14:29: flush_writebuf() failed Connection reset by peer
      ICECC[8003] 17:14:29: write of source chunk to host 10.122.1.92
      ICECC[8003] 17:14:29: failed Connection reset by peer
      ICECC[8003] 17:14:29: got exception Error 15 - write to host failed (10.122.1.92)
      [2100/4643 ( 45%) 981.709s] Compiling build/debug/mongo/db/s/balancer/balancer_commands_scheduler_impl.o
      ICECC[20521] 17:30:18: flush_writebuf() failed Connection reset by peer
      ICECC[20521] 17:30:18: write of source chunk to host 10.122.1.92
      ICECC[20521] 17:30:18: failed Connection reset by peer
      ICECC[20521] 17:30:18: got exception Error 15 - write to host failed (10.122.1.92)
      [3097/4643 ( 66%) 1581.883s] Compiling build/debug/mongo/s/transaction_router.o
      ICECC[27856] 17:40:16: flush_writebuf() failed Connection reset by peer
      ICECC[27856] 17:40:16: write of source chunk to host 10.122.1.92
      ICECC[27856] 17:40:16: failed Connection reset by peer
      ICECC[27856] 17:40:16: got exception Error 15 - write to host failed (10.122.1.92)
      [4220/4643 ( 90%) 1665.042s] Compiling build/debug/third_party/mozjs/platform/x86_64/linux/build/Unified_cpp_js_src14.o
      In file included from src/third_party/mozjs/platform/x86_64/linux/build/Unified_cpp_js_src14.cpp:29:
      src/third_party/mozjs/extract/js/src/vm/BytecodeUtil.cpp:13: warning: "__STDC_FORMAT_MACROS" redefined
      #define __STDC_FORMAT_MACROS

      <command-line>: note: this is the location of the previous definition
      [4643/4643 (100%) 1802.534s] Install build/debug/install/bin/mongod

      I fixed it by reverting this commit https://github.com/mongodb/mongo/commit/86da2a644b2a7bcb2ad6c0ea463e7ddc8ca6c6ac and then rebuilding.

            Assignee:
            ryan.egesdahl@mongodb.com Ryan Egesdahl (Inactive)
            Reporter:
            maddie.zechar@mongodb.com Maddie Zechar
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: