[CMake] Wierd find_program behaviour

Paul Baumer paul.baumer2 at gmail.com
Mon Jul 22 11:40:49 EDT 2013


Hello,

I am having some problem with FindQt4.cmake (both in v2.8.11.2 and
v2.8.10.2). I have localised the problem to a find_program call and added
message() calls around this find_program call.

  message("--------------------env QTDIR $ENV{QTDIR}")

  find_program(QT_QMAKE_EXECUTABLE NAMES ${QMAKE_NAME}
    PATHS
      ENV QTDIR

"[HKEY_CURRENT_USER\\Software\\Trolltech\\Versions\\${qt_install_version};InstallDir]"
    PATH_SUFFIXES bin
    DOC "The qmake executable for the Qt installation to use"
  )

  message("--------------------QT_QMAKE_EXECUTABLE: ${QT_QMAKE_EXECUTABLE}")

The environment variable QTDIR is set
to F:/TCT/4.7.4-gefed_vc10_exe-win32-msvc++10.0-64bit

The following is printed to the console:

--------------------env QTDIR
F:/TCT/4.7.4-gefed_vc10_exe-win32-msvc++10.0-64bit
--------------------QT_QMAKE_EXECUTABLE:
F:/TCT/4.7.4-gefed_vc10_exe-win32-msvc++10.0-64bit

I would expect the QT_QMAKE_EXECUTABLE to point to
F:/TCT/4.7.4-gefed_vc10_exe-win32-msvc++10.0-64bit/bin/qmake.exe but it
doesn't.

Is this a bug?

Paul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130722/ef91501d/attachment.htm>


More information about the CMake mailing list