Following the installation instructions (inside
x64 Native Tools Command Prompt for VS22) :
This worked fine:
cd examples/basic_example
cmake -S . -B build -DCMAKE_PREFIX_PATH=../..
but then
cmake --build build -v
starts to compile and then the linking errors begin:
absl_flags_parse.lib(parse.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in basic_example.obj [C:\temp\or-tools_x64_Vi
sualStudio2022_cpp_v9.12.4544\or-tools_x64_VisualStudio2022_cpp_v9.12.4544\examples\basic_example\build\basic_example.vcxproj]
absl_flags_parse.lib(parse.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MDd_DynamicDebug' in basic_example.obj
[C:\temp\or-tools_x64_VisualStudio2022_cpp_v9.12.4544\or-tools_x64_VisualStudio2022_cpp_v9.12.4544\examples\basic_example\build\basic_example.vcxproj]
absl_flags_usage.lib(usage.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in basic_example.obj [C:\temp\or-tools_x64_Vi
sualStudio2022_cpp_v9.12.4544\or-tools_x64_VisualStudio2022_cpp_v9.12.4544\examples\basic_example\build\basic_example.vcxproj]
any idea what is going on ?
I tried it on 2 computers running windows 11.
by the way - the readme.md file begins with an alternative of using
make run SOURCE=examples/basic_example/basic_example.cc
but windows does not have 'make'. using 'nmake' produces a syntax error with this file.