On 06/25/2014 06:52 AM, Philipp Moeller wrote: > That sounds like a good idea. Although I think that would make things > very confusing: the IMPORTED_LOCATION would be the full path of the > library, the INTERFACE_INCLUDE_DIRECTORIES would be the full path to the > includes, but all of this is ignored as soon as -framework is used and > the full path to the framework isn't specified (as far as my > understanding of OSX goes). > > Maybe it would make sense to add a FRAMEWORK library type and a > find_framework command to encapsulate all this. It would make writing > those imports a lot smoother as well.
Ideally find_library would just find the "foo.framework/foo" library file inside a framework so that the IMPORTED_LOCATION could be set without constructing that manually. However, we have to be compatible with current behavior so that would at least need to be an option to find_library. I do not think a separate find_framework is necessary. Once the full path to a framework library file inside the framework directory is known then CMake should pass that to the linker by full path too instead of using "-framework foo". -Brad -- 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-developers