Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tXmxt-00EHHp-Bg for pgsql-hackers@arkaria.postgresql.org; Tue, 14 Jan 2025 19:52:41 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tXmxr-003f4L-U6 for pgsql-hackers@arkaria.postgresql.org; Tue, 14 Jan 2025 19:52:40 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tXmxr-003f4D-KY for pgsql-hackers@lists.postgresql.org; Tue, 14 Jan 2025 19:52:40 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tXmxq-000PTT-2e for pgsql-hackers@lists.postgresql.org; Tue, 14 Jan 2025 19:52:39 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 50EJqTY5717459; Tue, 14 Jan 2025 14:52:29 -0500 From: Tom Lane To: Nathan Bossart cc: Fujii Masao , Andy Fan , pgsql-hackers@lists.postgresql.org Subject: Re: pgbench error: (setshell) of script 0; execution of meta-command failed In-reply-to: References: <87msfz5qv2.fsf@163.com> <87ikqn5em7.fsf@163.com> <2422778.1736521065@sss.pgh.pa.us> <2425050.1736522451@sss.pgh.pa.us> <127979.1736622253@sss.pgh.pa.us> <570943.1736808714@sss.pgh.pa.us> Comments: In-reply-to Nathan Bossart message dated "Tue, 14 Jan 2025 10:29:53 -0600" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <717457.1736884349.1@sss.pgh.pa.us> Date: Tue, 14 Jan 2025 14:52:29 -0500 Message-ID: <717458.1736884349@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Nathan Bossart writes: > On Mon, Jan 13, 2025 at 05:51:54PM -0500, Tom Lane wrote: >> (plus or minus an extern or so, but you get the idea). The point of >> this is that compiling against old headers and then linking against >> newer libpgport.a would still work. It does nothing however for the >> reverse scenario of compiling against new headers and then linking >> against old libpgport.a. So I haven't persuaded myself that it's >> worth the trouble -- but I'm happy to include it if others think >> it would help. > After sleeping on it, I think I agree that the extra gymnastics aren't > worth it to partially fix something that wasn't supported anyway. But I'm > not mortally opposed to it if someone feels strongly that it should be > included. After more thought I've realized that the asymmetrical detection here isn't all that bad, because the outcomes are different. If we fail to catch old-headers-and-new-library, the result will either be a link failure or (if the extension uses libpq) silently linking to libpq's pqsignal, which was likely not what was intended. If we fail to catch the other case, the result is always a link failure, and that will happen at build time not in the field. So now I'm inclined to include the ABI-compatible wrapper, which will ensure that extensions continue to link to libpgport's pqsignal. regards, tom lane