Windows static build is broken in 1.5.0

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • 1.7.0
    • Affects Version/s: 1.5.0
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      As of libmongoc 1.5.0, attempting to link applications against the static build of the driver will fail with the error that symbols like "__imp_bson_iter_init" and "__imp_mongoc_read_prefs_new" cannot be resolved.

      Original description:

      Linking with bson-static-1.0.lib, mongoc-static-1.0.lib, libbsoncxx.lib, libmongocxx.lib worked in version 3.0.1 but fails with 3.1.0:

      1>libbsoncxx.lib(view.cpp.obj) : error LNK2001: unresolved external symbol __imp_bson_iter_init
      1>libbsoncxx.lib(core.obj) : error LNK2001: unresolved external symbol __imp_bson_iter_init
      1>libbsoncxx.lib(view.cpp.obj) : error LNK2001: unresolved external symbol __imp_bson_iter_init
      1>libbsoncxx.lib(view.cpp.obj) : error LNK2001: unresolved external symbol __imp_bson_iter_init_find
      1>libbsoncxx.lib(view.cpp.obj) : error LNK2001: unresolved external symbol __imp_bson_iter_init_find
      1>libbsoncxx.lib(view.cpp.obj) : error LNK2001: unresolved external symbol __imp_bson_iter_next
      etc, etc.
      

              Assignee:
              A. Jesse Jiryu Davis
              Reporter:
              Rustam Abdullaev
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: