John LaGrone wrote > cmake_minimum_required(VERSION 2.8.12 FATAL_ERROR) > project(ex1) > find_package(foo REQUIRED) > add_executable(ex1.x ex1.c) > target_link_libraries(ex1.x foo)
Just check that library exists already: if(NOT TARGET foo) find_package(foo REQUIRED) endif() -- View this message in context: http://cmake.3232098.n2.nabble.com/Finding-internal-libraries-tp7591003p7591056.html Sent from the CMake mailing list archive at Nabble.com. -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake