Subject: Re: Error Building Postgres 17.0 from Source

From: Christophe Pettus <[email-masked]>
Date: Fri, 4 Oct 2024 09:41:11 -0700

> On Oct 4, 2024, at 09:35, Corbin Cavolt <[email-masked]> wrote:
> 
> Hi,
> 
> I'm having a problem building Postgres 17.0 from source. I'm able to build all the 16.x versions just fine; I'm running into an error specifically with version 17.0. I use a devcontainer for development with my own postgres feature here: https://github.com/ccavolt/devcontainer-features/tree/main/src/postgres. As you can see I'm using Debian Bookworm for testing. If you open up the repo in a Codespace or a devcontainer and run the following command, you should be able to see the same errors that I'll post below:

You might try installing the Debian packages for the documentation tools; the lack of them is the usual reason for errors of that sort:

	https://www.postgresql.org/docs/devel/docguide-toolsets.html#DOCGUIDE-TOOLSETS-INST-DEBIAN

---

From: Tom Lane <[email-masked]>
Date: Fri, 04 Oct 2024 15:05:24 -0400

Christophe Pettus <[email-masked]> writes:
>> I'm having a problem building Postgres 17.0 from source. I'm able to build all the 16.x versions just fine; I'm running into an error specifically with version 17.0.

> 	https://www.postgresql.org/docs/devel/docguide-toolsets.html#DOCGUIDE-TOOLSETS-INST-DEBIAN

Yeah, that's what it looks like.  I'm a bit confused though because
16.x should have failed the same way: building our docs without local
DTDs has failed for well over a year now [1].  Perhaps you weren't
trying to build the docs before?

			regards, tom lane

[1] https://git.postgresql.org/gitweb/?p=postgresql.git&a=commitdiff&h=969509c3f

---

From: Christophe Pettus <[email-masked]>
Date: Fri, 4 Oct 2024 12:08:11 -0700

> On Oct 4, 2024, at 12:05, Tom Lane <[email-masked]> wrote:
> 
> DTDs has failed for well over a year now [1]. 

To add confusion to the fire, I was successfully building pre-17 versions ("make world") locally on MacOS fine without having to install the documentation tools.  It wasn't until 17 that it failed (and installing the doc tools as recommended fixed it).

---

From: Tom Lane <[email-masked]>
Date: Fri, 04 Oct 2024 15:34:19 -0400

> To add confusion to the fire, I was successfully building pre-17 versions ("make world") locally on MacOS fine without having to install the documentation tools.  It wasn't until 17 that it failed…

If you had a locally installed copy of the required DTDs, it should've
worked, but otherwise I don't see how ... oh, wait.  Were you building
from a source tarball?  If so, the difference is that up to v16 we
included prebuilt HTML docs in the tarballs, but as of v17 we don't.
So "make world" now triggers a local docs build where before it
didn't.

You can restore things to the status quo ante if you also download
the now-separate docs tarball, eg

https://ftp.postgresql.org/pub/source/v17.0/postgresql-17.0-docs.tar.gz

and unpack that into the same place as the main source tarball.

			regards, tom lane

---

From: Christophe Pettus <[email-masked]>
Date: Fri, 4 Oct 2024 12:35:37 -0700

> On Oct 4, 2024, at 12:34, Tom Lane <[email-masked]> wrote:
> 
> If so, the difference is that up to v16 we

Ah!  That would be it.