Trolltech Home | Qt-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 5

Qt-interest Archive, January 2007
Qt 4.2.2 compilation errors


Message 1 in thread

Hello,

Please find below errors during compilation of Qt 4.2.2 on a Unix-like OS. (We have successfully compiled and executed Qt 3.x on this OS).

1. I have configured Qt using the foll. command:

./configure -platform lynxos-g++ 

But before generating the Makefiles, the configure script displays: "Cannot find GLIB-2.0". Qt is now configured for compilation. 

2. When I give make, it says:

 cd src
 cd tools/moc

 Could not find mkspecs for your QMAKESPEC after trying:

 /home/qt-4.2.2/qt-x11-opensource-src-4.2.2/src/tools
 Error while processing project file: moc.pro
 make[2]: ***
 [/home/qt-4.2.2/qt-x11-opensource-src-4.2.2/src/tools/moc/Makefile]
 make[1]: *** [sub-tools-moc-make_default-ordered] Error 2
 make: *** [sub-src-make_default-ordered] Error 2

Can anyone please provide suggestions to resolve this issue. It appears that QMAKESPEC variable is not set correctly. We tried modifying the configure script and setting the environment variable QMAKESPEC to /home/qt-4.2.2/qt-x11-opensource-src-4.2.2/mkspecs/lynxos-g++ but this did not work. 
We did not face such problems with QMAKESPEC while compiling Qt 3.x version on the same OS.

Thanks in advance.
Pankaj.

Message 2 in thread

[sorry, sent to Pankaj accidentally in private before]

Pankaj schrieb:
> >
> > Hello,
> >
> > Please find below errors during compilation of Qt 4.2.2 on a Unix-like
> > OS. (We have successfully compiled and executed Qt 3.x on this OS).
> >
> > 1. I have configured Qt using the foll. command:
> >
> > ./configure -platform lynxos-g++
> >
> > But before generating the Makefiles, the configure script displays:
> > "Cannot find GLIB-2.0". Qt is now configured for compilation.

This suggests that GLIB 2.0 is not installed on your target system or
it's header files are not in the INCLUDE or the pkg-config (which I
believe is how glib is detected) tool is not in your PATH.

Either way, make sure that Qt configure finds the proper installation
path before going on!

> > 2. When I give make, it says:
> >
> >  cd src
> >  cd tools/moc
> >
> >  Could not find mkspecs for your QMAKESPEC after trying:
> > ...
> > Can anyone please provide suggestions to resolve this issue. It appears
> > that QMAKESPEC variable is not set correctly. We tried modifying the
> > configure script and setting the environment variable QMAKESPEC to

Actually you should set QMAKESPEC in your environment before
configuration, something like

  setenv QMAKESPEC lynxos-g++

(also make sure that the PATH is set to something like

  setenv PATH ${QTDIR}/bin;${PATH}

while you're at it - QTDIR is the root directory of your Qt installation
- check the INSTALL readme of your Qt installation for details)

I assume you have already done so (if not, now would be the time to do
so  ;)  so first try to solve the glib problem above. I'm not sure, but
maybe Qt 3 uses some other check to find the glib installation or uses
another version of glib which happens to be installed on your platform -
that would explain why Qt 3 works whereas Qt 4 does not.

Cheers, Oliver



--
 [ signature omitted ] 

Message 3 in thread

Hi,

> 1. I have configured Qt using the foll. command:
> 
> ./configure -platform lynxos-g++ 
> 
> But before generating the Makefiles, the configure script displays: 
> "Cannot find GLIB-2.0". Qt is now configured for compilation.

Build Qt without GLIB support:
	./configure -platform lynxos-g++ -no-glib

I believe this should be automatically detected though, I'm not sure why 
  the configure script does not detect that GLIB is not available. 
Making the output of the following command available would help 
understand what went wrong with auto-detection:
	./configure -platform lynxos-g++ -v -v

Anyway, LynxOS is not a supported or tested platform.

> 2. When I give make, it says:
> [...]
>  Could not find mkspecs for your QMAKESPEC after trying:
> [...]
> Can anyone please provide suggestions to resolve this issue. It appears 
> that QMAKESPEC variable is not set correctly. We tried modifying the 
> configure script and setting the environment variable QMAKESPEC to 
> /home/qt-4.2.2/qt-x11-opensource-src-4.2.2/mkspecs/lynxos-g++ but this 
> did not work.

Have you tried *not* setting QMAKESEPC?

If you really want to set it, I think it should be set to:
	lynxos-g++

--
 [ signature omitted ]