We are trying to integrate Crashpad with our Qt application and have run into several errors. We built Crashpad and attempted to link it to our application using the following snippet from the .pro
file:
# Crashpad rules for Windows
win32 {
LIBS += -L$$PWD/Crashpad/Libraries/Windows/ -lbase
LIBS += -L$$PWD/Crashpad/Libraries/Windows/ -lclient
LIBS += -L$$PWD/Crashpad/Libraries/Windows/ -lutil
}
Upon building, we got a ton of linker errors similar to the following:
base.lib(base.file_path.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MDd_DynamicDebug' in main.obj
We saw this post and decided to build Crashpad using the /MDd
flag. After copying the new libraries into the directory listed above building with Qt yielded the following error:
fatal error C1007: unrecognized flag '-Ot' in 'p2'
Why is MSVC throwing this error? We are building using the 14.0 MSVC toolset.