LNK1104: cannot open file 'libboost_program_options-vc143-mt-s-x64-1_89.lib'
14:42 02 Nov 2025

Actually No files ending with "vc143-mt-s-x64-1_89.lib" exist in my Boost library, but still compiler tried to find 'libboost_program_options-vc143-mt-s-x64-1_89.lib'. I don't know why.

Here is the command line when I compiled Boost Library.↓

b2 toolset=msvc-14.3 address-model=64 variant=debug link=static threading=multi runtime-link=shared

CmakeLists↓

set(Boost_INCLUDE_DIR "E:/boost_1_89_0")
set(Boost_LIBRARY_DIR "E:/boost_1_89_0/stage/lib")
set(Boost_USE_STATIC_LIBS ON)
set(Boost_USE_STATIC_RUNTIME OFF)

find_package(Boost 1.89.0 REQUIRED COMPONENTS log thread filesystem date_time program_options)

target_link_libraries(project_name
PRIVATE 
         ${Boost_LIBRARIES}
)

CMakePresets.json↓

"cacheVariables": {
        "CMAKE_BUILD_TYPE": "Debug",
          "Boost_USE_STATIC_LIBS": "ON",
          "Boost_USE_STATIC_RUNTIME": "OFF",
          "Boost_USE_DEBUG_RUNTIME": "ON",
          "Boost_USE_MULTITHREADED": "ON",
          "Boost_USE_DEBUG_LIBS":"ON"
      }

No files with suffix "vc143-mt-s-x64-1_89.lib" in Additional Dependencies setting either. All are ending with "vc143-mt-gd-x64-1_89.lib".

Any idea about this problem?

c++ boost