|
12 | 12 | AC_DEFUN([OPAL_SETUP_SPHINX],[
|
13 | 13 | OPAL_VAR_SCOPE_PUSH([summary_msg])
|
14 | 14 |
|
| 15 | + # This option is probably only helpful to developers: have |
| 16 | + # configure fail if Sphinx is not found (i.e., if you don't have |
| 17 | + # the ability to use Sphinx to build the HTML docs and man pages). |
| 18 | + AC_ARG_ENABLE([sphinx], |
| 19 | + [AS_HELP_STRING([--enable-sphinx], |
| 20 | + [Force configure to fail if Sphinx is not found (Sphinx is used to build the Open MPI and OpenSHMEM HTML docs and man pages). This option is likely only useful for Open MPI developers; end users who are building from Open MPI distribution tarballs do ***not*** need to have Sphinx installed])]) |
| 21 | + |
15 | 22 | # Quick check to see if we have already-built docs (e.g., if we're
|
16 | 23 | # in a tarball vs. a fresh git clone).
|
17 | 24 | AC_MSG_CHECKING([if pre-built docs are available])
|
@@ -52,6 +59,13 @@ AC_DEFUN([OPAL_SETUP_SPHINX],[
|
52 | 59 | [summary_msg="installing packaged docs"],
|
53 | 60 | [summary_msg="no documentation available"])])
|
54 | 61 |
|
| 62 | + # If --enable-sphinx was specified and we did not find Sphinx, |
| 63 | + # abort. This is likely only useful to prevent "oops!" moments |
| 64 | + # from Open MPI developers. |
| 65 | + AS_IF([test -z "$SPHINX_BUILD" && test "$enable_sphinx" = "yes"], |
| 66 | + [AC_MSG_WARN([Sphinx was not found, but --enable-sphinx was specified]) |
| 67 | + AC_MSG_ERROR([Cannot continue])]) |
| 68 | + |
55 | 69 | OPAL_SUMMARY_ADD([Miscellaneous], [HTML docs and man pages], [],
|
56 | 70 | [$summary_msg])
|
57 | 71 |
|
|
0 commit comments