[CMake] FindQt4 stubbornly finding Qt3

Andreas Pakulat apaku at gmx.de
Tue May 19 10:11:36 EDT 2009


On 19.05.09 08:40:32, Zach Laine wrote:
> On Tue, May 19, 2009 at 12:24 AM, Clinton Stimpson <clinton at elemtech.com> wrote:
> > What about a minimal CMakeLists.txt file?
> > ===
> > find_package(Qt4)
> > message(${QT_INCLUDE_DIR})
> > ===
> 
> When I run this:
> 
> ================
> find_package(Qt4)
> include(${QT_USE_FILE})
> 
> message(${QT_LIBRARY_DIR}) # prints "/usr/lib"
> message(${QT_INCLUDE_DIR}) # prints "/usr/lib/qt3/include"
> ================
> 
> I get this output:
> 
> ================
> -- Found Qt-Version 4.3.5
> /usr/lib
> /usr/lib/qt3/include
> -- Configuring done
> -- Generating done
> -- Build files have been written to: /ldisk/localstorage/proj/cmake/qt_test
> ================
> 
> ... just what I've gotten all along.  How about posting a minimal file
> that is supposed to work, that I can test on my system?

Thats what Clinton did, so how about trying exactly what he wrote? In
particular you could try without the QT_USE_FILE and see wether the
variables are different then. If not the next step would be to start
putting message() calls into FindQt4.cmake in CMake's Modules/ directory to
find out why it uses the wrong qmake or wether maybe the qmake supplies the
wrong paths.

Andreas

-- 
You will step on the night soil of many countries.


More information about the CMake mailing list