0

In qt creator (version 3.6.1 based on qt 5.6.0), when I try to add an extern static library using add library -> external library -> choose the lib file, linkage: static, it adds the following codes to the .pro-file:

win32: LIBS += -L$$PWD/../libs/ -lmylib

INCLUDEPATH += $$PWD/../libs
DEPENDPATH += $$PWD/../libs

but I don't seem to need both of them (either LIBS or INCLUDEPATH). So my question is, what is the difference. Is one of them better and if yes, why? What I can thinking of is, when using INCLUDEPATH, you only have to this once so you don't have to add each library separately with LIBS += if many libraries are used?

yangsunny
  • 656
  • 5
  • 13
  • 32
  • Better in what sence? All these do different things. – lisyarus Apr 17 '16 at 17:39
  • I just want to add a static library mylib.lib to the project to use the functions which are contains in the .lib-file, thats all. What are they doing exactly, when u say the do different things? – yangsunny Apr 17 '16 at 17:43

0 Answers0