Hi there, I have modified FindZLIB.cmake and FindPNG.cmake, because I want to specify a separate release and debug library for MSVC to link to.
The problem is, my libraries are not in any standard place. I want to use cmake-gui, run cmake and punch in exactly where these libraries live. So I have a call in FindPNG, like this: find_library(PNG_LIBRARY_RELEASE NAMES ${PNG_NAMES_RELEASE} ) which it will not find. at the bottom, there is: mark_as_advanced(PNG_PNG_INCLUDE_DIR PNG_LIBRARY PNG_LIBRARY_RELEASE PNG_LIBRARY_DEBUG) My problem is, PNG_LIBRARY_DEBUG/RELEASE do NOT appear in cmake-gui. Only PNG_PNG_INCLUDE_DIR and PNG_LIBRARY show up. Is this because if Find_Target() doesn't find anything, it does not define the variable at all? This creates a problem. If find_target doesn't find the target, the variable is not defined, and thus the user isn't given the chance to input the correct location. Note that PNG_LIBRARY is not good enough, because you can't specify a set of optimized/debug libraries in the slot. My only choice seems to be to hack the cmake files to define the PNG_RELEASE_LIBRARY variable. Which is not ideal, because I'm compiling VTK, this is not my own project, so I'll have to maintain a patch just for this hack. thanks, Paul
-- 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