[CMake] COMPONENTS for export files
Nico Schlömer
nico.schloemer at gmail.com
Sun Apr 7 19:50:07 EDT 2013
Hi all,
I have a software project that I build and install with CMake. For
others to link against the software project, I have a
"MypackageConfig.cmake.in" from which I create "MypackageConfig.cmake"
using CONFIGURE_PACKAGE_CONFIG_FILE(). Others can then invoke
FIND_PACKAGE(Mypackage) in their own CMake files. -- Nice.
Now, the software breaks down into logical units, and it would make
sense for other users to be able for import it with the COMPONENTS
keyword, e.g.,
FIND_PACKAGE(Mypackage COMPONENTS reader writer parser)
Is there a recommended way of generating the package files such that
this syntax becomes applicable?
Cheers,
Nico
More information about the CMake
mailing list