[Qt-interest] Qt compilation issue
Andreas Pakulat
apaku at gmx.de
Wed Jan 25 11:45:32 CET 2012
On 25.01.12 15:03:51, Chirag Anand wrote:
> Hello,
>
> I am not able to compile Qt for some reason, though I have done it
> several times before without any problem. This is the error it throws:
>
> graphicsview/qgraphicslayoutitem.cpp: In member function 'bool QGraphicsLayoutItemPrivate::hasWidthForHeight() const':
> graphicsview/qgraphicslayoutitem.cpp:380:28: error: 'class QSizePolicy' has no member named 'hasWidthForHeight'
> graphicsview/qgraphicslayoutitem.cpp:381:1: warning: control reaches end of non-void function
> make[1]: *** [.obj/debug-shared/qgraphicslayoutitem.o] Error 1
> make[1]: *** Waiting for unfinished jobs....
> make[1]: Leaving directory `/home/chiky/projects/qt/src/gui'
> make: *** [sub-gui-make_default-ordered] Error 2
>
> I have searched Google, asked on IRC, and a couple of other people but
> no answer as for now. I did a clean git clone and then compiled the 4.8
> branch. I have checked the dependency list on the developer wiki also,
> and ./configure also does not throw any errors. I am using Gentoo Base
> System release 2.0.3, with kernel 3.0.6-gentoo SMP.
>
> Can somebody give me any pointers to what the solution could be
> for this error?
Looks like your Qt picks up some headers from outside its source-dir, do
you also have Qt development stuff installed in /usr/include maybe? That
would explain this since the member was introduced in 4.8, so if there's
a system-Qt < 4.8 your Qt compilation may pick up the qsizepolicy.h from
that instead of its own. Cleanup your system Qt and remove all headers
or install it in a way that the headers are not in the default search
path of the compiler.
Andreas
More information about the Qt-interest-old
mailing list