1

I compiled Qt 5.9.1 32bits for VS 2017 in static linking mode,commands I used can be found here.After installing Qt VS tools,i created a QtGUIapplication,and tried to compile it. I didn't modify the code,I did retarget the solution to Windows 10 SDK.

I get 141 errors (LNK2001 & LNK 2019) at compile time like this one:

Qt5Core.lib(qregularexpression.obj) : error LNK2019: symbole externe non résolu _pcre2_config_16 référencé dans la fonction "public: void __thiscall QRegularExpressionPrivate::getPatternInfo(void)" (?getPatternInfo@QRegularExpressionPrivate@@QAEXXZ)

The complete output (too large for stackoverflow) can be found here : https://pastebin.com/uYLJFU2V

Here is project structure : enter image description here

EDIT 08/14/2017 : adding qtharfbuzz.lib reduced errors number to 89

EinderJam
  • 417
  • 1
  • 6
  • 20
  • 1
    Read: [What is an undefined reference/unresolved external symbol error and how do I fix it?](https://stackoverflow.com/questions/12573816/what-is-an-undefined-reference-unresolved-external-symbol-error-and-how-do-i-fix) – Arnav Borborah Aug 13 '17 at 17:02
  • About suggested duplicate... Chances are this is a problem with either Visual Studio integration, or with Qt compilation. Linked duplicate doesn't cover either of these in any way. – hyde Aug 13 '17 at 17:09
  • Can you create a working dummy project from command line (simplest is to create a `main.cpp` which creates `QCoreApplication` instance, then use `qmake -project` to create a *.pro* file for building it). If that works, then try to add using `QReguclarExpression` to it. Also try the dummy project with pre-built Qt, to make sure the project itself is valid. – hyde Aug 13 '17 at 17:13
  • Project file... something banal like it needs QT += core or something else. – Alexander V Aug 13 '17 at 18:47
  • [Qt 5.4 static build produces “unresolved external symbol” link error in Visual Studio 2013](https://stackoverflow.com/questions/27759754/qt-5-4-static-build-produces-unresolved-external-symbol-link-error-in-visual-s) or just use QtCreator – Eligijus Pupeikis Aug 14 '17 at 07:57
  • adding `qtharfbuzz.lib` to my libraries reduced errors number to 89 (instead of 141) Thank you,we're in progress ! – EinderJam Aug 14 '17 at 12:26

0 Answers0