From: Kefu Chai Date: Mon, 4 May 2015 16:26:31 +0000 (+0800) Subject: configure.ac: add an option: --with-man-pages X-Git-Tag: v9.0.2~239^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=5b2357e663e603b23584b5e0114eb498d4ad6853;p=ceph.git configure.ac: add an option: --with-man-pages * do not require sphinx-build if --without-man-pages * dist rst files for man pages * build and dist .8 files if sphinx-build is found Signed-off-by: Kefu Chai --- diff --git a/configure.ac b/configure.ac index 4b504008e28c..b21ad4482d58 100644 --- a/configure.ac +++ b/configure.ac @@ -21,8 +21,16 @@ if test -d ".git" ; then fi AC_MSG_NOTICE([RPM_RELEASE='$RPM_RELEASE']) -AC_CHECK_PROGS(SPHINX_BUILD, sphinx-1.0-build sphinx-build, no) -AM_CONDITIONAL(HAS_SPHINX_BUILD, test x"$SPHINX_BUILD" != "xno") +AC_ARG_WITH([man-pages], + [AS_HELP_STRING([--with-man-pages], [build man pages])], + [], + [with_man_pages=check]) +AS_IF([test "x$with_man_pages" != "xno"], + [AC_CHECK_PROGS(SPHINX_BUILD, sphinx-1.0-build sphinx-build) + AS_IF([test -z "$SPHINX_BUILD" && \ + test "x$with_man_pages" = "xyes"], + [AC_MSG_ERROR([sphinx-build not found (python-sphinx)])])]) +AM_CONDITIONAL(WITH_MAN_PAGES, test -n "$SPHINX_BUILD") AC_CONFIG_MACRO_DIR([m4]) diff --git a/doc/.gitignore b/doc/.gitignore index 0c7c74746ae9..aca7518a3ee0 100644 --- a/doc/.gitignore +++ b/doc/.gitignore @@ -1,2 +1,3 @@ /overview.png /object_store.png +/Makefile diff --git a/man/Makefile.am b/man/Makefile.am index 2298866efe6b..7d1159edff0c 100644 --- a/man/Makefile.am +++ b/man/Makefile.am @@ -4,7 +4,7 @@ EXTRA_DIST = conf.py dist_man_MANS = -if HAS_SPHINX_BUILD +if WITH_MAN_PAGES if ENABLE_CLIENT include Makefile-client.am endif