2017-10-19 03:11:57 +00:00
|
|
|
# Usage:
|
|
|
|
# Have files:
|
|
|
|
# - osmoyada-vty-reference.xml
|
|
|
|
# A docbook root XML including a &chapter-vty; reference.
|
|
|
|
# - vty/*additions*.xml
|
|
|
|
# Manual additions to specific VTY nodes, any number of files.
|
|
|
|
# - vty/*_reference.xml
|
|
|
|
# Export from VTY 'show online-help', exactly one file.
|
|
|
|
#
|
2018-11-16 11:39:59 +00:00
|
|
|
# In your Makefile.am,
|
|
|
|
# - define 'OSMO_GSM_MANUALS_DIR' to point at the osmo-gsm-manuals shared files
|
|
|
|
# installation path as returned by "pkg-config osmo-gsm-manuals --variable=osmogsmmanualsdir"
|
|
|
|
# (project specific repos set this with configure.ac),
|
2017-10-19 03:11:57 +00:00
|
|
|
# - define the (single) name of the vty-reference source in VTY_REFERENCE,
|
|
|
|
# - include this file.
|
|
|
|
#
|
|
|
|
# e.g.
|
|
|
|
#
|
2018-11-14 09:47:01 +00:00
|
|
|
# OSMO_GSM_MANUALS_DIR = ..
|
2017-10-19 03:11:57 +00:00
|
|
|
# VTY_REFERENCE = osmofoo-vty-reference
|
2018-11-14 09:47:01 +00:00
|
|
|
# include $(OSMO_GSM_MANUALS_DIR)/build/Makefile.vty-reference.inc
|
2017-10-19 03:11:57 +00:00
|
|
|
#
|
|
|
|
# This uses the Makefile.docbook.inc, you should not mix uses of
|
|
|
|
# Makefile.vty-reference.inc and Makefile.docbook.inc.
|
|
|
|
|
|
|
|
DOCBOOKS = $(VTY_REFERENCE)
|
|
|
|
DOCBOOKS_DEPS = generated/docbook_vty.xml
|
2018-11-14 09:47:01 +00:00
|
|
|
include $(OSMO_GSM_MANUALS_DIR)/build/Makefile.docbook.inc
|
2017-10-19 03:11:57 +00:00
|
|
|
|
2018-11-14 09:47:01 +00:00
|
|
|
MERGE_DOC = $(shell realpath $(OSMO_GSM_MANUALS_DIR)/merge_doc.xsl)
|
2017-10-19 03:11:57 +00:00
|
|
|
|
|
|
|
CLEAN_FILES += generated
|
|
|
|
|
|
|
|
generated/docbook_vty.xml: \
|
Makefile.*.inc: adjust to out-of-tree building
Makefile.asciidoc.inc: create a symlink for the root adoc file, from
which a PDF gets generated, from the srcdir to the builddir. This file
may include other adoc files, which do not get symlinked. We need to do
this, because a2x (the program generating the PDF file) does not have a
parameter for the output file, and will otherwise generate the PDF in
the srcdir instead of the builddir. Do the same in the check target, so
the relative include paths work the same.
Makefile.asciidoc.inc, Makefile.docbook.inc: set the include paths for
the xstl parser, as well as the LaTeX compiler, so they can find the
files they need from both OSMO_GSM_MANUALS_DIR and builddir.
Makefile.asciidoc.inc, Makefile.docbook.inc: refer to the output file
$@ with $(notdir $@). This removes the path from the file, like
basename from coreutils. The output file will then be placed in the
builddir instead of the srcdir.
Makefile.vty-reference.inc: use $(srcdir) in references to vty/*.xml
files.
(moving manuals to project repositories 12/19)
Related: OS#3385
Change-Id: Ie6b212a6518f0fc29fae610a37ae6c533189278d
2018-11-14 14:51:07 +00:00
|
|
|
$(srcdir)/vty/*xml \
|
2018-11-14 09:47:01 +00:00
|
|
|
$(OSMO_GSM_MANUALS_DIR)/common/vty_additions.xml \
|
|
|
|
$(OSMO_GSM_MANUALS_DIR)/common/chapters/vty.xml \
|
|
|
|
$(OSMO_GSM_MANUALS_DIR)/vty_reference.xsl
|
|
|
|
$(OSMO_GSM_MANUALS_DIR)/build/vty_reference_combine.sh "$(MERGE_DOC)" \
|
2018-11-14 14:55:10 +00:00
|
|
|
$(srcdir)/vty/*reference.xml \
|
2018-11-14 09:47:01 +00:00
|
|
|
$(OSMO_GSM_MANUALS_DIR)/common/vty_additions.xml \
|
Makefile.*.inc: adjust to out-of-tree building
Makefile.asciidoc.inc: create a symlink for the root adoc file, from
which a PDF gets generated, from the srcdir to the builddir. This file
may include other adoc files, which do not get symlinked. We need to do
this, because a2x (the program generating the PDF file) does not have a
parameter for the output file, and will otherwise generate the PDF in
the srcdir instead of the builddir. Do the same in the check target, so
the relative include paths work the same.
Makefile.asciidoc.inc, Makefile.docbook.inc: set the include paths for
the xstl parser, as well as the LaTeX compiler, so they can find the
files they need from both OSMO_GSM_MANUALS_DIR and builddir.
Makefile.asciidoc.inc, Makefile.docbook.inc: refer to the output file
$@ with $(notdir $@). This removes the path from the file, like
basename from coreutils. The output file will then be placed in the
builddir instead of the srcdir.
Makefile.vty-reference.inc: use $(srcdir) in references to vty/*.xml
files.
(moving manuals to project repositories 12/19)
Related: OS#3385
Change-Id: Ie6b212a6518f0fc29fae610a37ae6c533189278d
2018-11-14 14:51:07 +00:00
|
|
|
$(srcdir)/vty/*additions*.xml
|
2018-11-14 09:47:01 +00:00
|
|
|
xsltproc $(OSMO_GSM_MANUALS_DIR)/vty_reference.xsl generated/combined.xml \
|
2017-10-19 03:11:57 +00:00
|
|
|
> generated/docbook_vty.xml
|