[CMake] find_path() and non-standard paths
Clinton Stimpson
clinton at elemtech.com
Fri Jul 2 15:59:13 EDT 2010
I have this
FIND_PATH(QT_MKSPECS_DIR NAMES qconfig.pri
PATH_SUFFIXES mkspecs)
And a Qt installation
<qtinstall>/bin
<qtinstall>/mkspecs
<qtinstall>/include
<qtinstall>/lib
and this file exists <qtinstall>/mkspecs/qconfig.pri.
And if I set
CMAKE_PREFIX_PATH=<qtinstall>
for a native build or
CMAKE_FIND_ROOT_PATH=<qtinstall>
for cross-compiling, it doesn't get found.
Any idea on the right way to make it found?
I can do append "/mkspecs" to each of the paths in CMAKE_FIND_ROOT_PATH and
pass it to find_path() under PATHS. But that seems like a hack.
Clint
More information about the CMake
mailing list