From d4ba6302c25d5c7667b88addf2dd5e0736d3b6b5 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Fri, 13 Nov 2020 12:14:42 +0100 Subject: [PATCH] Run libxml-based tools with --nonet option by default --- doc/src/sgml/docguide.sgml | 13 +++++-------- src/Makefile.global.in | 10 ++++++++++ 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/doc/src/sgml/docguide.sgml b/doc/src/sgml/docguide.sgml index 17d36e9145..5e98bde53d 100644 --- a/doc/src/sgml/docguide.sgml +++ b/doc/src/sgml/docguide.sgml @@ -153,8 +153,11 @@ Tool Sets You can get away with not installing DocBook XML and the DocBook XSLT - stylesheets locally, because the required files will be downloaded from the - Internet and cached locally. This may in fact be the preferred solution if + stylesheets locally because the required files can be downloaded from the + Internet and cached locally. By default, this behavior is disabled by the + PostgreSQL build system, but if you want it, pass the variable + LIBXML_NONET= on the make command + line. This may in fact be the preferred solution if your operating system packages provide only an old version of especially the stylesheets or if no packages are available at all. See the option for xmllint @@ -205,12 +208,6 @@ Debian Packages macOS - - On macOS, you can build the HTML and man documentation without installing - anything extra. If you want to build PDFs or want to install a local copy - of DocBook, you can get those from your preferred package manager. - - If you use MacPorts, the following will get you set up: diff --git a/src/Makefile.global.in b/src/Makefile.global.in index 7ca1e9aac5..b514129c10 100644 --- a/src/Makefile.global.in +++ b/src/Makefile.global.in @@ -493,6 +493,16 @@ FOP = @FOP@ XMLLINT = @XMLLINT@ XSLTPROC = @XSLTPROC@ +# Run libxml-based tools (xmllint, xsltproc) with --nonet by default. +# Can be overridden by user. +LIBXML_NONET = --nonet +ifdef XMLLINT +XMLLINT += $(LIBXML_NONET) +endif +ifdef XSLTPROC +XSLTPROC += $(LIBXML_NONET) +endif + # Code coverage GCOV = @GCOV@ -- 2.29.2