This adds the locations of the package files to the registry on windows, which should allow them to be auto detected by cmake on windows when linking against waffle in other projects.
Signed-off-by: Dylan Baker <[email protected]> --- This patch is completely untested (I don't have access to a windows development machine, nor do I want to maintain one), I've sent this as a courtesy to windows users, and hopefully it can point an interested part in the correct direction. Note that this installs into the local machine registry, and there is also the option of using local user registry instead, and that can be done by changing waffle to use export(), though I'm not exactly sure how that works either CMakeLists.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 729ebc1..0ac2d4b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -182,6 +182,16 @@ install( COMPONENT Devel ) +# If running on windows add waffle to the registry so it can be auto detected +# by consuming projects +if (WIN32) + execute_process( + COMMAND "REG ADD HKEY_LOCAL_MACHINE\Software\Kitware\CMake\Packages\Waffle /v Waffle-1 /t REG_SZ /d ${ConfigPackageLocation} /f" + ERROR_QUIET + OUTPUT_QUIET + ) +endif () + # ------------------------------------------------------------------------------ include(WafflePrintConfigurationSummary) -- 2.2.1 _______________________________________________ waffle mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/waffle

