[SOLVED] Merging installation of Qt4.8 and Qt5.2
Hello, I need to be able compile a project that uses Qt4 but is incompatible with Qt5 and a project in Qt5 that is not retro-compatible. I firstly needed the Qt5 project, so that's the one I installed first. Unfortunately the package manager does propose to install Qt4.8¹. After two days of painful downloading, I finally downloaded Qt4.8. I also downloaded and extracted MinGW4.4.0 in C:\Qt\Tools\mingw44_32, and pointed the Qt4 installer to this version of MinGW. But now my Qt5 project won't compile with the following error :
@11:58:12: The process "mingw32-make.exe" exited with code -1.
Error while building/deploying project GLGIS (kit: Desktop Qt 5.2.1 MinGW 32bit)@
My project kit seems okay, though :
@Name: Desktop Qt 5.2.1 MinGW 32bit
Device type: Desktop
Device: Local PC (default for Desktop)
Compiler: MinGW 4.8 32bit //Note, different from MinGW 4.4, this is the formely auto-detected MinGW
Debugger: Extracted from Kit Desktop Qt 5.2.1 MinGW 32bit
Qt version: Qt 5.2.1 MinGW 32 bit
Of course taking two more days to re-download Qt5 is not the easy solution.
EDIT: Woops, wrong posting place ! Could someone move the subject please ?
¹ But why not ???
If I may, you should rather install one of Qt 4.8.6 snapshot from "here":http://download.qt-project.org/snapshots/qt/4.8/
That way you don't need to have several version of mingw-installed.
If not possible, check that you don't have MinGW 4.4 in your PATH, if so, remove it.
No unfortunately I haven't MinGW in my path but thank you for the suggestion.
Anyway the damage is done; I don't think uninstall Qt4.8 will fix it; what else can I check ? is there any other variable that both Qt4.8 and Qt5.2 write ?
EDIT: Nay, uninstalling Qt4.8 does not change a damn thing, I have the same error.
I would double check the Kits and the Compilers panel in the preferences to see whether all compilers are correctly listed and the Kits to verify that current compiler associated with Qt is the correct one
Nothing to see there either !
The Qt version with the same name as linked above :
@name : Qt 5.2.1 MinGW 32bit
Qt version for desktop:
Qt 5.2.1 MinGW 32bit
The MinGW version with the same name as linked above :
@Name: MinGW 4.8 32bit
Compiler path: C:\Qt\Tools\mingw48_32\bin\g++.exe
Platform Codegen Flags:
Platform Linker Flags:
Got it during my installation I removed without realizing it the directory mingw48_32 to only mingw44_32. But now I have to reinstall Mingw4.8, but the Qt package manager cannot reinstall ! I must uninstall the whole Qt5 because of brainless (understand: unavoidable) dependency check and do a full reinstall of it (which means at least 2 days of downloading in my current situation… :'( ).
Thank you for previous help.
It there is an advice on how to do the equivalent of "apt-get reinstall -y gcc" or "yum reinstall -y gcc" or "pacman -S gcc" with the Qt package manager for windows, I'm listening !
EDIT: or how to hack to make it think that only :MinGW is not installed, or the address where the package it downloads is manually downloadable so I can silently fix, or (…)
Ok, I found it there and extracted it :
-But I'm still unable to compile anew… Here is a sample of the new error I get :-
@Makefile.Release:151: recipe for target 'compiler_rcc_clean' failed
process_begin: CreateProcess(NULL, del release\qrc_shaders.cpp, ...) failed.
make (e=2): The system cannot find the file specified.
mingw32-make: [compiler_rcc_clean] Error 2 (ignored)
del release\moc_glviewer.cpp release\moc_layer.cpp release\moc_unoptimizedlayer.cpp release\moc_polygonlayer.cpp release\moc_simpleshaderlayer.cpp release\moc_terrainlayer.cpp@
EDIT : rebuild in another directory and it seems to work. Many thanks for the motivation.
You're welcome !
As an alternative you may use the online installer which will allow you to more easily update and install several versions of Qt 5 (e.g. for android, mingw, Visual Studio etc…)
Happy coding !