View Full Version : sub-dir compilation problem
Salazaar
30th October 2007, 22:26
Hi. I've got very annoying problem. I just cannot compile application which is spread across sub-directories. I get some kind of endless project messages loop without proper compilation. Any ideas how to solve it?
Regards
wysota
30th October 2007, 22:36
mingw or msvc? which version? which Qt version? What shell?
Salazaar
30th October 2007, 22:50
mingw 3.2 and qt 4.3.2, and I've had the same problem with qt 4.2.3.
What shell?
i don't understand
wysota
31st October 2007, 01:08
shell: cmd or msys?
What exactly happens if you feed a project such as this to qmake:
TEMPLATE=subdirs
SUBDIRS=s1 s2
and in directories s1 s2 place such projects:
TEMPLATE=app
SOURCES=main.cpp
and create empty main.cpp files in both dirs.
Please paste output of qmake && make which you receive for such a configuration.
Salazaar
31st October 2007, 13:47
I don't know how it happened, but when I tried to compile it to get wrong output which you wanted to see, it's just compiling well. Regards
Salazaar
31st October 2007, 14:54
I've got a problem, in the end of compiling edyuk, I got this error:
C:\MinGW\bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\ mingw32\bin\ld.exe: cannot find -lQtXmld4
So of course after it I got release error. What is wrong?
Regards
jpn
31st October 2007, 14:57
You don't seem have debug version of Qt libs built (notice that there's also a start-menu shortcut for doing so). So try:
> make clean
> qmake -config release
> make
This will compile it in release mode.
Salazaar
31st October 2007, 16:34
Ok, it helped, thanks, but there's another problem. It's compiling the same things for few times, so as it compiles the whole, it starts to compile it again, and there's no end of this loop. Regards
jacek
31st October 2007, 22:13
It's compiling the same things for few times, so as it compiles the whole, it starts to compile it again, and there's no end of this loop.
Either it can't write the compilation results to the disk or there's something wrong with file modification dates.
Salazaar
31st October 2007, 22:24
Either it can't write the compilation results to the disk or there's something wrong with file modification dates.
So, what can I do to solve it?
jacek
1st November 2007, 00:46
So, what can I do to solve it?
First try passing -recursive option to qmake, if that doesn't help check if you can create new files and overwrite old ones in project's subdirectories.
Salazaar
1st November 2007, 18:22
I tried this two things - It hasn't helped
jacek
2nd November 2007, 15:12
I tried this two things - It hasn't helped
Then maybe there's something wrong with file names?
How do you invoke qmake and make? Do you use "Qt Command Prompt"?
Salazaar
2nd November 2007, 22:48
Now everything is fine, edyuk has just set that by default it compiles with debugging, so I just had to add make release at the end
Regards
vBulletin® v3.7.1, Copyright ©2000-2008, Jelsoft Enterprises Ltd.