Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fzP0y-0003pZ-6Y for pgsql-bugs@arkaria.postgresql.org; Mon, 10 Sep 2018 16:26:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fzP0w-0005nv-AX for pgsql-bugs@arkaria.postgresql.org; Mon, 10 Sep 2018 16:26:14 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fzP0w-0005nn-18 for pgsql-bugs@lists.postgresql.org; Mon, 10 Sep 2018 16:26:14 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fzP0p-0001Pw-Cv for pgsql-bugs@lists.postgresql.org; Mon, 10 Sep 2018 16:26:12 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id w8AGQ4Hx016985; Mon, 10 Sep 2018 12:26:04 -0400 From: Tom Lane To: Andrew Gierth cc: Jeremy Evans , Michael Paquier , pgsql-bugs@lists.postgresql.org Subject: Re: BUG #15367: Crash in pg_fe_scram_free when using foreign tables In-reply-to: <12293.1536591166@sss.pgh.pa.us> References: <153626613985.23143.4743626885618266803@wrigleys.postgresql.org> <20180906215836.GP2726@paquier.xyz> <20180906222843.GF17425@jeremyevans.local> <20180907165103.GH17425@jeremyevans.local> <20180907175518.GI17425@jeremyevans.local> <20180907181522.GB32058@paquier.xyz> <20016.1536351535@sss.pgh.pa.us> <20180907204403.GC32058@paquier.xyz> <16558.1536407783@sss.pgh.pa.us> <18398.1536410055@sss.pgh.pa.us> <87o9d8rv08.fsf@news-spur.riddles.org.uk> <22025.1536521375@sss.pgh.pa.us> <87zhwqqwz7.fsf@news-spur.riddles.org.uk> <24041.1536523851@sss.pgh.pa.us> <12134.1536550702@sss.pgh.pa.us> <12293.1536591166@sss.pgh.pa.us> Comments: In-reply-to Tom Lane message dated "Mon, 10 Sep 2018 10:52:46 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <16983.1536596764.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Mon, 10 Sep 2018 12:26:04 -0400 Message-ID: <16984.1536596764@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk I wrote: > AFAICT, this platform's "ld" doesn't have any simple equivalent of > a version script, but it does have "-B symbolic", which appears to > fix the problem in a quick test. BTW, I discovered while rummaging through the git history that we used to use -Bsymbolic on most platforms --- but only for ODBC, which had exactly the problem we're fighting now of an intended-to- be-local reference being resolved outside the library, but in a place where the malfunction was very obvious. When we removed ODBC from the core distro, the Makefile support for -Bsymbolic eventually went away too. But back around 7.2 we had this: $ grep -r shlib_symbolic /home/postgres/REL7_2/pgsql /home/postgres/REL7_2/pgsql/src/interfaces/odbc/GNUmakefile: 54: LINK.shar= ed +=3D $(shlib_symbolic) /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.bsdi: 19: shlib_symboli= c =3D -Wl,-Bsymbolic /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.freebsd: 6: shlib_symbo= lic =3D -Wl,-Bsymbolic -lc /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.hpux: 33: shlib_symboli= c =3D -Bsymbolic /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.irix5: 4: shlib_symboli= c =3D -Wl,-B,symbolic /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.linux: 4: shlib_symboli= c =3D -Wl,-Bsymbolic /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.netbsd: 6: shlib_symbol= ic =3D -Wl,-Bsymbolic -lc /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.openbsd: 6: shlib_symbo= lic =3D -Wl,-Bsymbolic /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.sco: 3: shlib_symbolic = =3D -Wl,-Bsymbolic /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.solaris: 11: shlib_symb= olic =3D -Wl,-Bsymbolic /home/postgres/REL7_2/pgsql/src/makefiles/Makefile.unixware: 6: shlib_symb= olic =3D -Wl,-Bsymbolic This suggests that we're gonna need -Bsymbolic on Solaris too, which agrees with your remark upthread. Unfortunately, with all the Solaris buildfarm members being hors de C99 right now, there's no easy way to test. I'm inclined to go fix the problem that's blocking castoroides, at least. regards, tom lane