2010-01-21 05:28:32 +01:00
|
|
|
|
|
|
|
# We use a two-step process to generate documentation from asciidoc files.
|
|
|
|
#
|
|
|
|
# First, we use asciidoc/a2x to process the asciidoc files into .1.in and
|
|
|
|
# .html.in files (see the asciidoc-helper.sh script). These are the same as
|
|
|
|
# the regular .1 and .html files, except that they still have some autoconf
|
|
|
|
# variables set in them.
|
|
|
|
#
|
|
|
|
# Second, we use config.status to turn .1.in files into .1 files and
|
|
|
|
# .html.in files into .html files.
|
|
|
|
#
|
|
|
|
# We do the steps in this order so that we can ship the .*.in files as
|
|
|
|
# part of the source distribution, so that people without asciidoc can
|
|
|
|
# just use the .1 and .html files.
|
|
|
|
|
2010-03-01 03:17:48 +01:00
|
|
|
if USE_ASCIIDOC
|
2010-09-30 22:44:11 +02:00
|
|
|
if USE_FW_HELPER
|
|
|
|
asciidoc_files = tor tor-gencert tor-resolve torify tor-fw-helper
|
|
|
|
else
|
2010-01-19 14:53:38 +01:00
|
|
|
asciidoc_files = tor tor-gencert tor-resolve torify
|
2010-09-30 22:44:11 +02:00
|
|
|
endif
|
2010-08-09 21:44:21 +02:00
|
|
|
html_in = $(asciidoc_files:=.html.in)
|
|
|
|
man_in = $(asciidoc_files:=.1.in)
|
|
|
|
txt_in = $(asciidoc_files:=.1.txt)
|
|
|
|
nodist_man_MANS = $(asciidoc_files:=.1)
|
|
|
|
doc_DATA = $(asciidoc_files:=.html)
|
2010-03-01 03:17:48 +01:00
|
|
|
else
|
|
|
|
asciidoc_files =
|
2010-08-09 21:44:21 +02:00
|
|
|
html_in =
|
|
|
|
man_in =
|
|
|
|
txt_in =
|
|
|
|
nodist_man_MANS =
|
|
|
|
doc_DATA =
|
2010-03-01 03:17:48 +01:00
|
|
|
endif
|
2010-01-18 22:15:38 +01:00
|
|
|
|
2010-02-27 16:27:44 +01:00
|
|
|
EXTRA_DIST = HACKING asciidoc-helper.sh \
|
2010-08-13 23:18:45 +02:00
|
|
|
$(html_in) $(man_in) $(txt_in) \
|
2010-10-11 18:47:14 +02:00
|
|
|
tor-rpm-creation.txt \
|
2010-01-19 04:35:04 +01:00
|
|
|
tor-win32-mingw-creation.txt
|
2003-10-07 18:30:05 +02:00
|
|
|
|
2010-01-28 08:59:20 +01:00
|
|
|
docdir = @docdir@
|
|
|
|
|
2010-01-18 22:15:38 +01:00
|
|
|
asciidoc_product = $(nodist_man_MANS) $(doc_DATA)
|
2004-08-06 21:54:29 +02:00
|
|
|
|
2010-01-27 21:05:01 +01:00
|
|
|
SUBDIRS = spec
|
2004-08-06 21:54:29 +02:00
|
|
|
|
2010-01-27 20:09:19 +01:00
|
|
|
DIST_SUBDIRS = spec
|
2006-03-31 06:23:41 +02:00
|
|
|
|
2010-01-18 22:15:38 +01:00
|
|
|
# Generate the html documentation from asciidoc, but don't do
|
|
|
|
# machine-specific replacements yet
|
|
|
|
$(html_in) :
|
2010-02-27 17:06:06 +01:00
|
|
|
$(top_srcdir)/doc/asciidoc-helper.sh html @ASCIIDOC@ $(top_srcdir)/doc/$@
|
2010-01-18 22:15:38 +01:00
|
|
|
|
2010-01-19 14:53:38 +01:00
|
|
|
tor.html.in : tor.1.txt
|
2010-01-19 04:35:04 +01:00
|
|
|
torify.html.in : torify.1.txt
|
2010-01-18 08:42:48 +01:00
|
|
|
tor-gencert.html.in : tor-gencert.1.txt
|
2010-01-19 14:51:10 +01:00
|
|
|
tor-resolve.html.in : tor-resolve.1.txt
|
2010-09-30 22:44:11 +02:00
|
|
|
tor-fw-helper.html.in : tor-fw-helper.1.txt
|
2010-01-18 08:42:48 +01:00
|
|
|
|
2010-01-18 22:15:38 +01:00
|
|
|
# Generate the manpage from asciidoc, but don't do
|
|
|
|
# machine-specific replacements yet
|
|
|
|
$(man_in) :
|
2010-02-27 17:06:06 +01:00
|
|
|
$(top_srcdir)/doc/asciidoc-helper.sh man @A2X@ $(top_srcdir)/doc/$@
|
2010-01-18 22:15:38 +01:00
|
|
|
|
2010-01-19 14:53:38 +01:00
|
|
|
tor.1.in : tor.1.txt
|
2010-01-19 04:35:04 +01:00
|
|
|
torify.1.in : torify.1.txt
|
2010-01-18 08:42:48 +01:00
|
|
|
tor-gencert.1.in : tor-gencert.1.txt
|
2010-01-19 14:51:10 +01:00
|
|
|
tor-resolve.1.in : tor-resolve.1.txt
|
2010-09-30 22:44:11 +02:00
|
|
|
tor-fw-helper.1.in : tor-fw-helper.1.txt
|
2010-01-18 08:42:48 +01:00
|
|
|
|
2010-01-18 22:15:38 +01:00
|
|
|
# use ../config.status to swap all machine-specific magic strings
|
|
|
|
# in the asciidoc with their replacements.
|
|
|
|
$(asciidoc_product) :
|
2010-01-21 05:32:27 +01:00
|
|
|
if test -e $(top_srcdir)/doc/$@.in && ! test -e ./$@.in ; then \
|
|
|
|
cp $(top_srcdir)/doc/$@.in .; \
|
|
|
|
fi
|
2010-01-18 22:15:38 +01:00
|
|
|
../config.status --file=$@;
|
2010-01-18 08:42:48 +01:00
|
|
|
|
2010-01-19 14:53:38 +01:00
|
|
|
tor.1 : tor.1.in
|
2010-01-19 04:35:04 +01:00
|
|
|
torify.1 : torify.1.in
|
2010-01-18 08:42:48 +01:00
|
|
|
tor-gencert.1 : tor-gencert.1.in
|
2010-01-19 14:51:10 +01:00
|
|
|
tor-resolve.1 : tor-resolve.1.in
|
2010-09-30 22:44:11 +02:00
|
|
|
tor-fw-helper.1 : tor-fw-helper.1.in
|
2010-01-19 14:53:38 +01:00
|
|
|
tor.html : tor.html.in
|
2010-01-19 04:35:04 +01:00
|
|
|
torify.html : torify.html.in
|
2010-01-18 08:42:48 +01:00
|
|
|
tor-gencert.html : tor-gencert.html.in
|
2010-01-19 14:51:10 +01:00
|
|
|
tor-resolve.html : tor-resolve.html.in
|
2010-09-30 22:44:11 +02:00
|
|
|
tor-fw-helper.html : tor-fw-helper.html.in
|
2010-01-27 20:23:13 +01:00
|
|
|
|
2010-08-03 00:48:59 +02:00
|
|
|
CLEANFILES = $(asciidoc_product) config.log
|
2010-01-27 20:23:13 +01:00
|
|
|
DISTCLEANFILES = $(html_in) $(man_in)
|