[cmake-developers] How to handle package Config.cmake files with dependencies ?

Brad King brad.king at kitware.com
Mon Mar 12 09:17:17 EDT 2012


On 3/10/2012 10:45 AM, Alexander Neundorf wrote:
>        std::string req_var = this->Name + "_FIND_REQUIRED_" + args[i];
>        this->AddFindDefinition(req_var.c_str(), "1");
[snip]
> Since this contains the word "required" multiple times this also suggests that
> the list of components is the list of required components.

The name REQUIRED is historical because components were once listed only
after the REQUIRED keyword.  Only later was the COMPONENTS keyword added,
but the <pkg>_FIND_REQUIRED_<comp> names were already in use.

Still I think the proposed behavior makes sense and is achievable with a
policy.  I'll look at the two topics you pushed for this thread when I get
a chance.

Thanks,
-Brad



More information about the cmake-developers mailing list