Hello Alexander, Am Montag, 12. Dezember 2011, 21:51:54 schrieb Alexander Neundorf: > Here is an example which shows just that: > https://projects.kde.org/projects/kde/kdeexamples/repository/revisions/mast > er/show/buildsystem/HowToInstallALibrary > > It's not "final" yet, i.e. I'll work on improving it in the next weeks.
thank you very much for this example project. It helped me a lot to understand especially the EXPORT usage. I know that you wrote that the project is not finished yet, but allow me to ask a question: In the "example/CMakeLists.txt": Is line 5, which calls "include(FindPackageHandleStandardArgs)", really needed? I think if BAR_FOUND would be checked, it should be called. But in the current version only BAR_INCLUDES, BAR_LIBRARIES, and BAR_VERSION are used. These variables should be set by "BarConfig.cmake", shouldn't they? I would greatly appreciate it if you could extend the example, or provide a second example, that uses an external library. So for example a library Foo depending on LibXml2. Some functionality of Foo depends on whether LibXml2 was found or not. Therefore it creates "Foo_Config.h" with "configure_file" defining something like LIB_XML2. I would like to see how this could be correctly installed and found by an application using Foo. Would it be simply adding the config header file to the set of exported header files? Kind regards Benjamin Eikel -- 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
