aboutsummaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2015-03-21 11:57:01 +0100
committerAnders Broman <a.broman58@gmail.com>2015-03-25 07:08:52 +0000
commit68698db8ccec8733929752c4b13da71dcad6213e (patch)
tree99f299c4296e94f78038fc8666d987e81a639974 /configure.ac
parent83b6338673d1f1e0035c34021199b90730da73fd (diff)
Always use html2text.py for FAQ, improve output
A recent commit broke compilation with Python 3. The original author of html2text.py is deceased and the fork has increased the number of files for this "simple" helper. The html2text.py script in this patch was rewritten and its output matches with lynx (except for a few newlines around lists). This means that indentation has been added for headings, paragraphs and lists. Also, since it was written from scratch, a new license could be chosen that matches Wireshark. Since now the in-tree html2text.py script provides nicer output, remove detection of the alternative programs (elinks, links). lynx/w3m is somehow still necessary for asciidoc though. (I also looked into reusing html2text.py for the release notes to replace asciidoc, but the --format=html output produces different output (HTML adds a ToC and section numbers). For now still require lynx for release notes) Tested with Python 2.6.6, 2.7.9, 3.2.6 and 3.4.3 under LC_ALL=C and LC_ALL=en_US.UTF-8 on Linux. Tested reading from stdin and file, writing to file, pipe and tty. Tested with cmake (Ninja) and autotools on Arch Linux x86_64. Test: # For each $PATH per python version, execute (with varying LC_ALL) help/faq.py -b | tools/html2text.py /dev/stdin | md5sum help/faq.py -b | tools/html2text.py | md5sum help/faq.py -b | tools/html2text.py help/faq.py -b | tools/html2text.py >/dev/null Change-Id: I6409450a3e6c8b010ca082251f9db7358b0cc2fd Reviewed-on: https://code.wireshark.org/review/7779 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac12
1 files changed, 4 insertions, 8 deletions
diff --git a/configure.ac b/configure.ac
index 62fce43336..857e898089 100644
--- a/configure.ac
+++ b/configure.ac
@@ -760,23 +760,19 @@ AC_PATH_PROG(A2X, a2x)
AC_CHECK_PROG(HAVE_A2X, a2x, "yes", "no")
AM_CONDITIONAL(HAVE_A2X, test x$HAVE_A2X = xyes)
-# Want to control a tape drive? Use mt. Want to convert HTML to text?
-# Uhhhhh... elinks? lynx? w3m? pandoc? html2text?
-AC_PATH_PROG(ELINKS, elinks)
-AC_CHECK_PROG(HAVE_ELINKS, elinks, "yes", "no")
-AM_CONDITIONAL(HAVE_ELINKS, test x$HAVE_ELINKS = xyes)
-
# Check for fop (translate .fo to e.g. pdf)
AC_PATH_PROG(FOP, fop)
AC_CHECK_PROG(HAVE_FOP, fop, "yes", "no")
AM_CONDITIONAL(HAVE_FOP, test x$HAVE_FOP = xyes)
-# Check for lynx (html -> text)
+# TODO: HAVE_LYNX and HAVE_W3M are unused. Maybe require one of them
+# to be found when a2x is enabled? Otherwise it will fail later...
+# Check for lynx (asciidoc text format from html)
AC_PATH_PROG(LYNX, lynx)
AC_CHECK_PROG(HAVE_LYNX, lynx, "yes", "no")
AM_CONDITIONAL(HAVE_LYNX, test x$HAVE_LYNX = xyes)
-# Check for w3m (html -> text)
+# Check for w3m (asciidoc text format from html)
AC_PATH_PROG(W3M, w3m)
AC_CHECK_PROG(HAVE_W3M, w3m, "yes", "no")
AM_CONDITIONAL(HAVE_W3M, test x$HAVE_W3M = xyes)