Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library
-
Installed QT Creator 7.0.2 Windows 10 environment..
After installation, I created a project type Application(Qt) - Qt Widgets Application -Empty window. Build qmake.
After compiling, when running it shows the error below:
Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library.
I need help. Thanks. -
Installed QT Creator 7.0.2 Windows 10 environment..
After installation, I created a project type Application(Qt) - Qt Widgets Application -Empty window. Build qmake.
After compiling, when running it shows the error below:
Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library.
I need help. Thanks.@CidGianni
Hello and welcome.This has nothing to do with Creator, only your own program.
Show the relevant code (looks like you were calling some
qt_assert()
function maybe?) and what you link with.Have you installed Qt (never mind Creator) correctly? How did you do so?
Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library.
Is that the whole error message? Was it not followed by stating e.g. which dynamic library?
-
@CidGianni
Hello and welcome.This has nothing to do with Creator, only your own program.
Show the relevant code (looks like you were calling some
qt_assert()
function maybe?) and what you link with.Have you installed Qt (never mind Creator) correctly? How did you do so?
Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library.
Is that the whole error message? Was it not followed by stating e.g. which dynamic library?
@JonB Hi. first of all, thanks. Yesterday I downloaded the latest Open Source version (qt-unified-windows-x64-4.4.0-online.exe) for Windows 10 x64 and just installed it without changing any recommendations. After installed, I created the first project (only one window), compiled and executed. It's my first contact with QT.
-
@JonB Hi. first of all, thanks. Yesterday I downloaded the latest Open Source version (qt-unified-windows-x64-4.4.0-online.exe) for Windows 10 x64 and just installed it without changing any recommendations. After installed, I created the first project (only one window), compiled and executed. It's my first contact with QT.
@CidGianni
I cannot help further on this. Doubtless somebody else will soon/later.
However, you should state what kit you set up to use, e.g. MSVC (what version) or MinGW? -
@CidGianni said in Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library:
After compiling, when running it shows the error below:
Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library.After compiling, when linking. The program is never getting far enough to be executed. The symbol "_Z9qt_assertPKcS0_i" is in Qt5Core.dll or Qt5Cored.dll, so something is not good with what is being run.
Select Rebuild from the Build menu.
Copy and paste the output from the Compile Output pane. -
Hi ChrisW67. Thanks your help. Follows COMPILE OUTPUT and APPLICATION OUTPUT:
COMPILE OUTPUT
15:30:55: Starting: "C:\Qt\Tools\mingw1120_64\bin\mingw32-make.exe" -j4
C:/Qt/Tools/mingw1120_64/bin/mingw32-make -f Makefile.Debug
mingw32-make[1]: Entering directory 'D:/OneDrive/00-ProjectosQTCreator/build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug'
mingw32-make[1]: Nothing to be done for 'first'.
mingw32-make[1]: Leaving directory 'D:/OneDrive/00-ProjectosQTCreator/build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug'
15:30:57: The process "C:\Qt\Tools\mingw1120_64\bin\mingw32-make.exe" exited normally.
15:30:57: Elapsed time: 00:02.
AFTER REBUILD
include/QtGui -IC:/Qt/6.3.1/mingw_64/include/QtCore -Idebug -I. -I/include -IC:/Qt/6.3.1/mingw_64/mkspecs/win32-g++ -o debug\moc_janela.o debug\moc_janela.cpp
g++ -Wl,-subsystem,windows -mthreads -o debug\Janela01.exe debug/main.o debug/janela.o debug/moc_janela.o C:\Qt\6.3.1\mingw_64\lib\libQt6Widgets.a C:\Qt\6.3.1\mingw_64\lib\libQt6Gui.a C:\Qt\6.3.1\mingw_64\lib\libQt6Core.a -lmingw32 C:\Qt\6.3.1\mingw_64\lib\libQt6EntryPoint.a -lshell32
mingw32-make[1]: Leaving directory 'D:/OneDrive/00-ProjectosQTCreator/build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug'
15:34:21: The process "C:\Qt\Tools\mingw1120_64\bin\mingw32-make.exe" exited normally.
15:34:21: Elapsed time: 00:22.APPLICATION OUTPUT
15:30:58: Starting D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe...
15:31:03: D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe crashed.15:36:35: Starting D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe...
15:36:49: D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe crashed. -
I copy Qt6Gui.dll and Qt6Core.dll to windows\system32. Today i remove from windows\system32. Now the message is:
Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library.
Qt6Gui.dll
Qt6Core.dll
DLL are in folder C:\Qt\Tools\QtCreator\bin -
Hi, the .dlls in the folder r C:\Qt\Tools\QtCreator\bin are meant to be used exclusively by Qt Creator. They usually are built with MSVC 2019, not with MingGW, and that could explain the error with the missing procedure entry point.
If you remove all Qt6Core.dll that you've copied, so that only 2 remains:
one in C:\Qt\6.3.1\mingw_64\bin and one in C:\Qt\Tools\QtCreator\bin (and they should have different sizes and dates) do you still get the same error when trying to build an app from Qt's Examples? -
Hi ChrisW67. Thanks your help. Follows COMPILE OUTPUT and APPLICATION OUTPUT:
COMPILE OUTPUT
15:30:55: Starting: "C:\Qt\Tools\mingw1120_64\bin\mingw32-make.exe" -j4
C:/Qt/Tools/mingw1120_64/bin/mingw32-make -f Makefile.Debug
mingw32-make[1]: Entering directory 'D:/OneDrive/00-ProjectosQTCreator/build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug'
mingw32-make[1]: Nothing to be done for 'first'.
mingw32-make[1]: Leaving directory 'D:/OneDrive/00-ProjectosQTCreator/build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug'
15:30:57: The process "C:\Qt\Tools\mingw1120_64\bin\mingw32-make.exe" exited normally.
15:30:57: Elapsed time: 00:02.
AFTER REBUILD
include/QtGui -IC:/Qt/6.3.1/mingw_64/include/QtCore -Idebug -I. -I/include -IC:/Qt/6.3.1/mingw_64/mkspecs/win32-g++ -o debug\moc_janela.o debug\moc_janela.cpp
g++ -Wl,-subsystem,windows -mthreads -o debug\Janela01.exe debug/main.o debug/janela.o debug/moc_janela.o C:\Qt\6.3.1\mingw_64\lib\libQt6Widgets.a C:\Qt\6.3.1\mingw_64\lib\libQt6Gui.a C:\Qt\6.3.1\mingw_64\lib\libQt6Core.a -lmingw32 C:\Qt\6.3.1\mingw_64\lib\libQt6EntryPoint.a -lshell32
mingw32-make[1]: Leaving directory 'D:/OneDrive/00-ProjectosQTCreator/build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug'
15:34:21: The process "C:\Qt\Tools\mingw1120_64\bin\mingw32-make.exe" exited normally.
15:34:21: Elapsed time: 00:22.APPLICATION OUTPUT
15:30:58: Starting D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe...
15:31:03: D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe crashed.15:36:35: Starting D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe...
15:36:49: D:\OneDrive\00-ProjectosQTCreator\build-Janela01-Desktop_Qt_6_3_1_MinGW_64_bit-Debug\debug\Janela01.exe crashed.@CidGianni said in Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library:
Hi ChrisW67. Thanks your help. Follows COMPILE OUTPUT and APPLICATION OUTPUT:
Thanks. I stand corrected, your program is compiling, linking, and then failing at run time. Mismatched DLLs, as @hskoglund is chasing, is the most likely cause.
-
Hi, the .dlls in the folder r C:\Qt\Tools\QtCreator\bin are meant to be used exclusively by Qt Creator. They usually are built with MSVC 2019, not with MingGW, and that could explain the error with the missing procedure entry point.
If you remove all Qt6Core.dll that you've copied, so that only 2 remains:
one in C:\Qt\6.3.1\mingw_64\bin and one in C:\Qt\Tools\QtCreator\bin (and they should have different sizes and dates) do you still get the same error when trying to build an app from Qt's Examples?@hskoglund Yes. I still get the same error when trying to build an app from Qt's. And dll there are only in two folders: C:\Qt\6.3.1\mingw_64\bin and C:\Qt\Tools\QtCreator\bin, and the have different sizes and dates too. I don't understand why they are different.
-
@CidGianni said in Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library:
Hi ChrisW67. Thanks your help. Follows COMPILE OUTPUT and APPLICATION OUTPUT:
Thanks. I stand corrected, your program is compiling, linking, and then failing at run time. Mismatched DLLs, as @hskoglund is chasing, is the most likely cause.
@ChrisW67 said in Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library:
Thanks. I stand corrected, your program is compiling, linking, and then failing at run time. Mismatched DLLs, as @hskoglund is chasing, is the most likely cause.
Hi @ChrisW67 thanks. Do you have any suggestion? Thanks again.
-
@ChrisW67 said in Could not find procedure entry point _Z9qt_assertPKcS0_i in dynamic link library:
Thanks. I stand corrected, your program is compiling, linking, and then failing at run time. Mismatched DLLs, as @hskoglund is chasing, is the most likely cause.
Hi @ChrisW67 thanks. Do you have any suggestion? Thanks again.
@CidGianni
It seems likely/possible your program is finding DLLs fromC:\Qt\Tools\QtCreator\bin
at runtime when you need it to only find files from/look inC:\Qt\6.3.1\mingw_64\bin
. They are not the same because the QtCreator ones are only for use by QtCreator.I copy Qt6Gui.dll and Qt6Core.dll to windows\system32. Today i remove from windows\system32. Now the message is:
DLL are in folder C:\Qt\Tools\QtCreator\binDon't do such a thing if you do not know what you doing. It sounds like you have copied the wrong files. If you must do this yourself at all manually, I assume the ones in
C:\Qt\6.3.1\mingw_64\bin
would be the correct ones.You should understand the difference between Qt Creator files, which are just for it to use, versus the Qt files your application uses.
-
Hi, in addtion to what @JonB says:
Try not using OneDrive for storing your projects, instead create a directory somewhere on your C: drive.
To avoid the mixup/collision with Qt dlls, try installing a Qt5 version of MinGW, for example 5.15.2 and see if you get the same error when launching the 5.15.2 version of your app. -
Hi, in addtion to what @JonB says:
Try not using OneDrive for storing your projects, instead create a directory somewhere on your C: drive.
To avoid the mixup/collision with Qt dlls, try installing a Qt5 version of MinGW, for example 5.15.2 and see if you get the same error when launching the 5.15.2 version of your app.@hskoglund Thanks. I make test saving project in d:\QTProject, but not solve de problems. Now i uninstall QT 7.0.2 and I will try an old version.
-
Ensure that neither the installer nor your good self is adding
C:\Qt\Tools\QtCreator\bin
to the system PATH.