I am currently trying to run Crypto++ in my Qt Application. But it does not work. Hopefully somebody of you knows whats wrong, because I have not figured it out and I am on this for 3 days now.
To concentrate the problem, I have created a test app. Holding this code: http://pastebin.com/1XMARtds taken from http://programmingknowledgeblog.blogspot.de/2013/04/compiling-and-integrating-crypto-into.html
My .pro looks like this:
TEMPLATE = app
CONFIG += console
CONFIG -= app_bundle
CONFIG -= qt
SOURCES += main.cpp
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../Savor_V100/libraries/ -lcryptlib
else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../Savor_V100/libraries/ -lcryptlibd
else:unix: LIBS += -L$$PWD/../Savor_V100/libraries/ -lcryptlib
INCLUDEPATH += $$PWD/../Savor_V100/includes/cryptopp562
DEPENDPATH += $$PWD/../Savor_V100/includes/cryptopp562
I have compiled the library with MS Visual Studio 2012. When I use these settings: http://i.imgur.com/Nd9TEIA.png
I get a single 50mb-ish .lib file.
When I then try to build my application in Qt Creator (5.0.2) I get the following: http://i.imgur.com/RbCGQDU.png
A lot of:
cryptlib.lib(cryptlib.obj):-1: error: LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in main.obj
It also says: File not found: cryptlib.lib(cryptlib.obj)
If I put the .obj files in the same folder as the .lib file I get rid of the "file not found" errors. But nothing else changes.
Could somebody please explain what I am doing wrong ? The LNK2038 info on the website does not help me:(