PDA

View Full Version : Qt Creator How to add "Additional Dependencies" (Linker settings)



tRs
8th December 2011, 13:04
Hello,

For my project I have a documentation for Visual Studio C++. I need external libraries and include folders:


Include Directories => In QtCreator I do it like this: INCLUDEPATH+=C:\\Folder\\Folder2\\IncludeFolder

Linker Settings => LIBS+=C:\\Folder\\Folder2\\LibFolder

Additional Dependencies (found in Visual Studio C++ under Linker Settings -> Input) => But how do I add these .lib files in QtCreator to act like in VS??


Thanks!

Added after 1 8 minutes:

Sorry, little misunderstanding.
I didn't know THIS (http://stackoverflow.com/questions/4066405/when-to-use-the-visual-studio-additional-dependencies) either.
So I think LIBS+=C:\\Folder\\Folder2\\LibFolder\\extlib.lib should do the job.

Oleg
8th December 2011, 18:04
Actually, do this way:


LIBS += -L"C:\\Folder\\Folder2\\LibFolder" -lextlib.lib

EDIT: This way works for both windows and linux, for win only you can simply do like you and docs suggest:


LIBS += "C:\\Folder\\Folder2\\LibFolder\\extlib.lib"
or
LIBS += $$quote(C:/mylibs/extra libs/extra.lib)