Files
boost_beast/doc/Jamfile

199 lines
4.8 KiB
Plaintext
Raw Normal View History

2017-07-20 08:01:46 -07:00
#
2017-02-06 20:07:03 -05:00
# Copyright (c) 2013-2017 Vinnie Falco (vinnie dot falco at gmail dot com)
2017-07-20 08:01:46 -07:00
#
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
#
project beast/doc ;
2017-07-24 13:24:15 -07:00
import os ;
import path ;
import boostbook ;
import quickbook ;
2017-07-25 14:50:04 +03:00
import xsltproc ;
import doxygen ;
import modules ;
2017-07-23 22:49:57 -07:00
2017-07-24 13:24:15 -07:00
#-------------------------------------------------------------------------------
#
# Build the list of header files that Doxygen will scan. We need
# this list to inform the build system of the dependencies so the
# docs can be rebuild if any of the header files change.
#
local sources = [ path.glob-tree ../include/boost/beast : *.hpp *.ipp : detail impl ] ;
2017-07-20 08:01:46 -07:00
2017-07-25 14:50:04 +03:00
# Get the configured paths to doxygen and xsltproc
.doxygen = [ doxygen.name ] ;
.doxygen ?= doxygen ;
#ECHO Using doxygen from "$(.doxygen)" ;
.xsltproc = [ xsltproc.name ] ;
.xsltproc ?= xsltproc ;
#ECHO Using xsltproc from "$(.xsltproc)" ;
2017-07-24 13:24:15 -07:00
#-------------------------------------------------------------------------------
2017-07-23 22:49:57 -07:00
#
2017-07-24 13:24:15 -07:00
# Generate transform.xsl. This xsl transfomration takes as input
# the Doxygen-generated XML and produces QuickBook output.
#
make transform.xsl
:
docca/include/docca/doxygen.xsl
xsl/config.xsl
xsl/class_detail.xsl
xsl/includes.xsl
xsl/includes_foot.xsl
:
@make_transform
;
# Make a copy of the docca transform. Then, insert our
# customizations into the speciall marked locations using sed.
#
actions make_transform
{
cp $(2[1]) $(1)
sed -i -e "/<!-- CONFIG_TEMPLATE -->/{r $(2[2])" -e "d}" $(1)
sed -i -e "/<!-- CLASS_DETAIL_TEMPLATE -->/{r $(2[3])" -e "d}" $(1)
sed -i -e "/<!-- INCLUDES_TEMPLATE -->/{r $(2[4])" -e "d}" $(1)
sed -i -e "/<!-- INCLUDES_FOOT_TEMPLATE -->/{r $(2[5])" -e "d}" $(1)
}
#-------------------------------------------------------------------------------
#
# Invoke Doxygen to process the header files and produce the XML
# containing the description of the C++ declarations and extracted
# Javadoc comments.
#
2017-07-25 14:50:04 +03:00
make index.xml
2017-07-24 13:24:15 -07:00
:
./source.dox
:
2017-07-25 14:50:04 +03:00
@make_doxygen_xml
2017-07-24 13:24:15 -07:00
:
<dependency>$(sources)
;
if [ os.name ] = NT
{
2017-07-25 14:50:04 +03:00
actions make_doxygen_xml
2017-07-24 13:24:15 -07:00
{
SET LIB_DIR=$(2:B=:S=..)
SET XML_OUTPUT=$(1:D)
2017-07-25 14:50:04 +03:00
"$(.doxygen)" $(2)
2017-07-24 13:24:15 -07:00
}
}
else
{
2017-07-25 14:50:04 +03:00
actions make_doxygen_xml
2017-07-24 13:24:15 -07:00
{
export LIB_DIR=$(2:B=:S=..)
export XML_OUTPUT=$(1:D)
2017-08-02 09:19:19 -07:00
echo "LIB_DIR=$LIB_DIR" > "$LIB_DIR/doc/html/lib_dir.txt"
2017-07-25 14:50:04 +03:00
"$(.doxygen)" $(2)
2017-07-24 13:24:15 -07:00
}
}
2017-07-25 14:50:04 +03:00
make combine.xslt : index.xml : @null_action ;
actions null_action
{
touch -c $(1) ;
}
make reference.xml
:
combine.xslt
index.xml
:
@call-xsltproc
;
actions call-xsltproc
{
"$(.xsltproc)" $(2) > $(1)
}
2017-07-24 13:24:15 -07:00
#-------------------------------------------------------------------------------
#
# Produce the reference.qbk file by running
# the reference xml through the transform.
2017-07-23 22:49:57 -07:00
#
2017-07-24 13:24:15 -07:00
make reference.qbk
:
transform.xsl
reference.xml
:
2017-07-25 14:50:04 +03:00
@call-xsltproc
2017-07-24 13:24:15 -07:00
;
2017-07-20 08:01:46 -07:00
2017-07-24 13:24:15 -07:00
# We have to make a copy of reference.qbk and put it
# in a place where the static .qbk files can find it
#
install qbk : reference.qbk ;
#-------------------------------------------------------------------------------
#
# Produce the Boost.Book XML from the QuickBook
#
2017-07-20 08:01:46 -07:00
2017-07-24 13:24:15 -07:00
install images
2017-07-20 08:01:46 -07:00
:
images/message.png
:
2017-07-23 22:49:57 -07:00
<location>html/beast/images
2017-07-20 08:01:46 -07:00
;
2017-07-24 13:24:15 -07:00
explicit images ;
2017-07-28 19:15:55 -07:00
xml beast_doc
:
qbk/00_main.qbk
:
<dependency>images
<dependency>qbk
;
explicit beast_doc ;
2017-07-24 13:24:15 -07:00
#-------------------------------------------------------------------------------
#
# HTML documentation for $(BOOST_ROOT)/doc/html
#
#-------------------------------------------------------------------------------
2017-07-20 08:01:46 -07:00
2017-07-23 22:49:57 -07:00
boostbook beast
2016-09-25 11:19:51 -04:00
:
2017-07-23 22:49:57 -07:00
beast_doc
2016-09-25 11:19:51 -04:00
:
2017-07-23 22:49:57 -07:00
<xsl:param>boost.root=../../../..
<xsl:param>root.filename=beast
<xsl:param>chapter.autolabel=1
2017-07-20 08:01:46 -07:00
<xsl:param>chunk.section.depth=8 # Depth to which sections should be chunked
2016-09-25 11:19:51 -04:00
<xsl:param>chunk.first.sections=1 # Chunk the first top-level section?
<xsl:param>toc.section.depth=8 # How deep should recursive sections appear in the TOC?
<xsl:param>toc.max.depth=8 # How many levels should be created for each TOC?
<xsl:param>generate.section.toc.level=8 # Control depth of TOC generation in sections
2017-06-04 17:25:55 -07:00
<xsl:param>generate.toc="chapter toc,title section nop reference nop"
2017-07-23 22:49:57 -07:00
<include>../../../tools/boostbook/dtd
2017-07-20 08:01:46 -07:00
:
2017-07-24 13:24:15 -07:00
<dependency>images
2017-07-20 08:01:46 -07:00
;
2017-07-24 13:24:15 -07:00
#-------------------------------------------------------------------------------
#
# These are used to inform the build system of the
# means to build the integrated and stand-alone docs.
#
2017-07-28 19:15:55 -07:00
alias boostdoc ;
2017-07-23 22:49:57 -07:00
explicit boostdoc ;
2017-07-28 19:15:55 -07:00
alias boostrelease : beast ;
2017-07-23 22:49:57 -07:00
explicit boostrelease ;