MacOS: xsltproc fails with "warning: failed to load external entity"
Aleksander Alekseev <aleksander@timescale.com>
From: Aleksander Alekseev <aleksander@timescale.com>
To: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2023-01-30T10:18:37Z
Lists: pgsql-hackers
Hi hackers,
I'm having some difficulties building the documentation on MacOS.
I'm using ./full-build.sh script from [1] repository. It worked just
fine for many years but since recently it started to fail like this:
```
/usr/bin/xsltproc --path . --stringparam pg.version '16devel'
/Users/eax/projects/c/pgscripts/../postgresql/doc/src/sgml/stylesheet.xsl
postgres-full.xml
error : Unknown IO error
warning: failed to load external entity
"http://docbook.sourceforge.net/release/xsl/current/xhtml/chunk.xsl"
compilation error: file
/Users/eax/projects/c/pgscripts/../postgresql/doc/src/sgml/stylesheet.xsl
line 6 element import
xsl:import : unable to load
http://docbook.sourceforge.net/release/xsl/current/xhtml/chunk.xsl
error : Unknown IO error
/Users/eax/projects/c/postgresql/doc/src/sgml/stylesheet-html-common.xsl:4:
warning: failed to load external entity
"http://docbook.sourceforge.net/release/xsl/current/common/entities.ent"
%common.entities;
^
Entity: line 1:
%common.entities;
^
[...]
```
This is not a network problem. I can download chunk.xsl with wget and
also build the documentation on my Linux laptop.
I've tried `brew reinstall` and also:
```
./configure ... XMLLINT="xmllint --nonet" XSLTPROC="xsltproc --nonet"
```
... as suggested by the documentation [2] but it didn't change anything.
I checked the archive of pgsql-hackers@ but was unable to find
anything relevant.
I'm using MacOS Monterey 12.6.2.
```
$ brew info docbook
==> docbook: stable 5.1 (bottled)
...
$ brew info docbook-xsl
==> docbook-xsl: stable 1.79.2 (bottled)
...
```
At this point I could use a friendly piece of advice from the community.
[1]: https://github.com/afiskon/pgscripts/
[2]: https://www.postgresql.org/docs/15/docguide-toolsets.html
--
Best regards,
Aleksander Alekseev
Commits
-
docs: meson: Change what 'docs' target builds
- 9e5b2a091fd0 17.0 landed
-
doc: Fix XML_CATALOG_FILES env var for Apple Silicon machines
- 4257d34e310b 11.20 landed
- aad9a2ee7c2d 12.15 landed
- c6f1f4e443fb 14.8 landed
- 9850ef9fc123 13.11 landed
- 50792b155371 15.3 landed
-
doc: fix Apple Silicon Homebrew prefix change documentation
- 5a91c7975503 16.0 landed
-
doc: Fix XML_CATALOG_FILES env var for Apple M1 machines
- 4c8d65408470 16.0 landed
-
Stop recommending auto-download of DTD files, and indeed disable it.
- 36a646d99c3f 11.20 landed
- 11f1f9f4fa30 12.15 landed
- 969509c3f2e3 16.0 landed
- c7b608600547 13.11 landed
- 7f8778fcf342 14.8 landed
- 2ee703c9d1c6 15.3 landed