[cmake-developers] Making Config.cmake files easier to write
Alexander Neundorf
neundorf at kde.org
Mon Mar 5 17:04:00 EST 2012
On Friday 02 March 2012, David Cole wrote:
> Alex,
>
> Brad and I reviewed the MakingConfigFilesEasier_ConfigureMacro topic,
> but have two small additional changes to request before we merge it to
> master.
>
> (1) There's a generated comment referencing
> "ConfigureConfigFile.cmake" but there is no such file. Please change
> that to CMakePackageConfigHelpers.cmake.
Ok.
> And (2) you are using the "PACKAGE_HELPER_" prefix... I thought the
> prefix was intended simply to be "PACKAGE_".
>
> After you fix up those two minor points, we'll merge it to 'master' next
> time.
So instead of:
# @PACKAGE_HELPER_INIT@
# ...
# set_and_check(FOO_INCLUDE_DIR "@PACKAGE_HELPER_INCLUDE_INSTALL_DIR@")
# set_and_check(FOO_SYSCONFIG_DIR "@PACKAGE_HELPER_SYSCONFIG_INSTALL_DIR@")
you prefer the following ?
# @PACKAGE_INIT@
# ...
# set_and_check(FOO_INCLUDE_DIR "@PACKAGE_INCLUDE_INSTALL_DIR@")
# set_and_check(FOO_SYSCONFIG_DIR "@PACKAGE_SYSCONFIG_INSTALL_DIR@")
, i.e. without "HELPER" for both the INIT as well as for the actual helper
variables ?
I can do that, but I think at least for the variables the "HELPER" makes
sense.
Alex
More information about the cmake-developers
mailing list