On Sunday 05 Dec 2010 6:16:35 pm Michael Hertling wrote: > On 11/30/2010 05:53 AM, Kishore wrote: > > On Tuesday 23 Nov 2010 5:27:56 pm Johannes Zarl wrote: > >> Another somehow related topic seems to be import/export of targets. Should > >> a LibraryConfig.cmake or FindLibrary.cmake file create imported targets > >> for the library? > > > > Thanks for this thread. It has helped. However, i am still not clear about > > the use of the export/import feature. I thought that libraries built with > > cmake would not need to write their Find*.cmake or *Config.cmake modules as > > they could simply use the EXPORT feature. > > No, the file created and installed by INSTALL(EXPORT ...) - casually > denoted as a "targets file" - contains information about the targets > provided by the package. The targets are set up as "IMPORTED" in the > targets file, and the latter must be included by *Config.cmake which > is still necessary. This is meant as a more flexible alternative to > explicit paths in XXX_LIBRARIES variables, e.g.; with targets files, > XXX_LIBRARIES contains the imported targets instead of the targets' > paths, so the different build types can be handled much better at > link time. The actual paths of the imported targets are specified > by means of IMPORTED_LOCATION properties in the targets file, too.
Thanks Michael. I think i have this somewhat figured out now. Will use and see if i have more doubts. -- Cheers! Kishore _______________________________________________ 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