From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-hackers@lists.postgresql.org
Subject: Non-configure build of thread_test has been broken for awhile
Date: Sun, 18 Oct 2020 13:20:12 -0400
Message-ID: <227659.1603041612@sss.pgh.pa.us> (raw)
If you go into src/test/thread/ and type "make", you get
a bunch of "undefined reference to `pg_fprintf'" failures.
That's because thread_test.c #include's postgres.h but
the Makefile doesn't bother to link it with libpgport,
arguing (falsely) that that might not exist yet.
Presumably, this has been busted on all platforms since
96bf88d52, and for many years before that on platforms
that have always used src/port/snprintf.c.
Configure's use of the program works anyway because it doesn't
use the Makefile and thread_test.c doesn't #include postgres.h
when IN_CONFIGURE.
It doesn't really seem sane to me to support two different build
environments for thread_test, especially when one of them is so
little-used that it can be broken for years before we notice.
So I'd be inclined to rip out the Makefile and just consider
that thread_test.c is *only* meant to be used by configure.
If we wish to resurrect the standalone build method, we could
probably do so by adding LIBS to the Makefile's link command
... but what's the point, and what will keep it from getting
broken again later?
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, pgsql-hackers@lists.postgresql.org
Subject: Re: Non-configure build of thread_test has been broken for awhile
In-Reply-To: <227659.1603041612@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox