2013-02-01 19:41:14 +00:00
|
|
|
# Guard against environment variables
|
|
|
|
MAN1_TXT =
|
|
|
|
MAN5_TXT =
|
|
|
|
MAN7_TXT =
|
2014-01-27 17:04:32 +00:00
|
|
|
TECH_DOCS =
|
|
|
|
ARTICLES =
|
|
|
|
SP_ARTICLES =
|
2014-10-10 21:25:36 +00:00
|
|
|
OBSOLETE_HTML =
|
2013-02-01 19:41:14 +00:00
|
|
|
|
2019-04-18 13:16:44 +00:00
|
|
|
-include GIT-EXCLUDED-PROGRAMS
|
|
|
|
|
2013-02-01 19:41:14 +00:00
|
|
|
MAN1_TXT += $(filter-out \
|
2019-04-18 13:16:44 +00:00
|
|
|
$(patsubst %,%.txt,$(EXCLUDED_PROGRAMS)) \
|
2013-02-01 19:41:14 +00:00
|
|
|
$(addsuffix .txt, $(ARTICLES) $(SP_ARTICLES)), \
|
|
|
|
$(wildcard git-*.txt))
|
|
|
|
MAN1_TXT += git.txt
|
|
|
|
MAN1_TXT += gitk.txt
|
|
|
|
MAN1_TXT += gitweb.txt
|
|
|
|
|
|
|
|
MAN5_TXT += gitattributes.txt
|
|
|
|
MAN5_TXT += githooks.txt
|
|
|
|
MAN5_TXT += gitignore.txt
|
|
|
|
MAN5_TXT += gitmodules.txt
|
|
|
|
MAN5_TXT += gitrepository-layout.txt
|
|
|
|
MAN5_TXT += gitweb.conf.txt
|
|
|
|
|
|
|
|
MAN7_TXT += gitcli.txt
|
|
|
|
MAN7_TXT += gitcore-tutorial.txt
|
2011-12-10 10:31:38 +00:00
|
|
|
MAN7_TXT += gitcredentials.txt
|
2013-02-01 19:41:14 +00:00
|
|
|
MAN7_TXT += gitcvs-migration.txt
|
|
|
|
MAN7_TXT += gitdiffcore.txt
|
2014-10-10 21:25:37 +00:00
|
|
|
MAN7_TXT += giteveryday.txt
|
2013-02-01 19:41:14 +00:00
|
|
|
MAN7_TXT += gitglossary.txt
|
|
|
|
MAN7_TXT += gitnamespaces.txt
|
2019-03-25 21:41:36 +00:00
|
|
|
MAN7_TXT += gitremote-helpers.txt
|
2013-02-01 19:41:14 +00:00
|
|
|
MAN7_TXT += gitrevisions.txt
|
2017-06-22 21:01:49 +00:00
|
|
|
MAN7_TXT += gitsubmodules.txt
|
2013-02-01 19:41:14 +00:00
|
|
|
MAN7_TXT += gittutorial-2.txt
|
|
|
|
MAN7_TXT += gittutorial.txt
|
|
|
|
MAN7_TXT += gitworkflows.txt
|
2005-05-10 21:32:39 +00:00
|
|
|
|
2019-01-07 19:21:12 +00:00
|
|
|
ifdef MAN_FILTER
|
|
|
|
MAN_TXT = $(filter $(MAN_FILTER),$(MAN1_TXT) $(MAN5_TXT) $(MAN7_TXT))
|
|
|
|
else
|
2007-12-10 09:15:57 +00:00
|
|
|
MAN_TXT = $(MAN1_TXT) $(MAN5_TXT) $(MAN7_TXT)
|
2019-01-07 19:21:12 +00:00
|
|
|
MAN_FILTER = $(MAN_TXT)
|
|
|
|
endif
|
|
|
|
|
2013-06-16 17:13:00 +00:00
|
|
|
MAN_XML = $(patsubst %.txt,%.xml,$(MAN_TXT))
|
|
|
|
MAN_HTML = $(patsubst %.txt,%.html,$(MAN_TXT))
|
2017-12-09 22:07:57 +00:00
|
|
|
GIT_MAN_REF = master
|
2007-12-10 09:15:57 +00:00
|
|
|
|
2014-10-10 21:25:37 +00:00
|
|
|
OBSOLETE_HTML += everyday.html
|
2014-10-10 21:25:36 +00:00
|
|
|
OBSOLETE_HTML += git-remote-helpers.html
|
2005-08-30 20:51:01 +00:00
|
|
|
|
2014-01-27 17:04:32 +00:00
|
|
|
ARTICLES += howto-index
|
2006-03-05 09:36:33 +00:00
|
|
|
ARTICLES += git-tools
|
2009-11-08 15:09:47 +00:00
|
|
|
ARTICLES += git-bisect-lk2009
|
2005-08-30 20:51:01 +00:00
|
|
|
# with their own formatting rules.
|
2014-01-27 17:04:32 +00:00
|
|
|
SP_ARTICLES += user-manual
|
2012-12-21 18:05:28 +00:00
|
|
|
SP_ARTICLES += howto/new-command
|
2012-01-17 22:52:24 +00:00
|
|
|
SP_ARTICLES += howto/revert-branch-rebase
|
|
|
|
SP_ARTICLES += howto/using-merge-subtree
|
|
|
|
SP_ARTICLES += howto/using-signed-tag-in-pull-request
|
2012-10-23 17:58:04 +00:00
|
|
|
SP_ARTICLES += howto/use-git-daemon
|
|
|
|
SP_ARTICLES += howto/update-hook-example
|
|
|
|
SP_ARTICLES += howto/setup-git-server-over-http
|
|
|
|
SP_ARTICLES += howto/separating-topic-branches
|
|
|
|
SP_ARTICLES += howto/revert-a-faulty-merge
|
|
|
|
SP_ARTICLES += howto/recover-corrupted-blob-object
|
2013-10-25 07:55:02 +00:00
|
|
|
SP_ARTICLES += howto/recover-corrupted-object-harder
|
2012-10-23 17:58:04 +00:00
|
|
|
SP_ARTICLES += howto/rebuild-from-update-hook
|
|
|
|
SP_ARTICLES += howto/rebase-from-internal-branch
|
2014-05-09 06:08:41 +00:00
|
|
|
SP_ARTICLES += howto/keep-canonical-history-correct
|
2012-10-23 17:58:04 +00:00
|
|
|
SP_ARTICLES += howto/maintain-git
|
2007-11-25 07:48:04 +00:00
|
|
|
API_DOCS = $(patsubst %.txt,%,$(filter-out technical/api-index-skel.txt technical/api-index.txt, $(wildcard technical/api-*.txt)))
|
|
|
|
SP_ARTICLES += $(API_DOCS)
|
2012-10-23 17:58:04 +00:00
|
|
|
|
2019-05-17 19:07:02 +00:00
|
|
|
TECH_DOCS += MyFirstContribution
|
2019-10-11 23:55:54 +00:00
|
|
|
TECH_DOCS += MyFirstObjectWalk
|
2017-11-12 22:07:18 +00:00
|
|
|
TECH_DOCS += SubmittingPatches
|
2017-09-28 04:43:21 +00:00
|
|
|
TECH_DOCS += technical/hash-function-transition
|
2014-01-27 17:04:32 +00:00
|
|
|
TECH_DOCS += technical/http-protocol
|
2014-01-26 12:57:19 +00:00
|
|
|
TECH_DOCS += technical/index-format
|
2018-01-25 18:53:24 +00:00
|
|
|
TECH_DOCS += technical/long-running-process-protocol
|
2018-11-20 18:04:54 +00:00
|
|
|
TECH_DOCS += technical/multi-pack-index
|
2012-10-23 17:58:04 +00:00
|
|
|
TECH_DOCS += technical/pack-format
|
|
|
|
TECH_DOCS += technical/pack-heuristics
|
|
|
|
TECH_DOCS += technical/pack-protocol
|
2018-08-14 22:28:46 +00:00
|
|
|
TECH_DOCS += technical/partial-clone
|
2012-10-23 17:58:04 +00:00
|
|
|
TECH_DOCS += technical/protocol-capabilities
|
|
|
|
TECH_DOCS += technical/protocol-common
|
2018-03-15 17:31:19 +00:00
|
|
|
TECH_DOCS += technical/protocol-v2
|
2012-10-23 17:58:04 +00:00
|
|
|
TECH_DOCS += technical/racy-git
|
|
|
|
TECH_DOCS += technical/send-pack-pipeline
|
|
|
|
TECH_DOCS += technical/shallow
|
2016-06-17 07:46:08 +00:00
|
|
|
TECH_DOCS += technical/signature-format
|
2012-10-23 17:58:04 +00:00
|
|
|
TECH_DOCS += technical/trivial-merge
|
|
|
|
SP_ARTICLES += $(TECH_DOCS)
|
2007-11-25 07:48:04 +00:00
|
|
|
SP_ARTICLES += technical/api-index
|
2005-08-30 20:51:01 +00:00
|
|
|
|
2019-01-07 19:21:12 +00:00
|
|
|
ARTICLES_HTML += $(patsubst %,%.html,$(ARTICLES) $(SP_ARTICLES))
|
|
|
|
HTML_FILTER ?= $(ARTICLES_HTML) $(OBSOLETE_HTML)
|
|
|
|
DOC_HTML = $(MAN_HTML) $(filter $(HTML_FILTER),$(ARTICLES_HTML) $(OBSOLETE_HTML))
|
2005-08-30 06:09:22 +00:00
|
|
|
|
2019-01-07 19:21:12 +00:00
|
|
|
DOC_MAN1 = $(patsubst %.txt,%.1,$(filter $(MAN_FILTER),$(MAN1_TXT)))
|
|
|
|
DOC_MAN5 = $(patsubst %.txt,%.5,$(filter $(MAN_FILTER),$(MAN5_TXT)))
|
|
|
|
DOC_MAN7 = $(patsubst %.txt,%.7,$(filter $(MAN_FILTER),$(MAN7_TXT)))
|
2005-05-22 17:44:15 +00:00
|
|
|
|
2013-06-16 17:13:00 +00:00
|
|
|
prefix ?= $(HOME)
|
|
|
|
bindir ?= $(prefix)/bin
|
|
|
|
htmldir ?= $(prefix)/share/doc/git-doc
|
2013-06-16 17:13:01 +00:00
|
|
|
infodir ?= $(prefix)/share/info
|
2013-06-16 17:13:00 +00:00
|
|
|
pdfdir ?= $(prefix)/share/doc/git-doc
|
|
|
|
mandir ?= $(prefix)/share/man
|
|
|
|
man1dir = $(mandir)/man1
|
|
|
|
man5dir = $(mandir)/man5
|
|
|
|
man7dir = $(mandir)/man7
|
|
|
|
# DESTDIR =
|
2005-07-15 01:21:57 +00:00
|
|
|
|
2012-09-19 17:06:37 +00:00
|
|
|
ASCIIDOC = asciidoc
|
2007-02-13 23:15:05 +00:00
|
|
|
ASCIIDOC_EXTRA =
|
2014-10-11 23:37:35 +00:00
|
|
|
ASCIIDOC_HTML = xhtml11
|
|
|
|
ASCIIDOC_DOCBOOK = docbook
|
|
|
|
ASCIIDOC_CONF = -f asciidoc.conf
|
2014-10-27 00:13:42 +00:00
|
|
|
ASCIIDOC_COMMON = $(ASCIIDOC) $(ASCIIDOC_EXTRA) $(ASCIIDOC_CONF) \
|
2019-09-16 19:00:26 +00:00
|
|
|
-amanversion=$(GIT_VERSION) \
|
|
|
|
-amanmanual='Git Manual' -amansource='Git'
|
2014-10-27 00:13:42 +00:00
|
|
|
TXT_TO_HTML = $(ASCIIDOC_COMMON) -b $(ASCIIDOC_HTML)
|
|
|
|
TXT_TO_XML = $(ASCIIDOC_COMMON) -b $(ASCIIDOC_DOCBOOK)
|
2009-03-27 06:43:58 +00:00
|
|
|
MANPAGE_XSL = manpage-normal.xsl
|
2012-09-19 17:06:37 +00:00
|
|
|
XMLTO = xmlto
|
2009-03-27 06:44:05 +00:00
|
|
|
XMLTO_EXTRA =
|
2013-06-16 17:13:00 +00:00
|
|
|
INSTALL ?= install
|
2007-07-14 17:51:44 +00:00
|
|
|
RM ?= rm -f
|
2011-11-08 18:17:40 +00:00
|
|
|
MAN_REPO = ../../git-manpages
|
|
|
|
HTML_REPO = ../../git-htmldocs
|
2005-07-15 01:21:57 +00:00
|
|
|
|
2013-06-16 17:13:00 +00:00
|
|
|
MAKEINFO = makeinfo
|
|
|
|
INSTALL_INFO = install-info
|
|
|
|
DOCBOOK2X_TEXI = docbook2x-texi
|
|
|
|
DBLATEX = dblatex
|
2013-10-03 19:17:32 +00:00
|
|
|
ASCIIDOC_DBLATEX_DIR = /etc/asciidoc/dblatex
|
2017-01-22 02:41:55 +00:00
|
|
|
DBLATEX_COMMON = -p $(ASCIIDOC_DBLATEX_DIR)/asciidoc-dblatex.xsl -s $(ASCIIDOC_DBLATEX_DIR)/asciidoc-dblatex.sty
|
2007-12-01 02:36:34 +00:00
|
|
|
ifndef PERL_PATH
|
|
|
|
PERL_PATH = /usr/bin/perl
|
|
|
|
endif
|
2007-08-06 10:22:57 +00:00
|
|
|
|
2006-08-31 22:31:08 +00:00
|
|
|
-include ../config.mak.autogen
|
2007-02-28 20:57:42 +00:00
|
|
|
-include ../config.mak
|
2006-08-31 22:31:08 +00:00
|
|
|
|
2009-03-27 06:44:00 +00:00
|
|
|
#
|
|
|
|
# For docbook-xsl ...
|
2010-11-19 17:54:24 +00:00
|
|
|
# -1.68.1, no extra settings are needed?
|
|
|
|
# 1.69.0, set ASCIIDOC_ROFF?
|
2009-04-01 08:50:34 +00:00
|
|
|
# 1.69.1-1.71.0, set DOCBOOK_SUPPRESS_SP?
|
2010-11-19 17:54:24 +00:00
|
|
|
# 1.71.1, set ASCIIDOC_ROFF?
|
2009-03-27 06:44:00 +00:00
|
|
|
# 1.72.0, set DOCBOOK_XSL_172.
|
2010-11-19 17:54:24 +00:00
|
|
|
# 1.73.0-, no extra settings are needed
|
2009-03-27 06:44:00 +00:00
|
|
|
#
|
|
|
|
|
2007-11-14 09:38:46 +00:00
|
|
|
ifdef DOCBOOK_XSL_172
|
2009-03-27 06:44:00 +00:00
|
|
|
ASCIIDOC_EXTRA += -a git-asciidoc-no-roff
|
2008-02-04 22:01:20 +00:00
|
|
|
MANPAGE_XSL = manpage-1.72.xsl
|
2009-03-27 06:44:00 +00:00
|
|
|
else
|
2010-11-19 17:54:24 +00:00
|
|
|
ifndef ASCIIDOC_ROFF
|
2009-03-27 06:44:00 +00:00
|
|
|
# docbook-xsl after 1.72 needs the regular XSL, but will not
|
|
|
|
# pass-thru raw roff codes from asciidoc.conf, so turn them off.
|
|
|
|
ASCIIDOC_EXTRA += -a git-asciidoc-no-roff
|
|
|
|
endif
|
2007-11-14 09:38:46 +00:00
|
|
|
endif
|
2016-05-31 16:20:33 +00:00
|
|
|
ifndef NO_MAN_BOLD_LITERAL
|
2009-03-27 06:44:05 +00:00
|
|
|
XMLTO_EXTRA += -m manpage-bold-literal.xsl
|
|
|
|
endif
|
2009-04-01 08:50:34 +00:00
|
|
|
ifdef DOCBOOK_SUPPRESS_SP
|
|
|
|
XMLTO_EXTRA += -m manpage-suppress-sp.xsl
|
|
|
|
endif
|
2007-11-14 09:38:46 +00:00
|
|
|
|
2009-12-03 08:06:52 +00:00
|
|
|
# Newer DocBook stylesheet emits warning cruft in the output when
|
2009-12-04 17:53:21 +00:00
|
|
|
# this is not set, and if set it shows an absolute link. Older
|
|
|
|
# stylesheets simply ignore this parameter.
|
2009-12-03 19:12:32 +00:00
|
|
|
#
|
2009-12-04 17:53:21 +00:00
|
|
|
# Distros may want to use MAN_BASE_URL=file:///path/to/git/docs/
|
|
|
|
# or similar.
|
|
|
|
ifndef MAN_BASE_URL
|
|
|
|
MAN_BASE_URL = file://$(htmldir)/
|
2009-12-03 19:12:32 +00:00
|
|
|
endif
|
2009-12-04 17:53:21 +00:00
|
|
|
XMLTO_EXTRA += -m manpage-base-url.xsl
|
2009-12-03 02:45:09 +00:00
|
|
|
|
2009-10-22 08:19:06 +00:00
|
|
|
# If your target system uses GNU groff, it may try to render
|
|
|
|
# apostrophes as a "pretty" apostrophe using unicode. This breaks
|
|
|
|
# cut&paste, so you should set GNU_ROFF to force them to be ASCII
|
|
|
|
# apostrophes. Unfortunately does not work with non-GNU roff.
|
|
|
|
ifdef GNU_ROFF
|
|
|
|
XMLTO_EXTRA += -m manpage-quote-apos.xsl
|
|
|
|
endif
|
|
|
|
|
2017-01-22 02:41:56 +00:00
|
|
|
ifdef USE_ASCIIDOCTOR
|
|
|
|
ASCIIDOC = asciidoctor
|
|
|
|
ASCIIDOC_CONF =
|
|
|
|
ASCIIDOC_HTML = xhtml5
|
Documentation: fix build with Asciidoctor 2
Our documentation toolchain has traditionally been built around DocBook
4.5. This version of DocBook is the last DTD-based version of DocBook.
In 2009, DocBook 5 was introduced using namespaces and its syntax is
expressed in RELAX NG, which is more expressive and allows a wider
variety of syntax forms.
Asciidoctor, one of the alternatives for building our documentation,
moved support for DocBook 4.5 out of core in its recent 2.0 release and
now only supports DocBook 5 in the main release. The DocBoook 4.5
converter is still available as a separate component, but this is not
available in most distro packages. This would not be a problem but for
the fact that we use xmlto, which is still stuck in the DocBook 4.5 era.
xmlto performs DTD validation as part of the build process. This is not
problematic for DocBook 4.5, which has a valid DTD, but it clearly
cannot work for DocBook 5, since no DTD can adequately express its full
syntax. In addition, even if xmlto did support RELAX NG validation,
that wouldn't be sufficient because it uses the libxml2-based xmllint to
do so, which has known problems with validating interleaves in RELAX NG.
Fortunately, there's an easy way forward: ask Asciidoctor to use its
DocBook 5 backend and tell xmlto to skip validation. Asciidoctor has
supported DocBook 5 since v0.1.4 in 2013 and xmlto has supported
skipping validation for probably longer than that.
We also need to teach xmlto how to use the namespaced DocBook XSLT
stylesheets instead of the non-namespaced ones it usually uses.
Normally these stylesheets are interchangeable, but the non-namespaced
ones have a bug that causes them not to strip whitespace automatically
from certain elements when namespaces are in use. This results in
additional whitespace at the beginning of list elements, which is
jarring and unsightly.
We can do this by passing a custom stylesheet with the -x option that
simply imports the namespaced stylesheets via a URL. Any system with
support for XML catalogs will automatically look this URL up and
reference a local copy instead without us having to know where this
local copy is located. We know that anyone using xmlto will already
have catalogs set up properly since the DocBook 4.5 DTD used during
validation is also looked up via catalogs. All major Linux
distributions distribute the necessary stylesheets and have built-in
catalog support, and Homebrew does as well, albeit with a requirement to
set an environment variable to enable catalog support.
On the off chance that someone lacks support for catalogs, it is
possible for xmlto (via xmllint) to download the stylesheets from the
URLs in question, although this will likely perform poorly enough to
attract attention. People still have the option of using the prebuilt
documentation that we ship, so happily this should not be an impediment.
Finally, we need to filter out some messages from other stylesheets that
occur when invoking dblatex in the CI job. This tool strips namespaces
much like the unnamespaced DocBook stylesheets and prints similar
messages. If we permit these messages to be printed to standard error,
our documentation CI job will fail because we check standard error for
unexpected output. Due to dblatex's reliance on Python 2, we may need
to revisit its use in the future, in which case this problem may go
away, but this can be delayed until a future patch.
The final message we filter is due to libxslt on modern Debian and
Ubuntu. The patch which they use to implement reproducible ID
generation also prints messages about the ID generation. While this
doesn't affect our current CI images since they use Ubuntu 16.04 which
lacks this patch, if we upgrade to Ubuntu 18.04 or a modern Debian,
these messages will appear and, like the above messages, cause a CI
failure.
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-09-15 22:43:32 +00:00
|
|
|
ASCIIDOC_DOCBOOK = docbook5
|
2018-05-06 20:42:25 +00:00
|
|
|
ASCIIDOC_EXTRA += -acompat-mode -atabsize=8
|
2017-01-26 00:13:44 +00:00
|
|
|
ASCIIDOC_EXTRA += -I. -rasciidoctor-extensions
|
2017-01-22 02:41:56 +00:00
|
|
|
ASCIIDOC_EXTRA += -alitdd='&\#x2d;&\#x2d;'
|
|
|
|
DBLATEX_COMMON =
|
Documentation: fix build with Asciidoctor 2
Our documentation toolchain has traditionally been built around DocBook
4.5. This version of DocBook is the last DTD-based version of DocBook.
In 2009, DocBook 5 was introduced using namespaces and its syntax is
expressed in RELAX NG, which is more expressive and allows a wider
variety of syntax forms.
Asciidoctor, one of the alternatives for building our documentation,
moved support for DocBook 4.5 out of core in its recent 2.0 release and
now only supports DocBook 5 in the main release. The DocBoook 4.5
converter is still available as a separate component, but this is not
available in most distro packages. This would not be a problem but for
the fact that we use xmlto, which is still stuck in the DocBook 4.5 era.
xmlto performs DTD validation as part of the build process. This is not
problematic for DocBook 4.5, which has a valid DTD, but it clearly
cannot work for DocBook 5, since no DTD can adequately express its full
syntax. In addition, even if xmlto did support RELAX NG validation,
that wouldn't be sufficient because it uses the libxml2-based xmllint to
do so, which has known problems with validating interleaves in RELAX NG.
Fortunately, there's an easy way forward: ask Asciidoctor to use its
DocBook 5 backend and tell xmlto to skip validation. Asciidoctor has
supported DocBook 5 since v0.1.4 in 2013 and xmlto has supported
skipping validation for probably longer than that.
We also need to teach xmlto how to use the namespaced DocBook XSLT
stylesheets instead of the non-namespaced ones it usually uses.
Normally these stylesheets are interchangeable, but the non-namespaced
ones have a bug that causes them not to strip whitespace automatically
from certain elements when namespaces are in use. This results in
additional whitespace at the beginning of list elements, which is
jarring and unsightly.
We can do this by passing a custom stylesheet with the -x option that
simply imports the namespaced stylesheets via a URL. Any system with
support for XML catalogs will automatically look this URL up and
reference a local copy instead without us having to know where this
local copy is located. We know that anyone using xmlto will already
have catalogs set up properly since the DocBook 4.5 DTD used during
validation is also looked up via catalogs. All major Linux
distributions distribute the necessary stylesheets and have built-in
catalog support, and Homebrew does as well, albeit with a requirement to
set an environment variable to enable catalog support.
On the off chance that someone lacks support for catalogs, it is
possible for xmlto (via xmllint) to download the stylesheets from the
URLs in question, although this will likely perform poorly enough to
attract attention. People still have the option of using the prebuilt
documentation that we ship, so happily this should not be an impediment.
Finally, we need to filter out some messages from other stylesheets that
occur when invoking dblatex in the CI job. This tool strips namespaces
much like the unnamespaced DocBook stylesheets and prints similar
messages. If we permit these messages to be printed to standard error,
our documentation CI job will fail because we check standard error for
unexpected output. Due to dblatex's reliance on Python 2, we may need
to revisit its use in the future, in which case this problem may go
away, but this can be delayed until a future patch.
The final message we filter is due to libxslt on modern Debian and
Ubuntu. The patch which they use to implement reproducible ID
generation also prints messages about the ID generation. While this
doesn't affect our current CI images since they use Ubuntu 16.04 which
lacks this patch, if we upgrade to Ubuntu 18.04 or a modern Debian,
these messages will appear and, like the above messages, cause a CI
failure.
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-09-15 22:43:32 +00:00
|
|
|
XMLTO_EXTRA += --skip-validation
|
|
|
|
XMLTO_EXTRA += -x manpage.xsl
|
2017-01-22 02:41:56 +00:00
|
|
|
endif
|
|
|
|
|
2009-03-22 13:20:44 +00:00
|
|
|
SHELL_PATH ?= $(SHELL)
|
|
|
|
# Shell quote;
|
|
|
|
SHELL_PATH_SQ = $(subst ','\'',$(SHELL_PATH))
|
|
|
|
|
2012-03-31 08:44:53 +00:00
|
|
|
ifdef DEFAULT_PAGER
|
|
|
|
DEFAULT_PAGER_SQ = $(subst ','\'',$(DEFAULT_PAGER))
|
|
|
|
ASCIIDOC_EXTRA += -a 'git-default-pager=$(DEFAULT_PAGER_SQ)'
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef DEFAULT_EDITOR
|
|
|
|
DEFAULT_EDITOR_SQ = $(subst ','\'',$(DEFAULT_EDITOR))
|
|
|
|
ASCIIDOC_EXTRA += -a 'git-default-editor=$(DEFAULT_EDITOR_SQ)'
|
|
|
|
endif
|
|
|
|
|
2009-03-27 06:49:38 +00:00
|
|
|
QUIET_SUBDIR0 = +$(MAKE) -C # space to separate -C and subdir
|
|
|
|
QUIET_SUBDIR1 =
|
|
|
|
|
|
|
|
ifneq ($(findstring $(MAKEFLAGS),w),w)
|
|
|
|
PRINT_DIR = --no-print-directory
|
|
|
|
else # "make -w"
|
|
|
|
NO_SUBDIR = :
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifneq ($(findstring $(MAKEFLAGS),s),s)
|
|
|
|
ifndef V
|
|
|
|
QUIET_ASCIIDOC = @echo ' ' ASCIIDOC $@;
|
|
|
|
QUIET_XMLTO = @echo ' ' XMLTO $@;
|
|
|
|
QUIET_DB2TEXI = @echo ' ' DB2TEXI $@;
|
|
|
|
QUIET_MAKEINFO = @echo ' ' MAKEINFO $@;
|
|
|
|
QUIET_DBLATEX = @echo ' ' DBLATEX $@;
|
|
|
|
QUIET_XSLTPROC = @echo ' ' XSLTPROC $@;
|
|
|
|
QUIET_GEN = @echo ' ' GEN $@;
|
2016-05-04 21:34:23 +00:00
|
|
|
QUIET_LINT = @echo ' ' LINT $@;
|
2009-03-27 06:49:38 +00:00
|
|
|
QUIET_STDERR = 2> /dev/null
|
|
|
|
QUIET_SUBDIR0 = +@subdir=
|
|
|
|
QUIET_SUBDIR1 = ;$(NO_SUBDIR) echo ' ' SUBDIR $$subdir; \
|
|
|
|
$(MAKE) $(PRINT_DIR) -C $$subdir
|
|
|
|
export V
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
2005-05-22 17:44:15 +00:00
|
|
|
all: html man
|
2005-05-10 21:32:39 +00:00
|
|
|
|
|
|
|
html: $(DOC_HTML)
|
|
|
|
|
2007-04-20 03:47:04 +00:00
|
|
|
man: man1 man5 man7
|
2005-05-22 17:44:15 +00:00
|
|
|
man1: $(DOC_MAN1)
|
2007-04-20 03:47:04 +00:00
|
|
|
man5: $(DOC_MAN5)
|
2005-05-22 17:44:15 +00:00
|
|
|
man7: $(DOC_MAN7)
|
2005-05-10 21:32:39 +00:00
|
|
|
|
2007-12-10 09:15:57 +00:00
|
|
|
info: git.info gitman.info
|
2007-08-06 10:22:57 +00:00
|
|
|
|
2008-12-10 22:44:50 +00:00
|
|
|
pdf: user-manual.pdf
|
|
|
|
|
2008-11-02 17:53:03 +00:00
|
|
|
install: install-man
|
|
|
|
|
|
|
|
install-man: man
|
2007-12-01 17:05:40 +00:00
|
|
|
$(INSTALL) -d -m 755 $(DESTDIR)$(man1dir)
|
|
|
|
$(INSTALL) -d -m 755 $(DESTDIR)$(man5dir)
|
|
|
|
$(INSTALL) -d -m 755 $(DESTDIR)$(man7dir)
|
|
|
|
$(INSTALL) -m 644 $(DOC_MAN1) $(DESTDIR)$(man1dir)
|
|
|
|
$(INSTALL) -m 644 $(DOC_MAN5) $(DESTDIR)$(man5dir)
|
|
|
|
$(INSTALL) -m 644 $(DOC_MAN7) $(DESTDIR)$(man7dir)
|
2005-07-15 01:21:57 +00:00
|
|
|
|
2007-08-06 10:22:57 +00:00
|
|
|
install-info: info
|
2007-12-01 17:05:40 +00:00
|
|
|
$(INSTALL) -d -m 755 $(DESTDIR)$(infodir)
|
2007-12-10 09:15:57 +00:00
|
|
|
$(INSTALL) -m 644 git.info gitman.info $(DESTDIR)$(infodir)
|
2007-08-06 10:22:57 +00:00
|
|
|
if test -r $(DESTDIR)$(infodir)/dir; then \
|
|
|
|
$(INSTALL_INFO) --info-dir=$(DESTDIR)$(infodir) git.info ;\
|
2007-12-10 09:15:57 +00:00
|
|
|
$(INSTALL_INFO) --info-dir=$(DESTDIR)$(infodir) gitman.info ;\
|
2007-08-06 10:22:57 +00:00
|
|
|
else \
|
|
|
|
echo "No directory found in $(DESTDIR)$(infodir)" >&2 ; \
|
|
|
|
fi
|
2005-11-04 08:06:20 +00:00
|
|
|
|
2008-12-10 22:44:50 +00:00
|
|
|
install-pdf: pdf
|
|
|
|
$(INSTALL) -d -m 755 $(DESTDIR)$(pdfdir)
|
|
|
|
$(INSTALL) -m 644 user-manual.pdf $(DESTDIR)$(pdfdir)
|
|
|
|
|
2007-12-02 05:07:55 +00:00
|
|
|
install-html: html
|
2009-03-22 13:20:44 +00:00
|
|
|
'$(SHELL_PATH_SQ)' ./install-webdoc.sh $(DESTDIR)$(htmldir)
|
2007-12-02 05:07:55 +00:00
|
|
|
|
2010-01-06 08:06:58 +00:00
|
|
|
../GIT-VERSION-FILE: FORCE
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_SUBDIR0)../ $(QUIET_SUBDIR1) GIT-VERSION-FILE
|
2007-03-25 11:56:49 +00:00
|
|
|
|
|
|
|
-include ../GIT-VERSION-FILE
|
|
|
|
|
2005-11-07 05:30:56 +00:00
|
|
|
#
|
|
|
|
# Determine "include::" file references in asciidoc files.
|
|
|
|
#
|
2013-01-28 00:52:26 +00:00
|
|
|
docdep_prereqs = \
|
|
|
|
mergetools-list.made $(mergetools_txt) \
|
|
|
|
cmd-list.made $(cmds_txt)
|
|
|
|
|
2018-10-27 06:22:34 +00:00
|
|
|
doc.dep : $(docdep_prereqs) $(wildcard *.txt) $(wildcard config/*.txt) build-docdep.perl
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_GEN)$(RM) $@+ $@ && \
|
|
|
|
$(PERL_PATH) ./build-docdep.perl >$@+ $(QUIET_STDERR) && \
|
2005-11-08 02:21:51 +00:00
|
|
|
mv $@+ $@
|
2005-11-07 05:30:56 +00:00
|
|
|
|
2005-11-08 02:21:51 +00:00
|
|
|
-include doc.dep
|
2005-11-04 08:06:20 +00:00
|
|
|
|
2007-01-19 00:02:13 +00:00
|
|
|
cmds_txt = cmds-ancillaryinterrogators.txt \
|
|
|
|
cmds-ancillarymanipulators.txt \
|
|
|
|
cmds-mainporcelain.txt \
|
|
|
|
cmds-plumbinginterrogators.txt \
|
|
|
|
cmds-plumbingmanipulators.txt \
|
2007-01-19 06:32:38 +00:00
|
|
|
cmds-synchingrepositories.txt \
|
|
|
|
cmds-synchelpers.txt \
|
|
|
|
cmds-purehelpers.txt \
|
|
|
|
cmds-foreignscminterface.txt
|
2007-01-19 00:02:13 +00:00
|
|
|
|
2007-04-06 05:17:20 +00:00
|
|
|
$(cmds_txt): cmd-list.made
|
|
|
|
|
2007-12-02 07:39:19 +00:00
|
|
|
cmd-list.made: cmd-list.perl ../command-list.txt $(MAN1_TXT)
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_GEN)$(RM) $@ && \
|
|
|
|
$(PERL_PATH) ./cmd-list.perl ../command-list.txt $(QUIET_STDERR) && \
|
2007-04-06 05:17:20 +00:00
|
|
|
date >$@
|
2005-05-10 21:32:39 +00:00
|
|
|
|
2013-01-28 00:52:26 +00:00
|
|
|
mergetools_txt = mergetools-diff.txt mergetools-merge.txt
|
|
|
|
|
|
|
|
$(mergetools_txt): mergetools-list.made
|
|
|
|
|
|
|
|
mergetools-list.made: ../git-mergetool--lib.sh $(wildcard ../mergetools/*)
|
|
|
|
$(QUIET_GEN)$(RM) $@ && \
|
|
|
|
$(SHELL_PATH) -c 'MERGE_TOOLS_DIR=../mergetools && \
|
|
|
|
. ../git-mergetool--lib.sh && \
|
|
|
|
show_tool_names can_diff "* " || :' >mergetools-diff.txt && \
|
|
|
|
$(SHELL_PATH) -c 'MERGE_TOOLS_DIR=../mergetools && \
|
|
|
|
. ../git-mergetool--lib.sh && \
|
|
|
|
show_tool_names can_merge "* " || :' >mergetools-merge.txt && \
|
|
|
|
date >$@
|
|
|
|
|
2019-03-17 18:36:00 +00:00
|
|
|
TRACK_ASCIIDOCFLAGS = $(subst ','\'',$(ASCIIDOC_COMMON):$(ASCIIDOC_HTML):$(ASCIIDOC_DOCBOOK))
|
|
|
|
|
|
|
|
GIT-ASCIIDOCFLAGS: FORCE
|
|
|
|
@FLAGS='$(TRACK_ASCIIDOCFLAGS)'; \
|
|
|
|
if test x"$$FLAGS" != x"`cat GIT-ASCIIDOCFLAGS 2>/dev/null`" ; then \
|
|
|
|
echo >&2 " * new asciidoc flags"; \
|
|
|
|
echo "$$FLAGS" >GIT-ASCIIDOCFLAGS; \
|
|
|
|
fi
|
|
|
|
|
2005-05-10 21:32:39 +00:00
|
|
|
clean:
|
2008-01-06 03:09:09 +00:00
|
|
|
$(RM) *.xml *.xml+ *.html *.html+ *.1 *.5 *.7
|
2009-03-27 06:49:39 +00:00
|
|
|
$(RM) *.texi *.texi+ *.texi++ git.info gitman.info
|
2011-08-08 08:33:05 +00:00
|
|
|
$(RM) *.pdf
|
2007-11-25 07:48:04 +00:00
|
|
|
$(RM) howto-index.txt howto/*.html doc.dep
|
2012-10-23 17:58:04 +00:00
|
|
|
$(RM) technical/*.html technical/api-index.txt
|
2017-11-12 22:07:18 +00:00
|
|
|
$(RM) SubmittingPatches.txt
|
2013-01-28 00:52:26 +00:00
|
|
|
$(RM) $(cmds_txt) $(mergetools_txt) *.made
|
2009-12-04 17:53:21 +00:00
|
|
|
$(RM) manpage-base-url.xsl
|
2019-03-17 18:36:00 +00:00
|
|
|
$(RM) GIT-ASCIIDOCFLAGS
|
2005-05-10 21:32:39 +00:00
|
|
|
|
2019-04-16 10:28:09 +00:00
|
|
|
$(MAN_HTML): %.html : %.txt asciidoc.conf asciidoctor-extensions.rb GIT-ASCIIDOCFLAGS
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \
|
2014-10-27 00:13:42 +00:00
|
|
|
$(TXT_TO_HTML) -d manpage -o $@+ $< && \
|
2007-03-25 11:56:49 +00:00
|
|
|
mv $@+ $@
|
2005-05-10 21:32:39 +00:00
|
|
|
|
2019-04-16 10:28:09 +00:00
|
|
|
$(OBSOLETE_HTML): %.html : %.txto asciidoc.conf asciidoctor-extensions.rb GIT-ASCIIDOCFLAGS
|
2013-01-31 21:59:50 +00:00
|
|
|
$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \
|
2014-10-27 00:13:42 +00:00
|
|
|
$(TXT_TO_HTML) -o $@+ $< && \
|
2013-01-31 21:59:50 +00:00
|
|
|
mv $@+ $@
|
|
|
|
|
2009-12-04 17:53:21 +00:00
|
|
|
manpage-base-url.xsl: manpage-base-url.xsl.in
|
2018-08-29 15:47:20 +00:00
|
|
|
$(QUIET_GEN)sed "s|@@MAN_BASE_URL@@|$(MAN_BASE_URL)|" $< > $@
|
2009-12-04 17:53:21 +00:00
|
|
|
|
2019-02-27 18:17:52 +00:00
|
|
|
%.1 %.5 %.7 : %.xml manpage-base-url.xsl $(wildcard manpage*.xsl)
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_XMLTO)$(RM) $@ && \
|
2012-09-19 17:06:37 +00:00
|
|
|
$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $<
|
2005-05-10 21:32:39 +00:00
|
|
|
|
2019-04-16 10:28:09 +00:00
|
|
|
%.xml : %.txt asciidoc.conf asciidoctor-extensions.rb GIT-ASCIIDOCFLAGS
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \
|
2014-10-27 00:13:42 +00:00
|
|
|
$(TXT_TO_XML) -d manpage -o $@+ $< && \
|
2007-03-25 11:56:49 +00:00
|
|
|
mv $@+ $@
|
2005-08-15 00:24:36 +00:00
|
|
|
|
2019-04-16 10:28:09 +00:00
|
|
|
user-manual.xml: user-manual.txt user-manual.conf asciidoctor-extensions.rb GIT-ASCIIDOCFLAGS
|
2010-04-22 01:18:21 +00:00
|
|
|
$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \
|
2017-01-02 16:03:57 +00:00
|
|
|
$(TXT_TO_XML) -d book -o $@+ $< && \
|
2010-04-22 01:18:21 +00:00
|
|
|
mv $@+ $@
|
2007-01-08 00:23:49 +00:00
|
|
|
|
2007-11-25 07:48:04 +00:00
|
|
|
technical/api-index.txt: technical/api-index-skel.txt \
|
|
|
|
technical/api-index.sh $(patsubst %,%.txt,$(API_DOCS))
|
2009-03-22 13:20:44 +00:00
|
|
|
$(QUIET_GEN)cd technical && '$(SHELL_PATH_SQ)' ./api-index.sh
|
2007-11-25 07:48:04 +00:00
|
|
|
|
2012-06-07 21:03:23 +00:00
|
|
|
technical/%.html: ASCIIDOC_EXTRA += -a git-relative-html-prefix=../
|
2019-03-17 18:36:00 +00:00
|
|
|
$(patsubst %,%.html,$(API_DOCS) technical/api-index $(TECH_DOCS)): %.html : %.txt \
|
|
|
|
asciidoc.conf GIT-ASCIIDOCFLAGS
|
2014-10-27 00:13:42 +00:00
|
|
|
$(QUIET_ASCIIDOC)$(TXT_TO_HTML) $*.txt
|
2007-11-25 07:48:04 +00:00
|
|
|
|
2017-11-12 22:07:18 +00:00
|
|
|
SubmittingPatches.txt: SubmittingPatches
|
|
|
|
$(QUIET_GEN) cp $< $@
|
|
|
|
|
2007-07-24 07:46:35 +00:00
|
|
|
XSLT = docbook.xsl
|
2007-03-16 15:45:29 +00:00
|
|
|
XSLTOPTS = --xinclude --stringparam html.stylesheet docbook-xsl.css
|
2007-03-03 18:33:48 +00:00
|
|
|
|
2010-08-21 06:21:22 +00:00
|
|
|
user-manual.html: user-manual.xml $(XSLT)
|
2010-04-22 01:18:21 +00:00
|
|
|
$(QUIET_XSLTPROC)$(RM) $@+ $@ && \
|
|
|
|
xsltproc $(XSLTOPTS) -o $@+ $(XSLT) $< && \
|
|
|
|
mv $@+ $@
|
2007-01-08 00:23:49 +00:00
|
|
|
|
2007-12-12 21:31:02 +00:00
|
|
|
git.info: user-manual.texi
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_MAKEINFO)$(MAKEINFO) --no-split -o $@ user-manual.texi
|
2007-12-10 09:15:57 +00:00
|
|
|
|
2007-12-12 21:31:02 +00:00
|
|
|
user-manual.texi: user-manual.xml
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_DB2TEXI)$(RM) $@+ $@ && \
|
2009-03-27 06:49:39 +00:00
|
|
|
$(DOCBOOK2X_TEXI) user-manual.xml --encoding=UTF-8 --to-stdout >$@++ && \
|
|
|
|
$(PERL_PATH) fix-texi.perl <$@++ >$@+ && \
|
|
|
|
rm $@++ && \
|
2007-12-10 09:15:57 +00:00
|
|
|
mv $@+ $@
|
|
|
|
|
2008-12-10 22:44:50 +00:00
|
|
|
user-manual.pdf: user-manual.xml
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_DBLATEX)$(RM) $@+ $@ && \
|
2017-01-22 02:41:55 +00:00
|
|
|
$(DBLATEX) -o $@+ $(DBLATEX_COMMON) $< && \
|
2008-12-10 22:44:50 +00:00
|
|
|
mv $@+ $@
|
|
|
|
|
Documentation: add XSLT to fix DocBook for Texinfo
There are two ways to create a section in a reference document (i.e.,
manpage) in DocBook 4: refsection elements and refsect, refsect2, and
refsect3 elements. Either form is acceptable as of DocBook 4.2, but
they cannot be mixed. Prior to DocBook 4.2, only the numbered forms
were acceptable.
docbook2texi only accepts the numbered forms, and this has not generally
been a problem, since AsciiDoc produces the numbered forms.
Asciidoctor, on the other hand, uses a shared backend for DocBook 4 and
5, and uses the unnumbered refsection elements instead.
If we don't convert the unnumbered form to the numbered form,
docbook2texi omits section headings, which is undesirable. Add an XSLT
stylesheet to transform the unnumbered forms to the numbered forms
automatically, and preprocess the DocBook XML as part of the
transformation to Texinfo format.
Note that this transformation is only necessary for Texinfo, since
docbook2texi provides its own stylesheets. The DocBook stylesheets,
which we use for other formats, provide the full range of DocBook 4 and
5 compatibility, and don't have this issue.
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-01-22 02:41:54 +00:00
|
|
|
gitman.texi: $(MAN_XML) cat-texi.perl texi.xsl
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_DB2TEXI)$(RM) $@+ $@ && \
|
Documentation: add XSLT to fix DocBook for Texinfo
There are two ways to create a section in a reference document (i.e.,
manpage) in DocBook 4: refsection elements and refsect, refsect2, and
refsect3 elements. Either form is acceptable as of DocBook 4.2, but
they cannot be mixed. Prior to DocBook 4.2, only the numbered forms
were acceptable.
docbook2texi only accepts the numbered forms, and this has not generally
been a problem, since AsciiDoc produces the numbered forms.
Asciidoctor, on the other hand, uses a shared backend for DocBook 4 and
5, and uses the unnumbered refsection elements instead.
If we don't convert the unnumbered form to the numbered form,
docbook2texi omits section headings, which is undesirable. Add an XSLT
stylesheet to transform the unnumbered forms to the numbered forms
automatically, and preprocess the DocBook XML as part of the
transformation to Texinfo format.
Note that this transformation is only necessary for Texinfo, since
docbook2texi provides its own stylesheets. The DocBook stylesheets,
which we use for other formats, provide the full range of DocBook 4 and
5 compatibility, and don't have this issue.
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2017-01-22 02:41:54 +00:00
|
|
|
($(foreach xml,$(sort $(MAN_XML)),xsltproc -o $(xml)+ texi.xsl $(xml) && \
|
|
|
|
$(DOCBOOK2X_TEXI) --encoding=UTF-8 --to-stdout $(xml)+ && \
|
|
|
|
rm $(xml)+ &&) true) > $@++ && \
|
2009-03-27 06:49:39 +00:00
|
|
|
$(PERL_PATH) cat-texi.perl $@ <$@++ >$@+ && \
|
|
|
|
rm $@++ && \
|
2007-12-10 09:15:57 +00:00
|
|
|
mv $@+ $@
|
|
|
|
|
|
|
|
gitman.info: gitman.texi
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_MAKEINFO)$(MAKEINFO) --no-split --no-validate $*.texi
|
2007-12-10 09:15:57 +00:00
|
|
|
|
|
|
|
$(patsubst %.txt,%.texi,$(MAN_TXT)): %.texi : %.xml
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_DB2TEXI)$(RM) $@+ $@ && \
|
|
|
|
$(DOCBOOK2X_TEXI) --to-stdout $*.xml >$@+ && \
|
2007-12-10 09:15:57 +00:00
|
|
|
mv $@+ $@
|
2007-08-06 10:22:57 +00:00
|
|
|
|
2005-08-25 07:28:18 +00:00
|
|
|
howto-index.txt: howto-index.sh $(wildcard howto/*.txt)
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_GEN)$(RM) $@+ $@ && \
|
2012-12-22 18:34:27 +00:00
|
|
|
'$(SHELL_PATH_SQ)' ./howto-index.sh $(sort $(wildcard howto/*.txt)) >$@+ && \
|
2005-08-25 07:28:18 +00:00
|
|
|
mv $@+ $@
|
|
|
|
|
2005-08-30 20:51:01 +00:00
|
|
|
$(patsubst %,%.html,$(ARTICLES)) : %.html : %.txt
|
2014-10-27 00:13:42 +00:00
|
|
|
$(QUIET_ASCIIDOC)$(TXT_TO_HTML) $*.txt
|
2005-08-25 07:28:18 +00:00
|
|
|
|
|
|
|
WEBDOC_DEST = /pub/software/scm/git/docs
|
|
|
|
|
2012-06-07 21:03:23 +00:00
|
|
|
howto/%.html: ASCIIDOC_EXTRA += -a git-relative-html-prefix=../
|
2019-03-17 18:36:00 +00:00
|
|
|
$(patsubst %.txt,%.html,$(wildcard howto/*.txt)): %.html : %.txt GIT-ASCIIDOCFLAGS
|
2009-03-27 06:49:38 +00:00
|
|
|
$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \
|
2014-10-11 23:37:35 +00:00
|
|
|
sed -e '1,/^$$/d' $< | \
|
2014-10-27 00:13:42 +00:00
|
|
|
$(TXT_TO_HTML) - >$@+ && \
|
2005-08-30 05:38:12 +00:00
|
|
|
mv $@+ $@
|
|
|
|
|
2005-08-25 07:28:18 +00:00
|
|
|
install-webdoc : html
|
2009-03-22 13:20:44 +00:00
|
|
|
'$(SHELL_PATH_SQ)' ./install-webdoc.sh $(WEBDOC_DEST)
|
2006-12-23 16:26:09 +00:00
|
|
|
|
2013-01-21 19:17:53 +00:00
|
|
|
# You must have a clone of 'git-htmldocs' and 'git-manpages' repositories
|
|
|
|
# next to the 'git' repository itself for the following to work.
|
2011-11-08 18:17:40 +00:00
|
|
|
|
2008-11-02 17:53:03 +00:00
|
|
|
quick-install: quick-install-man
|
|
|
|
|
2011-11-08 18:17:40 +00:00
|
|
|
require-manrepo::
|
|
|
|
@if test ! -d $(MAN_REPO); \
|
|
|
|
then echo "git-manpages repository must exist at $(MAN_REPO)"; exit 1; fi
|
|
|
|
|
|
|
|
quick-install-man: require-manrepo
|
2017-12-09 22:07:57 +00:00
|
|
|
'$(SHELL_PATH_SQ)' ./install-doc-quick.sh $(MAN_REPO) $(DESTDIR)$(mandir) $(GIT_MAN_REF)
|
2011-11-08 18:17:40 +00:00
|
|
|
|
|
|
|
require-htmlrepo::
|
|
|
|
@if test ! -d $(HTML_REPO); \
|
|
|
|
then echo "git-htmldocs repository must exist at $(HTML_REPO)"; exit 1; fi
|
2007-03-25 11:56:49 +00:00
|
|
|
|
2011-11-08 18:17:40 +00:00
|
|
|
quick-install-html: require-htmlrepo
|
2017-12-09 22:07:57 +00:00
|
|
|
'$(SHELL_PATH_SQ)' ./install-doc-quick.sh $(HTML_REPO) $(DESTDIR)$(htmldir) $(GIT_MAN_REF)
|
2008-09-09 20:44:17 +00:00
|
|
|
|
2012-08-08 20:57:52 +00:00
|
|
|
print-man1:
|
|
|
|
@for i in $(MAN1_TXT); do echo $$i; done
|
|
|
|
|
2016-05-04 21:34:23 +00:00
|
|
|
lint-docs::
|
|
|
|
$(QUIET_LINT)$(PERL_PATH) lint-gitlink.perl
|
|
|
|
|
2019-01-07 19:21:12 +00:00
|
|
|
ifeq ($(wildcard po/Makefile),po/Makefile)
|
|
|
|
doc-l10n install-l10n::
|
|
|
|
$(MAKE) -C po $@
|
|
|
|
endif
|
|
|
|
|
2010-01-06 08:06:58 +00:00
|
|
|
.PHONY: FORCE
|