hello, I'm trying to write a for look that will iterate on a group of libs and find the path of the lib, here is my code: SET(LIBS AR ARMulti ARvideo) FOREACH (LIB ${LIBS}) SET(FOUND_LIB) FIND_LIBRARY(LIB_FOUND ${LIB} /usr/lib /usr/local/lib) SET(ARTK_LIBRARY ${ARTK_LIBRARY} ${LIB_FOUND}) ENDFOREACH(LIB)
the result is /usr/lib64/libAR.a/usr/lib64/libAR.a/usr/lib64/libAR.a when it should be /usr/lib64/libAR.a /usr/lib64/libARMulti.a /usr/lib64/libARvideo.a but when I run FIND_LIBRARY(test ARvideo /usr/lib /usr/local/lib), I get the right file. how can I do that? thanks _______________________________________________ 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