QtCore4.dll Error When Starting Release App From Windows - Debug OK, Starting Release or Debug App from Command Prompt OK
-
Hi All.
Windows XP SP3
{Mingw - do not know how to establish version of Mingw
Qt 2010.05
QtCreator 2.0.1 } These three installed together from a single downloadQwt 6.0.0-rc5
Very new at this. This is the first of two different queries that I will post separately. Here goes ...
Am an old, unreformed and unrepentent C programmer that has not programmed in many years.
Am aware of C++ concepts such as classes, inheritance, polymorphism, overloading but not yet comfortable with these concepts.When I create and build an app (just learning stuff, nothing important) from within Qt Creator it will run OK when started from Qt Creator or from a command prompt (Haven't got the hang of Qt Creator yet and haven't figured out how to do a release build in Qt Creator yet). If built as either 'debug' or 'release' from a command prompt it will run OK from the command prompt. If built as 'debug' from the command prompt it will run OK if started from Windows (Explorer). However if built as 'release' from the command prompt and run from Windows it will produce the following error
'The procedure entry point _Z5qFreePv could not be located in the dynamic link library QtCore4.dll.'There are two, different QtCore4.dll files in the Qt install. Both have version 4.7.0.0 but they differ in size.
QtCore4.dll version 4.7.0.0 2.18MB located in c:\qt\2010.05\bin
QtCore4.dll version 4.7.0.0 2.41MB located in c:\qt2010.05\qt\binI can copy either into the app's directory but the error remains when I try to start the app from Windows.
With the smaller of the two dlls in the app directory, starting the app from the command prompt results in the same error.
With the larger there is no error when starting from the command prompt.To summarize...
Debug builds - all OK, no matter if started from Windows, command prompt or from within Qt Creator
Release build - will start OK from command prompt but not from WindowsI am sure that I must have installed something not quite right or am doing something silly now.
Any ideas?
Take care.
Mike
-
The dll's from this folder should be used (copy in the same folder as application): c:\qt2010.05\ qt \bin the other ones are used by Creator.
When you say command prompt you mean Windows cmd or the one that set the Qt environment?
Also if you double click from explorer or use Windows cmd (without Qt environment) you need two more dlls for MingW run-time ( mingwm10.dll and libgcc_s_dw2-1.dll) from C:\Qt\2010.05\mingw\binAnd make sure you copy the dll for each Qt module you linked with your application (QtCore4.dll, QtGui4.dll, etc)
-
Thank you Zlatomir.
Problem solved.
- You are quite correct to question my use of the term 'command prompt'. I was using the 'Qt Command Prompt', not Window's command prompt. Silly me!
- The dlls I need for this app are
QtCore4.dll (the one from the ..\2010.05\qt\bin folder as you suggested)
QtGui.dll
QtSvg4.dll - this probably included by Qwt (am using some Qwt Dials).
Many thanks for you help, Zlatomir.
Take care.
Mike
-
Check the following article... Hope it helps to resolve your "dll missing":http://www.articlewritingclicks.com/errors/dll4.php error.. http://www.windowserrorhelps.com/qtcore4-dll-error-how-to-fix-missing-qtcore4-dll-problem-in-windows-7/