diff options
author | rl1987 <rl1987@sdf.lonestar.org> | 2019-06-16 20:18:30 +0300 |
---|---|---|
committer | rl1987 <rl1987@sdf.lonestar.org> | 2019-06-16 20:21:30 +0300 |
commit | 66a15013fa5abf3c4d3345ca29c22ad13d45e22f (patch) | |
tree | 89b0aaf31ad6b6ded4e58ae195a985e5531c8684 | |
parent | 319ce225815897d8626e85037ee203c4de634405 (diff) | |
download | tor-66a15013fa5abf3c4d3345ca29c22ad13d45e22f.tar.gz tor-66a15013fa5abf3c4d3345ca29c22ad13d45e22f.zip |
Allow excluding documentation from the build
-rw-r--r-- | changes/ticket19381 | 4 | ||||
-rw-r--r-- | configure.ac | 8 | ||||
-rw-r--r-- | doc/include.am | 23 |
3 files changed, 31 insertions, 4 deletions
diff --git a/changes/ticket19381 b/changes/ticket19381 new file mode 100644 index 0000000000..ee51e2a3e2 --- /dev/null +++ b/changes/ticket19381 @@ -0,0 +1,4 @@ + o Minor features (build system): + - Add --disable-manpage and --disable-html-manual options to configure + script. This will enable shortening build times by not building + documentation. Resolves issue 19381. diff --git a/configure.ac b/configure.ac index 75ca03d7d8..9ec123f51e 100644 --- a/configure.ac +++ b/configure.ac @@ -105,6 +105,12 @@ if test "$enable_memory_sentinels" = "no"; then [Defined if we're turning off memory safety code to look for bugs]) fi +AC_ARG_ENABLE(manpage, + AS_HELP_STRING(--disable-manpage, [Disable manpage generation.])) + +AC_ARG_ENABLE(html-manual, + AS_HELP_STRING(--disable-html-manual, [Disable HTML documentation.])) + AC_ARG_ENABLE(asciidoc, AS_HELP_STRING(--disable-asciidoc, [don't use asciidoc (disables building of manpages)]), [case "${enableval}" in @@ -299,6 +305,8 @@ AC_PATH_PROG([ASCIIDOC], [asciidoc], none) AC_PATH_PROGS([A2X], [a2x a2x.py], none) AM_CONDITIONAL(USE_ASCIIDOC, test "x$asciidoc" = "xtrue") +AM_CONDITIONAL(BUILD_MANPAGE, [test "x$enable_manpage" != "xno"]) +AM_CONDITIONAL(BUILD_HTML_DOCS, [test "x$enable_html_manual" != "xno"]) AM_PROG_CC_C_O AC_PROG_CC_C99 diff --git a/doc/include.am b/doc/include.am index 0a123aae11..a9d3fa1c98 100644 --- a/doc/include.am +++ b/doc/include.am @@ -15,17 +15,32 @@ all_mans = doc/tor doc/tor-gencert doc/tor-resolve doc/torify doc/tor-print-ed-signing-cert if USE_ASCIIDOC -nodist_man1_MANS = $(all_mans:=.1) -doc_DATA = $(all_mans:=.html) +txt_in = $(all_mans:=.1.txt) + +if BUILD_HTML_DOCS html_in = $(all_mans:=.html.in) +doc_DATA = $(all_mans:=.html) +else +html_in = +doc_DATA = +endif + +if BUILD_MANPAGE +nodist_man1_MANS = $(all_mans:=.1) man_in = $(all_mans:=.1.in) -txt_in = $(all_mans:=.1.txt) else +nodist_man1_MANS = +man_in = +endif + +else + html_in = +doc_DATA = man_in = txt_in = nodist_man1_MANS = -doc_DATA = + endif EXTRA_DIST+= doc/asciidoc-helper.sh \ |