"debug" and "optimized" cannot be a uppercase in TARGET_LINK_LIBRARIES
There are error when use MSBuild:
TARGET_LINK_LIBRARIES(
MyProject
DEBUG lib-d-a
)
error message:
LINK : fatal error LNK1104: cannot open files 'DEBUG.lib'
My build command:
cmake -G "Visual Studio 15 2017" -A x64 -DCMAKE_BUILD_TYPE=Debug ../../src
MSBuild.exe MyProject.sln /property:Configuration=Debug /property:Platform=x64
But if I modify DEBUG to lowercase(debug), then it can be build successfully.