Solved Trying to run default QT Plain C++ App -> -1073741515
-
@ghost23 You should not add anything to PATH - it is not needed!
It should work.
You're using QtCreator? -
@J.Hilk said in Trying to run default QT Plain C++ App -> -1073741515:
Thats actually not always true, I for example had to add the MSVC Debugger manually for 5.9.1 in the project settings
But for that you do not need PATH, right?
-
@jsulm Nope. you need to add the Windows(10) Kit binary folder to the Path variable
in my caseC:\Program Files (x86)\Windows Kits\10\bin\x86
-
@J.Hilk I'm not using Microsoft compiler, but can't you just add the absolute path to the debugger in QtCreator?
-
@jsulm said in Trying to run default QT Plain C++ App -> -1073741515:
@J.Hilk I'm not using Microsoft compiler, but can't you just add the absolute path to the debugger in QtCreator?
If I'm not mistaken, than changing /adding stuff in your path variable via Qt-Creators project settings
is exactly that. My global System PATH variable is unchanged.
-
-
Hi,
oh so many replies :)
So, yes I am using QTCreator. So, I have added the path to the x86 version of the ucrtbased.dll to the PATH variable in the System environment variables.
A little bit has changed, when doing so. When I run the .exe manually in a CMD window, now I get the error "0xc000007b".
IN QTCreator, though, I still get the same outcome, as before, although in the Project settings, I can see, that the Path to the ucrtbased.dll is also added.
-
@ghost23 Close, but no cigar. Error "0xc000007b" means that your 64-bit console program is trying to load the 32-bit version of ucrtbased.dll :-( You need to find a 64-bit flavor of ucrtbased.dll on your computer.
-
Hi,
ok, so this took some time. Yesterday I found, that I had installed a mess of Microsoft and Windows SDKs and I thought, let's clean this up. So I uninstalled all those SDKs. Then I read the Qt documentation again and it says, that I should install a compiler as a requirement for Qt. One of the recommendations is to use Visual C++ build tools. So I have installed the Visual C++ Build Tools 2015.
Then I start Qt, but I cannot compile my plain c++ app in Debug mode, because Qt cannot find a debugger. After some investigation, I find, that the Visual C++ build tools 2015 do not contain a debugger. Why isn't that mentioned in the documentation?
So after somer further googling I find, that the Windows SDK comes with a debugger (the cdb.exe). So I install the Windows SDK. Now I have a debugger.
Then, when I tried compile my app in debug mode, I got this error:
LINK : fatal error LNK1158: cannot run 'rc.exe'
So, for some reason, the place, where the rc.exe is, wasn't in my PATH. Added it, now finally, I can compile both the debug and the release version and run them without errors.
Man, I have to say, I haven't even written one line of code as of now, but I am already exhausted.
Thanks for all the help, though. Much appreciated.
-
@ghost23 jup, run into exatcly the same issue.
But the advantage of the MSVC compiler is, that it's about 5 times faster (on Windows) than mingw, so you'll have that time back in a couple of weeks :)You should set the topic to solved, if you managed to solve your problem :p
-
@ghost23 "I cannot compile my plain c++ app in Debug mode" - you don't need a debugger to build in debug mode. You only need it if you want to debug.
"Why isn't that mentioned in the documentation?" - it is: http://doc.qt.io/qtcreator/creator-debugger-engines.html