aboutsummaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2018-04-23 08:31:25 -0700
committerAnders Broman <a.broman58@gmail.com>2018-04-24 03:45:15 +0000
commit631fec3e1bdb069466da95ebfc0f0b3de5706415 (patch)
tree3db2d54cd90bcf7bab41905dac69c3921ec80621 /cmake
parentf70a7bf09b3b7fd5b835bce979535e75b381688a (diff)
CMake: Doxygen and API reference target updates.
The DOXYGEN_* variables which we use to create doxygen.cfg are native paths and are not compatible with Cygwin. We could try to make them compatible, but given that we're trying to migrate away from Cygwin set "DOXYGEN_EXECUTABLE" to "DOXYGEN_EXECUTABLE-NOTFOUND" if "cyg" is anywhere in its path. Add the wsar_html* targets to "Docs" and exclude them from Visual Studio's default build. Change-Id: Id23a3c43a9f4f1edb2d827bbf36a3a7eb64f0212 Reviewed-on: https://code.wireshark.org/review/27100 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/modules/FindDOXYGEN.cmake16
1 files changed, 11 insertions, 5 deletions
diff --git a/cmake/modules/FindDOXYGEN.cmake b/cmake/modules/FindDOXYGEN.cmake
index 23a99fdcc6..381048989b 100644
--- a/cmake/modules/FindDOXYGEN.cmake
+++ b/cmake/modules/FindDOXYGEN.cmake
@@ -1,21 +1,27 @@
#
-# - Find unix commands from cygwin
-# This module looks for some usual Unix commands.
+# - Find Doxygen
+# This module looks for a native (non-Cygwin) Doxygen.
#
-include( FindCygwin )
-
find_program( DOXYGEN_EXECUTABLE
NAMES
doxygen
PATHS
- ${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
+# We set various paths in doxygen.cfg via configure_file(). These are
+# native system paths which aren't compatible with Cygwin's Doxygen.
+string(TOLOWER ${DOXYGEN_EXECUTABLE} _de_lower)
+if(${_de_lower} MATCHES "cyg")
+ set(_ignore_reason "Cygwin Doxygen found at ${DOXYGEN_EXECUTABLE}. Ignoring.")
+ message(STATUS ${_ignore_reason})
+ set(DOXYGEN_EXECUTABLE DOXYGEN_EXECUTABLE-NOTFOUND CACHE FILEPATH ${_ignore_reason} FORCE)
+endif()
+
include( FindPackageHandleStandardArgs )
find_package_handle_standard_args( DOXYGEN DEFAULT_MSG DOXYGEN_EXECUTABLE )