Generate man pages and completions by default if possible
authorTeemu Murtola <teemu.murtola@gmail.com>
Sun, 21 Sep 2014 13:40:19 +0000 (16:40 +0300)
committerGerrit Code Review <gerrit@gerrit.gromacs.org>
Tue, 23 Sep 2014 09:03:24 +0000 (11:03 +0200)
commit89cfb2612760b1abf9cad7f94aa813d0a77d9c2b
tree45b3000e6155522060e427a7b3bd5bfe1de335ae
parente60fe9d2897fa123496a714c65f4ee4c6a860053
Generate man pages and completions by default if possible

Make GMX_BUILD_HELP a tristate option to support three different use
cases:
 - OFF: never build anything (default for source distributions, where
   everything is already generated)
 - ON: always build everything as part of the ALL target, give an error
   if anything fails.
 - AUTO: try to build man pages and completions as part of the ALL
   target, and install the result if successful; if it fails, some
   warnings will be given, but build will still be otherwise functional.
This allows making the default AUTO for builds from a git repo, making
the shell completions and man pages work automatically also in such
cases (as long as the build host can run the compiled executables).

HTML help is generated only with GMX_BUILD_HELP=ON, since it is
currently in somewhat of a flux what will happen to it, and most people
will not notice it missing, either.

Change-Id: Id7a69b1b912381a2f1ad3678b82cbaa01cba8479
CMakeLists.txt
CPackInit.cmake
cmake/gmxOptionUtilities.cmake
docs/man/BuildManPages.cmake [new file with mode: 0644]
docs/man/CMakeLists.txt
docs/old-html/BuildHtmlHelp.cmake
docs/old-html/CMakeLists.txt
src/programs/BuildCompletions.cmake [new file with mode: 0644]
src/programs/CMakeLists.txt