ExportXMLWordPrintableJSON

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Unknown
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Not Needed
    • None
    • C Drivers
    • None
    • None
    • None
    • None
    • None
    • None

      Summary

      libbson doesn't build under MS Visual Studio 2026

      Environment

      Version 2.5.7

      Windows 11 x64

      MSVC 19.52.37025.0

       

      [28/32] "C:\Program Files\Microsoft Visual Studio\18\Insiders\VC\Tools\MSVC\14.52.37025\bin\Hostx64\x64\cl.exe"   -DBSON_COMPILATION -DBSON_STATIC -DJSONSL_PARSE_NAN -DMCOMMON_NAME_PREFIX=_bson_mcommon -D_BSD_SOURCE -D_CRT_SECURE_NO_WARNINGS -D_DEFAULT_SOURCE -D_MLIB_BUILD_CONFIG=Debug -D_XOPEN_SOURCE=700 -IC:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src -IC:\Develop\vcpkg\buildtrees\libbson\x64-windows-static-md-dbg\src\libbson\src -IC:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\common\src -IC:\Develop\vcpkg\buildtrees\libbson\x64-windows-static-md-dbg\src\common\src /nologo /DWIN32 /D_WINDOWS /utf-8 /MP  /MDd /Z7 /Ob0 /Od /RTC1  -MDd -RTC1 /we4013 /we4431 /we4716 /we4113 /we4047 /we4090 /we4700 /D_CRT_SECURE_NO_WARNINGS /showIncludes /Fosrc\libbson\CMakeFiles\bson_static.dir\src\bson\validate.c.obj /Fdsrc\libbson\CMakeFiles\bson_static.dir\bson_static.pdb /FS -c C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c FAILED: [code=2] src/libbson/CMakeFiles/bson_static.dir/src/bson/validate.c.obj  "C:\Program Files\Microsoft Visual Studio\18\Insiders\VC\Tools\MSVC\14.52.37025\bin\Hostx64\x64\cl.exe"   -DBSON_COMPILATION -DBSON_STATIC -DJSONSL_PARSE_NAN -DMCOMMON_NAME_PREFIX=_bson_mcommon -D_BSD_SOURCE -D_CRT_SECURE_NO_WARNINGS -D_DEFAULT_SOURCE -D_MLIB_BUILD_CONFIG=Debug -D_XOPEN_SOURCE=700 -IC:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src -IC:\Develop\vcpkg\buildtrees\libbson\x64-windows-static-md-dbg\src\libbson\src -IC:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\common\src -IC:\Develop\vcpkg\buildtrees\libbson\x64-windows-static-md-dbg\src\common\src /nologo /DWIN32 /D_WINDOWS /utf-8 /MP  /MDd /Z7 /Ob0 /Od /RTC1  -MDd -RTC1 /we4013 /we4431 /we4716 /we4113 /we4047 /we4090 /we4700 /D_CRT_SECURE_NO_WARNINGS /showIncludes /Fosrc\libbson\CMakeFiles\bson_static.dir\src\bson\validate.c.obj /Fdsrc\libbson\CMakeFiles\bson_static.dir\bson_static.pdb /FS -c C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c(253): error C4047: 'function': 'bool' differs in levels of indirection from 'const char *const ' C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c(253): warning C4024: '_mlibCheckConditionSimple': different types for formal and actual parameter 1 C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c(254): error C4047: 'function': 'bool' differs in levels of indirection from 'const char *' C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c(254): warning C4024: '_mlibCheckConditionSimple': different types for formal and actual parameter 1 C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c(319): error C4047: 'function': 'bool' differs in levels of indirection from 'const char *const ' C:\Develop\vcpkg\buildtrees\libbson\src\2.5.7-c846f12862.clean\src\libbson\src\bson\validate.c(319): warning C4024: '_mlibCheckConditionSimple': different types for formal and actual parameter 1

       

      How to Reproduce

      Install MS Visual Studio 2026 and try to compile library using vcpkg

      vcpkg.exe install libbson:x64-windows-static-md

            Assignee:
            Colby Pike
            Reporter:
            Nikolay Shishov (EXT)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: