[SOLVED] QMake infinite loop
-
Hello.
All of a sudden, my Qt (on windows xp) project won't build or clean anymore, rather it will endlessly output :
@C:\Qt\5.2.1\mingw48_32\bin\qmake.exe -spec win32-g++ CONFIG+=debug CONFIG+=declarative_debug CONFIG+=qml_debug -o Makefile ....\GLGIS\GLGIS.pro@I tried to run the step manually in cmd with more verbose information, and here is what I noticed while running mingw32-make -d :
@...
Finished prerequisites of target file 'Makefile'.
Prerequisite '../../GLGIS/GLGIS.pro' is newer than target 'Makefile'.
Prerequisite '../../../Qt/5.2.1/mingw48_32/mkspecs/win32-g++/qmake.conf' is older than target 'Makefile'.
Prerequisite '../../../Qt/5.2.1/mingw48_32/mkspecs/features/spec_pre.prf' is older than target 'Makefile'.
...@So it seems for some reasons the makefile tells make to call qmake which updates the project file which causes make to start over. Then make calls qmake again which updates again the project file which causes make to start over again and so on endlessly.
How do I get out of this hell ? Many thanks to anyone for any help !
-
qmake itself does not modify PRO files so that cannot cause the behaviour you describe. The evidence you present only shows that make processing superior Makefile has (correctly) determined that it needs to regenerate the Makefile corresponding to '../../GLGIS/GLGIS.pro' by running qmake.
If the Makefile was write protected, locked open by something else, or modified by something you have done then you would possibly have issues.
I am sure you already tried deleting your shadow build directory, checking the time on your machine, and doing a clean build.
-
I had deleted my shadow build directory, checked the time of my machine and done a clean build, but I hadn't checked the modification time of my source files.
Actually some of them, including the GLGIS.pro file had a modification time 10 days in the future. Saving the file through QtCreator didn't change that timestamp when I cleaned my build directory, so I use msys and I ran
@find -true -exec touch '{}' ';'@in the root of the source tree, and then everything worked !
Thank you ChrisW67 for the hint.