> > Hello, > I'm having trouble getting FIND_PATH to work in a certain case. I have it > working in other Find*.cmake files, but in one of my files I cannot seem > to get it to cooperate and cmake --trace/--debug-output don't seem to > provide any useful information for debugging FIND_PATH. > The problem is that cmake generates a "NOTFOUND" error when using the > following cmake file (DEV_ROOT is set to /home/jlk/dev): > FindTinyXML.cmake: > FIND_PATH( TinyXML_INCLUDE_DIRS NAMES tinyxml.h > PATHS $ENV{DEV_ROOT}/externals/tinyxml ) > MESSAGE( STATUS ${TinyXML_INCLUDE_DIRS} )MESSAGE( STATUS > $ENV{DEV_ROOT}/externals/tinyxml ) > FIND_LIBRARY( TinyXML_LIBRARY_Debug NAMES tinyxml > PATHS $ENV{DEV_ROOT}/externals/tinyxml/Debug ) > FIND_LIBRARY( TinyXML_LIBRARY_Release NAMES tinyxml > PATHS $ENV{DEV_ROOT}/externals/tinyxml/Release ) > SET( TinyXML_FOUND FALSE ) > IF( TinyXML_INCLUDE_DIRS ) SET( TinyXML_FOUND TRUE ) SET( > TinyXML_LIBRARIES ${TinyXML_LIBRARIES} debug > ${TinyXML_LIBRARY_Debug} optimized ${TinyXML_LIBRARY_Release} > )ENDIF() > The two MESSAGE outputs from cmake are: > -- TinyXML_INCLUDE_DIRS-NOTFOUND-- /home/jlk/dev/externals/tinyxml > > The part I do not understand is if I execute an ls command like so: ls -la > /home/jlk/dev/externals/tinyxml/tinyxml.h > The output I get is: -rw-r--r-- 1 jlk jlk 64574 2011-09-27 02:58 > /home/jlk/dev/externals/tinyxml/tinyxml.h > Which, as far as I understand it, is the file that cmake should be looking > for. Does anyone know what could be wrong? As I said, I have other > Find*.cmake files that work and I just can't seem to spot the problem.
My first attempt would be to run the cmake process trough "strace -f -eopen,stat cmake ..." and look which files it is actually looking at. Eike -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake