Uploaded image for project: 'C++ Driver'
  1. C++ Driver
  2. CXX-92

Shared client compiler switch "--as-needed" giving compiler errors

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: None
    • Environment:
      Fedora 14 64 but
      git sha b2910bcc5e55ee7d29f83476db0fd1c577690b71

      switch "--as-needed" is leaving a lot of undefined references when building mongoclient.so. See log for details. Removing switch then everything links. Will attach patch momentarily....

      Here are some of the link error message, full log is attached.
      ./libmongotestfiles.a(cmdline.o): In function `mongo::CmdLine::addGlobalOptions(boost::program_options::options_description&, boost::program_options::options_description&)':
      /home/dhubler/temp/mongodb-src-r2.0.0/db/cmdline.cpp:47: undefined reference to `boost::program_options::options_description::add_options()'
      /home/dhubler/temp/mongodb-src-r2.0.0/db/cmdline.cpp:47: undefined reference to `boost::program_options::options_description_easy_init::operator()(char const*, char const*)'
      /home/dhubler/temp/mongodb-src-r2.0.0/db/cmdline.cpp:51: undefined reference to `boost::program_options::options_description::add_options()'
      /home/dhubler/temp/mongodb-src-r2.0.0/db/cmdline.cpp:51: undefined reference to `boost::program_options::options_description_easy_init::operator()(char const*, char const*)'
      /home/dhubler/temp/mongodb-src-r2.0.0/db/cmdline.cpp:52: undefined reference to `boost::program_options::options_description_easy_init::operator()(char const*, char const*)'
      /home/dhubler/temp/mongodb-src-r2.0.0/db/cmdline.cpp:53: undefined reference to `boost::program_options::options_description_easy_init::operator()(char const*,

            Assignee:
            andrew.morrow@mongodb.com Andrew Morrow (Inactive)
            Reporter:
            dhubler Douglas Hubler
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: