in the lib directory are the two files located:
qmake generates the vcxproj file with
LIBS += halconcpp.lib
the reason for this is following bug in winmakefile.cpp:
int ver = findHighestVersion((*dep_it).local(), file);
this line is active for the -l option and also without the -l
the only two solutions to this are
- prepending the whole path for the lib (ignoring the QMAKE_LIBDIR)
- CONFIG += no_versionlink
no_versionlink is in no documentation mentioned. you'd have to find out by searching the code or visiting some "inside qmake" resource on the web.
what the docs have to say about this is:
Note: On Windows, specifying libraries with the -l option, as in the above example, will cause the library with the highest version number to be used; for example, libmath2.lib could potentially be used instead of libmathlib. To avoid this ambiguity, we recommend that you explicitly specify the library to be used by including the .lib file name suffix.
this is plain wrong as I stated above
see also https://bugreports.qt-project.org/browse/QTBUG-15596
- relates to
QTBUG-15596 Incorrect lib lookup