[cmake-developers] Making Config.cmake files easier to write

Brad King brad.king at kitware.com
Thu Feb 16 10:22:28 EST 2012


On 2/16/2012 10:15 AM, Alexander Neundorf wrote:
> On Thursday 16 February 2012, Brad King wrote:
>> In hindsight that name was poorly chosen.  I'd really like to see "package"
>> in the name because they are "package configuration files".  Otherwise
>> there is no indication it has anything to do with find_package.
>
> Well, it has to do with Config files :-)

Okay, so it can have "PackageConfig" in its name since they are
"package configuration" files.

> So which one ?
> 1) configure_config_file() + write_basic_config_version_file()
> 2) configure_package_file() + write_basic_config_version_file()
> 3) configure_package_file() + write_basic_package_version_file()
>
> Personally, I prefer 1) and 3) over 2).

include(CMakePackageConfigHelper) # "CMakeConfigHelper" is ambiguous IMO
configure_package_config_file(...)
write_basic_config_version_file(...) # no need to change name

-Brad



More information about the cmake-developers mailing list