mirror of
https://github.com/qpdf/qpdf.git
synced 2024-12-22 10:58:58 +00:00
Switch build from docbook manual to sphinx
Also remove linearization from qpdf-manual.pdf. It's a small file, and removing the dependency on the qpdf executable significantly shortens build times.
This commit is contained in:
parent
abb6a16ed1
commit
a372a988fd
2
Makefile
2
Makefile
@ -100,7 +100,7 @@ $(foreach B,$(BUILD_ITEMS),$(eval \
|
|||||||
DISTFILES = doc/qpdf-manual.html doc/qpdf-manual.pdf
|
DISTFILES = doc/qpdf-manual.html doc/qpdf-manual.pdf
|
||||||
distfiles.zip: $(DISTFILES)
|
distfiles.zip: $(DISTFILES)
|
||||||
$(RM) distfiles.zip
|
$(RM) distfiles.zip
|
||||||
zip distfiles.zip $(DISTFILES)
|
zip -r distfiles.zip $(DISTFILES) doc/_static
|
||||||
|
|
||||||
distclean: clean
|
distclean: clean
|
||||||
$(RM) -r autoconf.mk autom4te.cache config.log config.status libtool
|
$(RM) -r autoconf.mk autom4te.cache config.log config.status libtool
|
||||||
|
14
TODO
14
TODO
@ -42,20 +42,6 @@ Correct placement of comment: <!-- This section is referenced in QPDFObjectHandl
|
|||||||
<firstterm> -> just use literal
|
<firstterm> -> just use literal
|
||||||
<replaceable> -> Make sure in :file: or :samp:, then use {}
|
<replaceable> -> Make sure in :file: or :samp:, then use {}
|
||||||
|
|
||||||
Build:
|
|
||||||
|
|
||||||
apt install python3-pip texlive-latex-extra latexmk
|
|
||||||
pip install sphinx
|
|
||||||
|
|
||||||
sphinx-build -M help . .
|
|
||||||
sphinx-build -M latexpdf source build
|
|
||||||
sphinx-build -M html source build
|
|
||||||
sphinx-build -M singlehtml source build
|
|
||||||
|
|
||||||
autoconf should detect sphinx and its dependencies, not fop, etc.
|
|
||||||
Remove VALIDATE_DOC
|
|
||||||
Fix installation of documentation in doc
|
|
||||||
|
|
||||||
Additional cleanup:
|
Additional cleanup:
|
||||||
|
|
||||||
* Indices and tables section
|
* Indices and tables section
|
||||||
|
4
aclocal.m4
vendored
4
aclocal.m4
vendored
@ -1,6 +1,6 @@
|
|||||||
# generated automatically by aclocal 1.16.1 -*- Autoconf -*-
|
# generated automatically by aclocal 1.16.4 -*- Autoconf -*-
|
||||||
|
|
||||||
# Copyright (C) 1996-2018 Free Software Foundation, Inc.
|
# Copyright (C) 1996-2021 Free Software Foundation, Inc.
|
||||||
|
|
||||||
# This file is free software; the Free Software Foundation
|
# This file is free software; the Free Software Foundation
|
||||||
# gives unlimited permission to copy and/or distribute it,
|
# gives unlimited permission to copy and/or distribute it,
|
||||||
|
@ -1,11 +1,13 @@
|
|||||||
FROM ubuntu:16.04
|
FROM ubuntu:18.04
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get -y install screen autoconf git sudo \
|
apt-get -y install screen autoconf git sudo \
|
||||||
build-essential zlib1g-dev libjpeg-dev libgnutls28-dev \
|
build-essential zlib1g-dev libjpeg-dev libgnutls28-dev \
|
||||||
docbook-xsl fop xsltproc \
|
python3-pip texlive-latex-extra latexmk \
|
||||||
inkscape imagemagick busybox-static wget fuse && \
|
inkscape imagemagick busybox-static wget fuse && \
|
||||||
apt-get clean && \
|
apt-get clean && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
RUN pip3 install sphinx
|
||||||
COPY entrypoint /entrypoint
|
COPY entrypoint /entrypoint
|
||||||
RUN chmod +x /entrypoint
|
RUN chmod +x /entrypoint
|
||||||
ENTRYPOINT [ "/entrypoint" ]
|
ENTRYPOINT [ "/entrypoint" ]
|
||||||
|
@ -43,24 +43,25 @@ if [ "x$1" == "x--sign" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# Check if we are on Ubuntu Trusty
|
# Check Ubuntu Distribution
|
||||||
_osversion=$(cat /etc/os-release | grep PRETTY_NAME | awk -F'=' '{print $2}' | sed 's#"##g')
|
_osversion=$(cat /etc/os-release | grep PRETTY_NAME | awk -F'=' '{print $2}' | sed 's#"##g')
|
||||||
|
|
||||||
# Warn users building the AppImage locally:
|
# Warn users building the AppImage locally:
|
||||||
if [[ ! $_osversion =~ Ubuntu\ 16.04.*\ LTS ]]; then
|
if [[ ! $_osversion =~ Ubuntu\ 18.04.*\ LTS ]]; then
|
||||||
set +x
|
set +x
|
||||||
echo ""
|
echo ""
|
||||||
# 0 1 2 3 4 5 6 7
|
# 0 1 2 3 4 5 6 7
|
||||||
# 01234567890123456789012345678901234567890123456789012345678901234567890123456789
|
# 01234567890123456789012345678901234567890123456789012345678901234567890123456789
|
||||||
echo "+===========================================================================+"
|
echo "+===========================================================================+"
|
||||||
echo "|| WARNING: You are about to build a QPDF AppImage on a system which is ||"
|
echo "|| WARNING: You are about to build a QPDF AppImage on a system which is ||"
|
||||||
echo "|| NOT Ubuntu 16.04 LTS ('Xenial'). ||"
|
echo "|| NOT Ubuntu 18.04 LTS. ||"
|
||||||
echo "|| ||"
|
echo "|| ||"
|
||||||
echo "|| It is recommended that you use a distribution that is at least a ||"
|
echo "|| It is recommended that you use a distribution that is at least a ||"
|
||||||
echo "|| few years old to maximize the number of Linux distributions the ||"
|
echo "|| few years old to maximize the number of Linux distributions the ||"
|
||||||
echo "|| resulting AppImage will work on. AppImages often don't work on ||"
|
echo "|| resulting AppImage will work on. AppImages often don't work on ||"
|
||||||
echo "|| distributions older than the one they were built on because of ||"
|
echo "|| distributions older than the one they were built on because of ||"
|
||||||
echo "|| standard library differences. ||"
|
echo "|| standard library differences. The oldest supported Ubuntu LTS is ||"
|
||||||
|
echo "|| a good option. ||"
|
||||||
echo "+===========================================================================+"
|
echo "+===========================================================================+"
|
||||||
echo ""
|
echo ""
|
||||||
set -x
|
set -x
|
||||||
|
@ -34,13 +34,9 @@ LIBTOOL=@LIBTOOL@
|
|||||||
USE_CRYPTO_NATIVE=@USE_CRYPTO_NATIVE@
|
USE_CRYPTO_NATIVE=@USE_CRYPTO_NATIVE@
|
||||||
USE_CRYPTO_OPENSSL=@USE_CRYPTO_OPENSSL@
|
USE_CRYPTO_OPENSSL=@USE_CRYPTO_OPENSSL@
|
||||||
USE_CRYPTO_GNUTLS=@USE_CRYPTO_GNUTLS@
|
USE_CRYPTO_GNUTLS=@USE_CRYPTO_GNUTLS@
|
||||||
DOCBOOKX_DTD=@DOCBOOKX_DTD@
|
SPHINX=@SPHINX@
|
||||||
FOP=@FOP@
|
|
||||||
XSLTPROC=@XSLTPROC@
|
|
||||||
XMLLINT=@XMLLINT@
|
|
||||||
BUILD_HTML=@BUILD_HTML@
|
BUILD_HTML=@BUILD_HTML@
|
||||||
BUILD_PDF=@BUILD_PDF@
|
BUILD_PDF=@BUILD_PDF@
|
||||||
VALIDATE_DOC=@VALIDATE_DOC@
|
|
||||||
OSS_FUZZ=@OSS_FUZZ@
|
OSS_FUZZ=@OSS_FUZZ@
|
||||||
QPDF_SKIP_TEST_COMPARE_IMAGES=@QPDF_SKIP_TEST_COMPARE_IMAGES@
|
QPDF_SKIP_TEST_COMPARE_IMAGES=@QPDF_SKIP_TEST_COMPARE_IMAGES@
|
||||||
BUILDRULES=@BUILDRULES@
|
BUILDRULES=@BUILDRULES@
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
e8f33e2b17d8c04fc1c160e9a92e7f1e48e433467f734629cdbb873f2d6fa676 configure.ac
|
44c66263db20dec40cefe94df4f9f9effe7410f20865cd53cf89268f6a98010f configure.ac
|
||||||
d3f9ee6f6f0846888d9a10fd3dad2e4b1258be84205426cf04d7cef02d61dad7 aclocal.m4
|
a45b129101efb46d7ac59ca2cf12d137a5742c2593ea11ebb32401aefd915b96 aclocal.m4
|
||||||
c12d837479fa9a3fa4c278b6dc7d6b449503d663e0f0d294305595a51ff43f70 libqpdf/qpdf/qpdf-config.h.in
|
c12d837479fa9a3fa4c278b6dc7d6b449503d663e0f0d294305595a51ff43f70 libqpdf/qpdf/qpdf-config.h.in
|
||||||
5297971a0ef90bcd5563eb3f7127a032bb76d3ae2af7258bf13479caf8983a60 m4/ax_cxx_compile_stdcxx.m4
|
5297971a0ef90bcd5563eb3f7127a032bb76d3ae2af7258bf13479caf8983a60 m4/ax_cxx_compile_stdcxx.m4
|
||||||
35bc5c645dc42d47f2daeea06f8f3e767c8a1aee6a35eb2b4854fd2ce66c3413 m4/ax_random_device.m4
|
35bc5c645dc42d47f2daeea06f8f3e767c8a1aee6a35eb2b4854fd2ce66c3413 m4/ax_random_device.m4
|
||||||
|
@ -3,8 +3,9 @@ set -ex
|
|||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get -y install \
|
sudo apt-get -y install \
|
||||||
autoconf build-essential zlib1g-dev libjpeg-dev libgnutls28-dev \
|
autoconf build-essential zlib1g-dev libjpeg-dev libgnutls28-dev \
|
||||||
libssl-dev docbook-xsl fop xsltproc libxml2-utils inkscape imagemagick \
|
libssl-dev python3-pip texlive-latex-extra latexmk \
|
||||||
libtiff-tools ghostscript
|
inkscape imagemagick libtiff-tools ghostscript
|
||||||
|
pip3 install sphinx
|
||||||
./configure --enable-werror --enable-doc-maintenance \
|
./configure --enable-werror --enable-doc-maintenance \
|
||||||
--enable-crypto-native --enable-crypto-openssl --enable-crypto-gnutls \
|
--enable-crypto-native --enable-crypto-openssl --enable-crypto-gnutls \
|
||||||
--enable-show-failed-test-output --enable-test-compare-images
|
--enable-show-failed-test-output --enable-test-compare-images
|
||||||
|
@ -4,7 +4,8 @@ set -ex
|
|||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get -y install \
|
sudo apt-get -y install \
|
||||||
autoconf build-essential zlib1g-dev libjpeg-dev \
|
autoconf build-essential zlib1g-dev libjpeg-dev \
|
||||||
docbook-xsl fop xsltproc libxml2-utils inkscape imagemagick
|
python3-pip texlive-latex-extra latexmk inkscape imagemagick
|
||||||
|
pip3 install sphinx
|
||||||
./configure --enable-doc-maintenance
|
./configure --enable-doc-maintenance
|
||||||
make -j$(nproc) distfiles.zip
|
make -j$(nproc) distfiles.zip
|
||||||
build-scripts/download-external-libs
|
build-scripts/download-external-libs
|
||||||
|
246
configure
vendored
246
configure
vendored
@ -631,15 +631,12 @@ ac_includes_default="\
|
|||||||
ac_subst_vars='LTLIBOBJS
|
ac_subst_vars='LTLIBOBJS
|
||||||
LIBOBJS
|
LIBOBJS
|
||||||
OSS_FUZZ
|
OSS_FUZZ
|
||||||
VALIDATE_DOC
|
|
||||||
BUILD_PDF
|
BUILD_PDF
|
||||||
BUILD_HTML
|
BUILD_HTML
|
||||||
XMLLINT
|
SPHINX
|
||||||
XSLTPROC
|
LATEXMK
|
||||||
FOP
|
PDFLATEX
|
||||||
DOCBOOKX_DTD
|
LATEX
|
||||||
DOCBOOK_FO
|
|
||||||
DOCBOOK_XHTML
|
|
||||||
SHOW_FAILED_TEST_OUTPUT
|
SHOW_FAILED_TEST_OUTPUT
|
||||||
QPDF_SKIP_TEST_COMPARE_IMAGES
|
QPDF_SKIP_TEST_COMPARE_IMAGES
|
||||||
DEFAULT_CRYPTO
|
DEFAULT_CRYPTO
|
||||||
@ -794,12 +791,9 @@ enable_crypto_gnutls
|
|||||||
with_default_crypto
|
with_default_crypto
|
||||||
enable_test_compare_images
|
enable_test_compare_images
|
||||||
enable_show_failed_test_output
|
enable_show_failed_test_output
|
||||||
with_docbook_xsl
|
|
||||||
with_docbookx_dtd
|
|
||||||
enable_doc_maintenance
|
enable_doc_maintenance
|
||||||
enable_html_doc
|
enable_html_doc
|
||||||
enable_pdf_doc
|
enable_pdf_doc
|
||||||
enable_validate_doc
|
|
||||||
enable_oss_fuzz
|
enable_oss_fuzz
|
||||||
'
|
'
|
||||||
ac_precious_vars='build_alias
|
ac_precious_vars='build_alias
|
||||||
@ -1497,7 +1491,6 @@ Optional Features:
|
|||||||
if set, enables all documentation options
|
if set, enables all documentation options
|
||||||
--enable-html-doc whether to build HTML documents
|
--enable-html-doc whether to build HTML documents
|
||||||
--enable-pdf-doc whether to build PDF documents
|
--enable-pdf-doc whether to build PDF documents
|
||||||
--enable-validate-doc whether to validate xml document source
|
|
||||||
--enable-oss-fuzz if set, build static fuzzers for oss-fuzz
|
--enable-oss-fuzz if set, build static fuzzers for oss-fuzz
|
||||||
|
|
||||||
Optional Packages:
|
Optional Packages:
|
||||||
@ -1523,9 +1516,6 @@ Optional Packages:
|
|||||||
--with-default-crypto=provider
|
--with-default-crypto=provider
|
||||||
which crypto provider to use by default; see
|
which crypto provider to use by default; see
|
||||||
README.md
|
README.md
|
||||||
--with-docbook-xsl=DIR location of docbook 4.x xml stylesheets
|
|
||||||
--with-docbookx-dtd=FILE
|
|
||||||
location of docbook 4.x xml DTD
|
|
||||||
|
|
||||||
Some influential environment variables:
|
Some influential environment variables:
|
||||||
CC C compiler command
|
CC C compiler command
|
||||||
@ -2650,8 +2640,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
|
|||||||
|
|
||||||
ac_config_files="$ac_config_files autoconf.mk"
|
ac_config_files="$ac_config_files autoconf.mk"
|
||||||
|
|
||||||
ac_config_files="$ac_config_files manual/html.xsl manual/print.xsl"
|
|
||||||
|
|
||||||
ac_config_files="$ac_config_files libqpdf.pc"
|
ac_config_files="$ac_config_files libqpdf.pc"
|
||||||
|
|
||||||
ac_config_files="$ac_config_files libqpdf.map"
|
ac_config_files="$ac_config_files libqpdf.map"
|
||||||
@ -18449,69 +18437,15 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Extract the first word of "latex", so it can be a program name with args.
|
||||||
# Check whether --with-docbook-xsl was given.
|
set dummy latex; ac_word=$2
|
||||||
if test "${with_docbook_xsl+set}" = set; then :
|
|
||||||
withval=$with_docbook_xsl; DOCBOOK_XSL=$withval
|
|
||||||
else
|
|
||||||
DOCBOOK_XSL=/usr/share/xml/docbook/stylesheet/nwalsh
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
DOCBOOK_XHTML=
|
|
||||||
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for xml to xhtml docbook stylesheets" >&5
|
|
||||||
$as_echo_n "checking for xml to xhtml docbook stylesheets... " >&6; }
|
|
||||||
if test -f "$DOCBOOK_XSL/xhtml/docbook.xsl"; then
|
|
||||||
DOCBOOK_XHTML="$DOCBOOK_XSL/xhtml/docbook.xsl"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOCBOOK_XHTML" >&5
|
|
||||||
$as_echo "$DOCBOOK_XHTML" >&6; }
|
|
||||||
else
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
|
||||||
$as_echo "no" >&6; }
|
|
||||||
fi
|
|
||||||
DOCBOOK_FO=
|
|
||||||
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for xml to fo docbook stylesheets" >&5
|
|
||||||
$as_echo_n "checking for xml to fo docbook stylesheets... " >&6; }
|
|
||||||
if test -f "$DOCBOOK_XSL/fo/docbook.xsl"; then
|
|
||||||
DOCBOOK_FO="$DOCBOOK_XSL/fo/docbook.xsl"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOCBOOK_FO" >&5
|
|
||||||
$as_echo "$DOCBOOK_FO" >&6; }
|
|
||||||
else
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
|
||||||
$as_echo "no" >&6; }
|
|
||||||
fi
|
|
||||||
|
|
||||||
DOCBOOKX_DTD=
|
|
||||||
|
|
||||||
|
|
||||||
# Check whether --with-docbookx-dtd was given.
|
|
||||||
if test "${with_docbookx_dtd+set}" = set; then :
|
|
||||||
withval=$with_docbookx_dtd; DOCBOOKX_DTD=$withval
|
|
||||||
else
|
|
||||||
DOCBOOKX_DTD=/usr/share/xml/docbook/schema/dtd/4/docbookx.dtd
|
|
||||||
fi
|
|
||||||
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for docbook 4.x xml DTD" >&5
|
|
||||||
$as_echo_n "checking for docbook 4.x xml DTD... " >&6; }
|
|
||||||
if test -f "$DOCBOOKX_DTD"; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOCBOOKX_DTD" >&5
|
|
||||||
$as_echo "$DOCBOOKX_DTD" >&6; }
|
|
||||||
else
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
|
||||||
$as_echo "no" >&6; }
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Extract the first word of "fop", so it can be a program name with args.
|
|
||||||
set dummy fop; ac_word=$2
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||||
$as_echo_n "checking for $ac_word... " >&6; }
|
$as_echo_n "checking for $ac_word... " >&6; }
|
||||||
if ${ac_cv_prog_FOP+:} false; then :
|
if ${ac_cv_prog_LATEX+:} false; then :
|
||||||
$as_echo_n "(cached) " >&6
|
$as_echo_n "(cached) " >&6
|
||||||
else
|
else
|
||||||
if test -n "$FOP"; then
|
if test -n "$LATEX"; then
|
||||||
ac_cv_prog_FOP="$FOP" # Let the user override the test.
|
ac_cv_prog_LATEX="$LATEX" # Let the user override the test.
|
||||||
else
|
else
|
||||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||||
for as_dir in $PATH
|
for as_dir in $PATH
|
||||||
@ -18520,7 +18454,7 @@ do
|
|||||||
test -z "$as_dir" && as_dir=.
|
test -z "$as_dir" && as_dir=.
|
||||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||||
ac_cv_prog_FOP="fop"
|
ac_cv_prog_LATEX="latex"
|
||||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||||
break 2
|
break 2
|
||||||
fi
|
fi
|
||||||
@ -18530,25 +18464,25 @@ IFS=$as_save_IFS
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
FOP=$ac_cv_prog_FOP
|
LATEX=$ac_cv_prog_LATEX
|
||||||
if test -n "$FOP"; then
|
if test -n "$LATEX"; then
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LATEX" >&5
|
||||||
$as_echo "$FOP" >&6; }
|
$as_echo "$LATEX" >&6; }
|
||||||
else
|
else
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||||
$as_echo "no" >&6; }
|
$as_echo "no" >&6; }
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# Extract the first word of "xsltproc", so it can be a program name with args.
|
# Extract the first word of "pdflatex", so it can be a program name with args.
|
||||||
set dummy xsltproc; ac_word=$2
|
set dummy pdflatex; ac_word=$2
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||||
$as_echo_n "checking for $ac_word... " >&6; }
|
$as_echo_n "checking for $ac_word... " >&6; }
|
||||||
if ${ac_cv_prog_XSLTPROC+:} false; then :
|
if ${ac_cv_prog_PDFLATEX+:} false; then :
|
||||||
$as_echo_n "(cached) " >&6
|
$as_echo_n "(cached) " >&6
|
||||||
else
|
else
|
||||||
if test -n "$XSLTPROC"; then
|
if test -n "$PDFLATEX"; then
|
||||||
ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
|
ac_cv_prog_PDFLATEX="$PDFLATEX" # Let the user override the test.
|
||||||
else
|
else
|
||||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||||
for as_dir in $PATH
|
for as_dir in $PATH
|
||||||
@ -18557,7 +18491,7 @@ do
|
|||||||
test -z "$as_dir" && as_dir=.
|
test -z "$as_dir" && as_dir=.
|
||||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||||
ac_cv_prog_XSLTPROC="xsltproc"
|
ac_cv_prog_PDFLATEX="pdflatex"
|
||||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||||
break 2
|
break 2
|
||||||
fi
|
fi
|
||||||
@ -18567,25 +18501,25 @@ IFS=$as_save_IFS
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
XSLTPROC=$ac_cv_prog_XSLTPROC
|
PDFLATEX=$ac_cv_prog_PDFLATEX
|
||||||
if test -n "$XSLTPROC"; then
|
if test -n "$PDFLATEX"; then
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PDFLATEX" >&5
|
||||||
$as_echo "$XSLTPROC" >&6; }
|
$as_echo "$PDFLATEX" >&6; }
|
||||||
else
|
else
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||||
$as_echo "no" >&6; }
|
$as_echo "no" >&6; }
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# Extract the first word of "xmllint", so it can be a program name with args.
|
# Extract the first word of "latexmk", so it can be a program name with args.
|
||||||
set dummy xmllint; ac_word=$2
|
set dummy latexmk; ac_word=$2
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||||
$as_echo_n "checking for $ac_word... " >&6; }
|
$as_echo_n "checking for $ac_word... " >&6; }
|
||||||
if ${ac_cv_prog_XMLLINT+:} false; then :
|
if ${ac_cv_prog_LATEXMK+:} false; then :
|
||||||
$as_echo_n "(cached) " >&6
|
$as_echo_n "(cached) " >&6
|
||||||
else
|
else
|
||||||
if test -n "$XMLLINT"; then
|
if test -n "$LATEXMK"; then
|
||||||
ac_cv_prog_XMLLINT="$XMLLINT" # Let the user override the test.
|
ac_cv_prog_LATEXMK="$LATEXMK" # Let the user override the test.
|
||||||
else
|
else
|
||||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||||
for as_dir in $PATH
|
for as_dir in $PATH
|
||||||
@ -18594,7 +18528,7 @@ do
|
|||||||
test -z "$as_dir" && as_dir=.
|
test -z "$as_dir" && as_dir=.
|
||||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||||
ac_cv_prog_XMLLINT="xmllint"
|
ac_cv_prog_LATEXMK="latexmk"
|
||||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||||
break 2
|
break 2
|
||||||
fi
|
fi
|
||||||
@ -18604,10 +18538,47 @@ IFS=$as_save_IFS
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
XMLLINT=$ac_cv_prog_XMLLINT
|
LATEXMK=$ac_cv_prog_LATEXMK
|
||||||
if test -n "$XMLLINT"; then
|
if test -n "$LATEXMK"; then
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LATEXMK" >&5
|
||||||
$as_echo "$XMLLINT" >&6; }
|
$as_echo "$LATEXMK" >&6; }
|
||||||
|
else
|
||||||
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||||
|
$as_echo "no" >&6; }
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Extract the first word of "sphinx-build", so it can be a program name with args.
|
||||||
|
set dummy sphinx-build; ac_word=$2
|
||||||
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||||
|
$as_echo_n "checking for $ac_word... " >&6; }
|
||||||
|
if ${ac_cv_prog_SPHINX+:} false; then :
|
||||||
|
$as_echo_n "(cached) " >&6
|
||||||
|
else
|
||||||
|
if test -n "$SPHINX"; then
|
||||||
|
ac_cv_prog_SPHINX="$SPHINX" # Let the user override the test.
|
||||||
|
else
|
||||||
|
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||||
|
for as_dir in $PATH
|
||||||
|
do
|
||||||
|
IFS=$as_save_IFS
|
||||||
|
test -z "$as_dir" && as_dir=.
|
||||||
|
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||||
|
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||||
|
ac_cv_prog_SPHINX="sphinx-build"
|
||||||
|
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||||
|
break 2
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
done
|
||||||
|
IFS=$as_save_IFS
|
||||||
|
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
SPHINX=$ac_cv_prog_SPHINX
|
||||||
|
if test -n "$SPHINX"; then
|
||||||
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SPHINX" >&5
|
||||||
|
$as_echo "$SPHINX" >&6; }
|
||||||
else
|
else
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||||
$as_echo "no" >&6; }
|
$as_echo "no" >&6; }
|
||||||
@ -18653,19 +18624,6 @@ else
|
|||||||
BUILD_PDF=$doc_default
|
BUILD_PDF=$doc_default
|
||||||
fi
|
fi
|
||||||
|
|
||||||
VALIDATE_DOC=0
|
|
||||||
|
|
||||||
# Check whether --enable-validate-doc was given.
|
|
||||||
if test "${enable_validate_doc+set}" = set; then :
|
|
||||||
enableval=$enable_validate_doc; if test "$enableval" = "yes"; then
|
|
||||||
VALIDATE_DOC=1;
|
|
||||||
else
|
|
||||||
VALIDATE_DOC=0;
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
VALIDATE_DOC=$doc_default
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Check whether --enable-oss-fuzz was given.
|
# Check whether --enable-oss-fuzz was given.
|
||||||
@ -18680,38 +18638,31 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
if test "$VALIDATE_DOC" = "1"; then
|
|
||||||
if test "$XMLLINT" = ""; then
|
|
||||||
MISSING_XMLLINT=1
|
|
||||||
MISSING_ANY=1
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
if test "$BUILD_HTML" = "1"; then
|
if test "$BUILD_HTML" = "1"; then
|
||||||
if test "$XSLTPROC" = ""; then
|
if test "$SPHINX" = ""; then
|
||||||
MISSING_XSLTPROC=1
|
MISSING_SPHINX=1
|
||||||
MISSING_ANY=1
|
|
||||||
fi
|
|
||||||
if test "$DOCBOOK_XHTML" = ""; then
|
|
||||||
MISSING_DOCBOOK_XHTML=1
|
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
if test "$BUILD_PDF" = "1"; then
|
if test "$BUILD_PDF" = "1"; then
|
||||||
if test "$XSLTPROC" = ""; then
|
if test "$SPHINX" = ""; then
|
||||||
MISSING_XSLTPROC=1
|
MISSING_SPHINX=1
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
if test "$DOCBOOK_FO" = ""; then
|
if test "$LATEX" = ""; then
|
||||||
MISSING_DOCBOOK_FO=1
|
MISSING_LATEX=1
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
if test "$FOP" = ""; then
|
if test "$LATEXMK" = ""; then
|
||||||
MISSING_FOP=1
|
MISSING_LATEXMK=1
|
||||||
|
MISSING_ANY=1
|
||||||
|
fi
|
||||||
|
if test "$PDFLATEX" = ""; then
|
||||||
|
MISSING_PDFLATEX=1
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
if test "$MISSING_ANY" = "1"; then
|
if test "$MISSING_ANY" = "1"; then
|
||||||
ISSUE_WARNINGS=1
|
ISSUE_WARNINGS=1
|
||||||
fi
|
fi
|
||||||
@ -18745,29 +18696,24 @@ if test "$MISSING_JPEG" = "1"; then
|
|||||||
$as_echo "$as_me: WARNING: unable to find required library jpeg" >&2;}
|
$as_echo "$as_me: WARNING: unable to find required library jpeg" >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_DOCBOOK_FO" = "1"; then
|
if test "$MISSING_LATEX" = "1"; then
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: docbook fo stylesheets are required to build PDF documentation" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: latex is required to build PDF documentation" >&5
|
||||||
$as_echo "$as_me: WARNING: docbook fo stylesheets are required to build PDF documentation" >&2;}
|
$as_echo "$as_me: WARNING: latex is required to build PDF documentation" >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_DOCBOOK_XHTML" = "1"; then
|
if test "$MISSING_LATEXMK" = "1"; then
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: docbook xhmtl stylesheets are required to build HTML documentation" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: latexmk is required to build PDF documentation" >&5
|
||||||
$as_echo "$as_me: WARNING: docbook xhmtl stylesheets are required to build HTML documentation" >&2;}
|
$as_echo "$as_me: WARNING: latexmk is required to build PDF documentation" >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_FOP" = "1"; then
|
if test "$MISSING_PDFLATEX" = "1"; then
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: apache fop is required to build PDF documentation" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pdflatex is required to build PDF documentation" >&5
|
||||||
$as_echo "$as_me: WARNING: apache fop is required to build PDF documentation" >&2;}
|
$as_echo "$as_me: WARNING: pdflatex is required to build PDF documentation" >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_XMLLINT" = "1"; then
|
if test "$MISSING_SPHINX" = "1"; then
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: xmllint is required to validate documentation" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: sphinx-build is required to build documentation" >&5
|
||||||
$as_echo "$as_me: WARNING: xmllint is required to validate documentation" >&2;}
|
$as_echo "$as_me: WARNING: sphinx-build is required to build documentation" >&2;}
|
||||||
fi
|
|
||||||
|
|
||||||
if test "$MISSING_XSLTPROC" = "1"; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: xsltproc is required to build documentation" >&5
|
|
||||||
$as_echo "$as_me: WARNING: xsltproc is required to build documentation" >&2;}
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$ISSUE_WARNINGS" = "1"; then
|
if test "$ISSUE_WARNINGS" = "1"; then
|
||||||
@ -19871,8 +19817,6 @@ for ac_config_target in $ac_config_targets
|
|||||||
do
|
do
|
||||||
case $ac_config_target in
|
case $ac_config_target in
|
||||||
"autoconf.mk") CONFIG_FILES="$CONFIG_FILES autoconf.mk" ;;
|
"autoconf.mk") CONFIG_FILES="$CONFIG_FILES autoconf.mk" ;;
|
||||||
"manual/html.xsl") CONFIG_FILES="$CONFIG_FILES manual/html.xsl" ;;
|
|
||||||
"manual/print.xsl") CONFIG_FILES="$CONFIG_FILES manual/print.xsl" ;;
|
|
||||||
"libqpdf.pc") CONFIG_FILES="$CONFIG_FILES libqpdf.pc" ;;
|
"libqpdf.pc") CONFIG_FILES="$CONFIG_FILES libqpdf.pc" ;;
|
||||||
"libqpdf.map") CONFIG_FILES="$CONFIG_FILES libqpdf.map" ;;
|
"libqpdf.map") CONFIG_FILES="$CONFIG_FILES libqpdf.map" ;;
|
||||||
"libqpdf/qpdf/qpdf-config.h") CONFIG_HEADERS="$CONFIG_HEADERS libqpdf/qpdf/qpdf-config.h" ;;
|
"libqpdf/qpdf/qpdf-config.h") CONFIG_HEADERS="$CONFIG_HEADERS libqpdf/qpdf/qpdf-config.h" ;;
|
||||||
|
109
configure.ac
109
configure.ac
@ -6,7 +6,6 @@ AC_INIT([qpdf],[10.4.0])
|
|||||||
|
|
||||||
AC_CONFIG_MACRO_DIR([m4])
|
AC_CONFIG_MACRO_DIR([m4])
|
||||||
AC_CONFIG_FILES([autoconf.mk])
|
AC_CONFIG_FILES([autoconf.mk])
|
||||||
AC_CONFIG_FILES([manual/html.xsl manual/print.xsl])
|
|
||||||
AC_CONFIG_FILES([libqpdf.pc])
|
AC_CONFIG_FILES([libqpdf.pc])
|
||||||
AC_CONFIG_FILES([libqpdf.map])
|
AC_CONFIG_FILES([libqpdf.map])
|
||||||
AC_CONFIG_HEADERS([libqpdf/qpdf/qpdf-config.h])
|
AC_CONFIG_HEADERS([libqpdf/qpdf/qpdf-config.h])
|
||||||
@ -795,48 +794,10 @@ AC_ARG_ENABLE(show-failed-test-output,
|
|||||||
fi],
|
fi],
|
||||||
[SHOW_FAILED_TEST_OUTPUT=0])
|
[SHOW_FAILED_TEST_OUTPUT=0])
|
||||||
|
|
||||||
AC_ARG_WITH(docbook-xsl,
|
AC_CHECK_PROG(LATEX,latex,latex,[])
|
||||||
AS_HELP_STRING([--with-docbook-xsl=DIR],
|
AC_CHECK_PROG(PDFLATEX,pdflatex,pdflatex,[])
|
||||||
[location of docbook 4.x xml stylesheets]),
|
AC_CHECK_PROG(LATEXMK,latexmk,latexmk,[])
|
||||||
[DOCBOOK_XSL=$withval],
|
AC_CHECK_PROG(SPHINX,sphinx-build,sphinx-build,[])
|
||||||
[DOCBOOK_XSL=/usr/share/xml/docbook/stylesheet/nwalsh])
|
|
||||||
|
|
||||||
DOCBOOK_XHTML=
|
|
||||||
AC_SUBST(DOCBOOK_XHTML)
|
|
||||||
AC_MSG_CHECKING(for xml to xhtml docbook stylesheets)
|
|
||||||
if test -f "$DOCBOOK_XSL/xhtml/docbook.xsl"; then
|
|
||||||
DOCBOOK_XHTML="$DOCBOOK_XSL/xhtml/docbook.xsl"
|
|
||||||
AC_MSG_RESULT($DOCBOOK_XHTML)
|
|
||||||
else
|
|
||||||
AC_MSG_RESULT(no)
|
|
||||||
fi
|
|
||||||
DOCBOOK_FO=
|
|
||||||
AC_SUBST(DOCBOOK_FO)
|
|
||||||
AC_MSG_CHECKING(for xml to fo docbook stylesheets)
|
|
||||||
if test -f "$DOCBOOK_XSL/fo/docbook.xsl"; then
|
|
||||||
DOCBOOK_FO="$DOCBOOK_XSL/fo/docbook.xsl"
|
|
||||||
AC_MSG_RESULT($DOCBOOK_FO)
|
|
||||||
else
|
|
||||||
AC_MSG_RESULT(no)
|
|
||||||
fi
|
|
||||||
|
|
||||||
DOCBOOKX_DTD=
|
|
||||||
AC_SUBST(DOCBOOKX_DTD)
|
|
||||||
AC_ARG_WITH(docbookx-dtd,
|
|
||||||
AS_HELP_STRING([--with-docbookx-dtd=FILE],
|
|
||||||
[location of docbook 4.x xml DTD]),
|
|
||||||
[DOCBOOKX_DTD=$withval],
|
|
||||||
[DOCBOOKX_DTD=/usr/share/xml/docbook/schema/dtd/4/docbookx.dtd])
|
|
||||||
AC_MSG_CHECKING(for docbook 4.x xml DTD)
|
|
||||||
if test -f "$DOCBOOKX_DTD"; then
|
|
||||||
AC_MSG_RESULT($DOCBOOKX_DTD)
|
|
||||||
else
|
|
||||||
AC_MSG_RESULT(no)
|
|
||||||
fi
|
|
||||||
|
|
||||||
AC_CHECK_PROG(FOP,fop,fop,[])
|
|
||||||
AC_CHECK_PROG(XSLTPROC,xsltproc,xsltproc,[])
|
|
||||||
AC_CHECK_PROG(XMLLINT,xmllint,xmllint,[])
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(doc-maintenance,
|
AC_ARG_ENABLE(doc-maintenance,
|
||||||
AS_HELP_STRING([--enable-doc-maintenance],
|
AS_HELP_STRING([--enable-doc-maintenance],
|
||||||
@ -870,17 +831,6 @@ AC_ARG_ENABLE(pdf-doc,
|
|||||||
BUILD_PDF=0;
|
BUILD_PDF=0;
|
||||||
fi],
|
fi],
|
||||||
[BUILD_PDF=$doc_default])
|
[BUILD_PDF=$doc_default])
|
||||||
VALIDATE_DOC=0
|
|
||||||
AC_SUBST(VALIDATE_DOC)
|
|
||||||
AC_ARG_ENABLE(validate-doc,
|
|
||||||
AS_HELP_STRING([--enable-validate-doc],
|
|
||||||
[whether to validate xml document source]),
|
|
||||||
[if test "$enableval" = "yes"; then
|
|
||||||
VALIDATE_DOC=1;
|
|
||||||
else
|
|
||||||
VALIDATE_DOC=0;
|
|
||||||
fi],
|
|
||||||
[VALIDATE_DOC=$doc_default])
|
|
||||||
|
|
||||||
AC_SUBST(OSS_FUZZ)
|
AC_SUBST(OSS_FUZZ)
|
||||||
AC_ARG_ENABLE(oss-fuzz,
|
AC_ARG_ENABLE(oss-fuzz,
|
||||||
@ -893,38 +843,31 @@ AC_ARG_ENABLE(oss-fuzz,
|
|||||||
fi],
|
fi],
|
||||||
[OSS_FUZZ=0])
|
[OSS_FUZZ=0])
|
||||||
|
|
||||||
if test "$VALIDATE_DOC" = "1"; then
|
|
||||||
if test "$XMLLINT" = ""; then
|
|
||||||
MISSING_XMLLINT=1
|
|
||||||
MISSING_ANY=1
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
if test "$BUILD_HTML" = "1"; then
|
if test "$BUILD_HTML" = "1"; then
|
||||||
if test "$XSLTPROC" = ""; then
|
if test "$SPHINX" = ""; then
|
||||||
MISSING_XSLTPROC=1
|
MISSING_SPHINX=1
|
||||||
MISSING_ANY=1
|
|
||||||
fi
|
|
||||||
if test "$DOCBOOK_XHTML" = ""; then
|
|
||||||
MISSING_DOCBOOK_XHTML=1
|
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
if test "$BUILD_PDF" = "1"; then
|
if test "$BUILD_PDF" = "1"; then
|
||||||
if test "$XSLTPROC" = ""; then
|
if test "$SPHINX" = ""; then
|
||||||
MISSING_XSLTPROC=1
|
MISSING_SPHINX=1
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
if test "$DOCBOOK_FO" = ""; then
|
if test "$LATEX" = ""; then
|
||||||
MISSING_DOCBOOK_FO=1
|
MISSING_LATEX=1
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
if test "$FOP" = ""; then
|
if test "$LATEXMK" = ""; then
|
||||||
MISSING_FOP=1
|
MISSING_LATEXMK=1
|
||||||
|
MISSING_ANY=1
|
||||||
|
fi
|
||||||
|
if test "$PDFLATEX" = ""; then
|
||||||
|
MISSING_PDFLATEX=1
|
||||||
MISSING_ANY=1
|
MISSING_ANY=1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
if test "$MISSING_ANY" = "1"; then
|
if test "$MISSING_ANY" = "1"; then
|
||||||
ISSUE_WARNINGS=1
|
ISSUE_WARNINGS=1
|
||||||
fi
|
fi
|
||||||
@ -953,24 +896,20 @@ if test "$MISSING_JPEG" = "1"; then
|
|||||||
AC_MSG_WARN(unable to find required library jpeg)
|
AC_MSG_WARN(unable to find required library jpeg)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_DOCBOOK_FO" = "1"; then
|
if test "$MISSING_LATEX" = "1"; then
|
||||||
AC_MSG_WARN(docbook fo stylesheets are required to build PDF documentation)
|
AC_MSG_WARN(latex is required to build PDF documentation)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_DOCBOOK_XHTML" = "1"; then
|
if test "$MISSING_LATEXMK" = "1"; then
|
||||||
AC_MSG_WARN(docbook xhmtl stylesheets are required to build HTML documentation)
|
AC_MSG_WARN(latexmk is required to build PDF documentation)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_FOP" = "1"; then
|
if test "$MISSING_PDFLATEX" = "1"; then
|
||||||
AC_MSG_WARN(apache fop is required to build PDF documentation)
|
AC_MSG_WARN(pdflatex is required to build PDF documentation)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$MISSING_XMLLINT" = "1"; then
|
if test "$MISSING_SPHINX" = "1"; then
|
||||||
AC_MSG_WARN(xmllint is required to validate documentation)
|
AC_MSG_WARN(sphinx-build is required to build documentation)
|
||||||
fi
|
|
||||||
|
|
||||||
if test "$MISSING_XSLTPROC" = "1"; then
|
|
||||||
AC_MSG_WARN(xsltproc is required to build documentation)
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$ISSUE_WARNINGS" = "1"; then
|
if test "$ISSUE_WARNINGS" = "1"; then
|
||||||
|
@ -17,9 +17,10 @@ installwin: all
|
|||||||
cp qpdf/$(OUTPUT_DIR)/fix-qdf.exe $(DEST)/bin
|
cp qpdf/$(OUTPUT_DIR)/fix-qdf.exe $(DEST)/bin
|
||||||
cp include/qpdf/*.h $(DEST)/include/qpdf
|
cp include/qpdf/*.h $(DEST)/include/qpdf
|
||||||
cp include/qpdf/*.hh $(DEST)/include/qpdf
|
cp include/qpdf/*.hh $(DEST)/include/qpdf
|
||||||
cp doc/stylesheet.css $(DEST)/doc
|
|
||||||
if [ -f doc/qpdf-manual.html ]; then \
|
if [ -f doc/qpdf-manual.html ]; then \
|
||||||
|
mkdir $(DEST)/doc/_static; \
|
||||||
cp doc/qpdf-manual.html $(DEST)/doc; \
|
cp doc/qpdf-manual.html $(DEST)/doc; \
|
||||||
|
cp doc/_static/* $(DEST)/doc/_static; \
|
||||||
fi
|
fi
|
||||||
if [ -f doc/qpdf-manual.pdf ]; then \
|
if [ -f doc/qpdf-manual.pdf ]; then \
|
||||||
cp doc/qpdf-manual.pdf $(DEST)/doc; \
|
cp doc/qpdf-manual.pdf $(DEST)/doc; \
|
||||||
|
@ -120,6 +120,12 @@ install-libs: build_libqpdf
|
|||||||
|
|
||||||
# NOTE: If installing any new executables, remember to update the
|
# NOTE: If installing any new executables, remember to update the
|
||||||
# lambda layer code in build-scripts/build-appimage.
|
# lambda layer code in build-scripts/build-appimage.
|
||||||
|
|
||||||
|
# NOTE: See comments in manual/build.mk about html documentation.
|
||||||
|
|
||||||
|
# Ensure that installwin in make/installwin.mk is consistent with
|
||||||
|
# this.
|
||||||
|
|
||||||
install: all install-libs
|
install: all install-libs
|
||||||
./mkinstalldirs -m 0755 $(DESTDIR)$(bindir)
|
./mkinstalldirs -m 0755 $(DESTDIR)$(bindir)
|
||||||
./mkinstalldirs -m 0755 $(DESTDIR)$(docdir)
|
./mkinstalldirs -m 0755 $(DESTDIR)$(docdir)
|
||||||
@ -133,9 +139,10 @@ install: all install-libs
|
|||||||
$(LIBTOOL) --mode=install ./install-sh \
|
$(LIBTOOL) --mode=install ./install-sh \
|
||||||
qpdf/$(OUTPUT_DIR)/fix-qdf \
|
qpdf/$(OUTPUT_DIR)/fix-qdf \
|
||||||
$(DESTDIR)$(bindir)/fix-qdf
|
$(DESTDIR)$(bindir)/fix-qdf
|
||||||
./install-sh -m 0644 doc/stylesheet.css $(DESTDIR)$(docdir)
|
|
||||||
if [ -f doc/qpdf-manual.html ]; then \
|
if [ -f doc/qpdf-manual.html ]; then \
|
||||||
|
./mkinstalldirs -m 0755 $(DESTDIR)$(docdir)/_static; \
|
||||||
./install-sh -m 0644 doc/qpdf-manual.html $(DESTDIR)$(docdir); \
|
./install-sh -m 0644 doc/qpdf-manual.html $(DESTDIR)$(docdir); \
|
||||||
|
./install-sh -m 0644 doc/_static/* $(DESTDIR)$(docdir)/_static; \
|
||||||
fi
|
fi
|
||||||
if [ -f doc/qpdf-manual.pdf ]; then \
|
if [ -f doc/qpdf-manual.pdf ]; then \
|
||||||
./install-sh -m 0644 doc/qpdf-manual.pdf $(DESTDIR)$(docdir); \
|
./install-sh -m 0644 doc/qpdf-manual.pdf $(DESTDIR)$(docdir); \
|
||||||
|
@ -78,7 +78,7 @@ if ($version ne $code_version)
|
|||||||
}
|
}
|
||||||
if ($version ne $doc_version)
|
if ($version ne $doc_version)
|
||||||
{
|
{
|
||||||
print "$whoami: qpdf-manual.xml version = $doc_version\n";
|
print "$whoami: doc version = $doc_version\n";
|
||||||
$version_error = 1;
|
$version_error = 1;
|
||||||
}
|
}
|
||||||
if ($version ne $cli_version)
|
if ($version ne $cli_version)
|
||||||
@ -153,11 +153,11 @@ sub get_version_from_source
|
|||||||
|
|
||||||
sub get_version_from_manual
|
sub get_version_from_manual
|
||||||
{
|
{
|
||||||
my $fh = safe_open("manual/qpdf-manual.xml");
|
my $fh = safe_open("manual/conf.py");
|
||||||
my $doc_version = 'unknown';
|
my $doc_version = 'unknown';
|
||||||
while (<$fh>)
|
while (<$fh>)
|
||||||
{
|
{
|
||||||
if (m/swversion "([^\"]+)\"/)
|
if (m/release = '([^\']+)\'/)
|
||||||
{
|
{
|
||||||
$doc_version = $1;
|
$doc_version = $1;
|
||||||
last;
|
last;
|
||||||
|
@ -1,45 +1,55 @@
|
|||||||
INDOC = manual/qpdf-manual
|
DOC_OUT := manual/$(OUTPUT_DIR)
|
||||||
OUTDOC = manual/$(OUTPUT_DIR)/qpdf-manual
|
S_HTML_OUT := $(DOC_OUT)/singlehtml
|
||||||
|
S_HTML_TARGET := $(S_HTML_OUT)/index.html
|
||||||
|
HTML_OUT := $(DOC_OUT)/html
|
||||||
|
HTML_TARGET := $(HTML_OUT)/index.html
|
||||||
|
PDF_OUT := $(DOC_OUT)/latex
|
||||||
|
PDF_TARGET := $(PDF_OUT)/qpdf.pdf
|
||||||
|
|
||||||
TARGETS_manual := doc/qpdf.1 doc/fix-qdf.1 doc/zlib-flate.1
|
TARGETS_manual := doc/qpdf.1 doc/fix-qdf.1 doc/zlib-flate.1
|
||||||
ifeq ($(BUILD_HTML),1)
|
ifeq ($(BUILD_HTML),1)
|
||||||
TARGETS_manual += doc/qpdf-manual.html
|
TARGETS_manual += doc/qpdf-manual.html $(HTML_TARGET)
|
||||||
endif
|
endif
|
||||||
ifeq ($(BUILD_PDF),1)
|
ifeq ($(BUILD_PDF),1)
|
||||||
TARGETS_manual += doc/qpdf-manual.pdf
|
TARGETS_manual += doc/qpdf-manual.pdf
|
||||||
endif
|
endif
|
||||||
|
|
||||||
VALIDATE=manual/$(OUTPUT_DIR)/validate
|
# Prevent targets that run $(SPHINX) from running in parallel by using
|
||||||
|
# order-only dependencies (the dependencies listed after the |) to
|
||||||
|
# avoid clashes in temporary files that cause the build to fail with
|
||||||
|
# the error "_pickle.UnpicklingError: pickle data was truncated"
|
||||||
|
$(HTML_TARGET): manual/index.rst
|
||||||
|
$(SPHINX) -M html manual $(DOC_OUT) -W
|
||||||
|
|
||||||
ifeq ($(VALIDATE_DOC),1)
|
$(S_HTML_TARGET): manual/index.rst | $(HTML_TARGET)
|
||||||
|
$(SPHINX) -M singlehtml manual $(DOC_OUT) -W
|
||||||
|
|
||||||
$(VALIDATE): $(INDOC).xml
|
$(PDF_TARGET): manual/index.rst | $(S_HTML_TARGET) $(HTML_TARGET)
|
||||||
$(XMLLINT) --noout --dtdvalid $(DOCBOOKX_DTD) $<
|
$(SPHINX) -M latexpdf manual $(DOC_OUT) -W
|
||||||
touch $(VALIDATE)
|
|
||||||
|
|
||||||
else
|
# This depends on sphinx-build's singlehtml target creating index.html
|
||||||
|
# and a _static directory. If that changes, this code has to be
|
||||||
|
# adjusted. It will also be necessary to adjust the install target in
|
||||||
|
# make/libtool.mk.
|
||||||
|
doc/qpdf-manual.html: $(S_HTML_TARGET)
|
||||||
|
mkdir -p doc
|
||||||
|
@if [ "$(shell find $(S_HTML_OUT)/ -mindepth 1 -type d -print)" != \
|
||||||
|
"$(S_HTML_OUT)/_static" ]; then \
|
||||||
|
echo "***"; \
|
||||||
|
echo Expected only directory in $(S_HTML_OUT) to be _static; \
|
||||||
|
echo "***"; \
|
||||||
|
false; \
|
||||||
|
fi
|
||||||
|
cp $< $@
|
||||||
|
mkdir -p doc/_static
|
||||||
|
cp -p $(S_HTML_OUT)/_static/* doc/_static
|
||||||
|
|
||||||
$(VALIDATE):
|
doc/qpdf-manual.pdf: $(PDF_TARGET)
|
||||||
touch $(VALIDATE)
|
mkdir -p doc
|
||||||
|
cp $< $@
|
||||||
endif
|
|
||||||
|
|
||||||
$(OUTDOC).pdf: $(OUTDOC).fo qpdf/build/qpdf
|
|
||||||
$(FOP) $< -pdf $@.tmp
|
|
||||||
qpdf/build/qpdf --linearize --object-streams=generate \
|
|
||||||
--recompress-flate --compression-level=9 $@.tmp $@
|
|
||||||
|
|
||||||
$(OUTDOC).html: $(INDOC).xml manual/html.xsl $(VALIDATE)
|
|
||||||
$(XSLTPROC) --output $@ manual/html.xsl $<
|
|
||||||
|
|
||||||
.PRECIOUS: $(OUTDOC).fo
|
|
||||||
$(OUTDOC).fo: $(INDOC).xml manual/print.xsl $(VALIDATE)
|
|
||||||
$(XSLTPROC) --output $@ manual/print.xsl $<
|
|
||||||
|
|
||||||
doc/%.1: manual/%.1.in
|
doc/%.1: manual/%.1.in
|
||||||
|
mkdir -p doc
|
||||||
sed -e 's:@PACKAGE_VERSION@:$(PACKAGE_VERSION):g' \
|
sed -e 's:@PACKAGE_VERSION@:$(PACKAGE_VERSION):g' \
|
||||||
-e 's:@docdir@:$(docdir):g' \
|
-e 's:@docdir@:$(docdir):g' \
|
||||||
< $< > $@
|
< $< > $@
|
||||||
|
|
||||||
doc/%: manual/$(OUTPUT_DIR)/%
|
|
||||||
cp $< $@
|
|
||||||
|
Loading…
Reference in New Issue
Block a user