From 90473be159f5fb6645f13195adba44525215f152 Mon Sep 17 00:00:00 2001 From: Bill Somerville Date: Mon, 21 Apr 2014 11:38:17 +0000 Subject: [PATCH] Make manpage generation optional for casual builders. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4056 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- CMakeLists.txt | 6 ++++-- debian/CMakeLists.txt | 2 +- manpages/CMakeLists.txt | 11 ++++++++++- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6f5460f9b..db82ee2b3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -57,7 +57,7 @@ option (WSJT_TRACE_CAT_POLLS "Debugging option that turns on CAT diagnostics dur option (WSJT_HAMLIB_TRACE "Debugging option that turns on full Hamlib internal diagnostics.") option (WSJT_STANDARD_FILE_LOCATIONS "All non-installation files located in \"Standard\" platfom specific locations." ON) option (WSJT_SOFT_KEYING "Apply a ramp to CW keying envelope to reduce transients." ON) - +option (WSJT_SKIP_MANPAGES "Skip *nix manpage generation") # # install locations @@ -623,7 +623,9 @@ add_executable (wsjtx WIN32 MACOSX_BUNDLE qt5_use_modules (wsjtx Widgets OpenGL Network Multimedia) if (UNIX) - add_subdirectory (manpages) + if (NOT WSJT_SKIP_MANPAGES) + add_subdirectory (manpages) + endif (NOT WSJT_SKIP_MANPAGES) if (NOT APPLE) add_subdirectory (debian) endif (NOT APPLE) diff --git a/debian/CMakeLists.txt b/debian/CMakeLists.txt index b1bb7a425..ef8849d2e 100644 --- a/debian/CMakeLists.txt +++ b/debian/CMakeLists.txt @@ -19,7 +19,7 @@ configure_file ( @ONLY) add_custom_target (debian - COMMAND ${GZIP_EXECUTABLE} -9 --force changelog + COMMAND ${GZIP_EXECUTABLE} -cf9 changelog > changelog.gz DEPENDS changelog.in WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMENT "Compressing Debian changelog" diff --git a/manpages/CMakeLists.txt b/manpages/CMakeLists.txt index de2e1dbd3..dea72e692 100644 --- a/manpages/CMakeLists.txt +++ b/manpages/CMakeLists.txt @@ -5,7 +5,16 @@ set (ASCIIDOC_MANS find_program (A2X_EXECUTABLE NAMES a2x a2x.py) if (NOT A2X_EXECUTABLE) if (NOT CMAKE_BUILD_TYPE STREQUAL "Debug") - message (SEND_ERROR "Failed to find a2x which is required for release builds on *nix platforms.") + message (SEND_ERROR " +Failed to find a2x which is an optional requirement for non-debug +builds on *nix platforms. + +You can choose to skip manpage generation and this error by setting +the CMake option WSJT_SKIP_MANPAGES to ON. This option is designed for +those that are building for their own use, packages should not opt to +skip manpage generation since package building requires the +manpages.") + else (NOT CMAKE_BUILD_TYPE STREQUAL "Debug") message (WARNING "Failed to find a2x skipping manpage generation.") endif (NOT CMAKE_BUILD_TYPE STREQUAL "Debug")