Merge topic 'cpack-innosetup-linux'
[kiteware-cmake.git] / Modules / FindHTMLHelp.cmake
bloba11ad4d690057d9581b4e0f664e3f6c77d1a3172
1 # Distributed under the OSI-approved BSD 3-Clause License.  See accompanying
2 # file Copyright.txt or https://cmake.org/licensing for details.
4 #[=======================================================================[.rst:
5 FindHTMLHelp
6 ------------
8 This module looks for Microsoft HTML Help Compiler
10 It defines:
14    HTML_HELP_COMPILER     : full path to the Compiler (hhc.exe)
15    HTML_HELP_INCLUDE_PATH : include path to the API (htmlhelp.h)
16    HTML_HELP_LIBRARY      : full path to the library (htmlhelp.lib)
17 #]=======================================================================]
19 if(WIN32)
21   find_program(HTML_HELP_COMPILER
22     NAMES hhc
23     PATHS
24       "[HKEY_CURRENT_USER\\Software\\Microsoft\\HTML Help Workshop;InstallDir]"
25     PATH_SUFFIXES "HTML Help Workshop"
26     )
28   get_filename_component(HTML_HELP_COMPILER_PATH "${HTML_HELP_COMPILER}" PATH)
30   find_path(HTML_HELP_INCLUDE_PATH
31     NAMES htmlhelp.h
32     PATHS
33       "${HTML_HELP_COMPILER_PATH}/include"
34       "[HKEY_CURRENT_USER\\Software\\Microsoft\\HTML Help Workshop;InstallDir]/include"
35     PATH_SUFFIXES "HTML Help Workshop/include"
36     )
38   find_library(HTML_HELP_LIBRARY
39     NAMES htmlhelp
40     PATHS
41       "${HTML_HELP_COMPILER_PATH}/lib"
42       "[HKEY_CURRENT_USER\\Software\\Microsoft\\HTML Help Workshop;InstallDir]/lib"
43     PATH_SUFFIXES "HTML Help Workshop/lib"
44     )
46   mark_as_advanced(
47     HTML_HELP_COMPILER
48     HTML_HELP_INCLUDE_PATH
49     HTML_HELP_LIBRARY
50     )
52 endif()