pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
BUG #15132: Build fails in src/backend/utils/adt/encode.c
3+ messages / 3 participants
[nested] [flat]

* BUG #15132: Build fails in src/backend/utils/adt/encode.c
@ 2018-03-28 11:57  PG Bug reporting form <noreply@postgresql.org>
  0 siblings, 1 reply; 3+ messages in thread

From: PG Bug reporting form @ 2018-03-28 11:57 UTC (permalink / raw)
  To: pgsql-bugs@lists.postgresql.org; +Cc: stadtkind2@gmx.de

The following bug has been logged on the website:

Bug reference:      15132
Logged by:          Stefan Krüger
Email address:      stadtkind2@gmx.de
PostgreSQL version: 10.3
Operating system:   Solaris 11.4 Beta
Description:        

Hi,

Solaris 11.4 has b64_encode/b64_decode in libc. So building PostgreSQL 10.3
fails because they are defined in src/backend/utils/adt/encode.c as well:

gmake[4]: Entering directory '/tmp/postgresql-10.3/src/backend/utils/adt'
/opt/developerstudio12.6/bin/cc -Xa -m64 -g -Qoption cg -xregs=no%appl
-W2,-xwrap_int -xc99=all -KPIC -DPIC -xmemalign=16s
-I../../../../src/include  -D_LARGEFILE64_SOURCE -D_XOPEN_SOURCE=600
-D__EXTENSIONS__=1 -D_XPG6   -c -o encode.o encode.c
"encode.c", line 218: identifier redeclared: b64_encode
        current : static function(pointer to const char, unsigned int,
pointer to char) returning unsigned int
        previous: function(restrict pointer to char, unsigned long, restrict
pointer to const void, unsigned long, pointer to const char, unsigned long)
returning long : "/usr/include/string.h", line 218
"encode.c", line 265: identifier redeclared: b64_decode
        current : static function(pointer to const char, unsigned int,
pointer to char) returning unsigned int
        previous: function(pointer to void, unsigned long, pointer to const
char, pointer to const char, unsigned long) returning long :
"/usr/include/string.h", line 221
cc: acomp failed for encode.c



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: BUG #15132: Build fails in src/backend/utils/adt/encode.c
@ 2018-03-28 12:09  Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
  parent: PG Bug reporting form <noreply@postgresql.org>
  0 siblings, 1 reply; 3+ messages in thread

From: Peter Eisentraut @ 2018-03-28 12:09 UTC (permalink / raw)
  To: stadtkind2@gmx.de, pgsql-bugs@lists.postgresql.org, PG Bug reporting form <noreply@postgresql.org>

On 3/28/18 07:57, PG Bug reporting form wrote:
> Solaris 11.4 has b64_encode/b64_decode in libc. So building PostgreSQL 10.3
> fails because they are defined in src/backend/utils/adt/encode.c as well:

This will be fixed in the next minor release.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: BUG #15132: Build fails in src/backend/utils/adt/encode.c
@ 2018-03-28 12:12  Michael Paquier <michael@paquier.xyz>
  parent: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
  0 siblings, 0 replies; 3+ messages in thread

From: Michael Paquier @ 2018-03-28 12:12 UTC (permalink / raw)
  To: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>; +Cc: stadtkind2@gmx.de, pgsql-bugs@lists.postgresql.org, PG Bug reporting form <noreply@postgresql.org>

On Wed, Mar 28, 2018 at 08:09:11AM -0400, Peter Eisentraut wrote:
> On 3/28/18 07:57, PG Bug reporting form wrote:
> > Solaris 11.4 has b64_encode/b64_decode in libc. So building PostgreSQL 10.3
> > fails because they are defined in src/backend/utils/adt/encode.c as well:
> 
> This will be fixed in the next minor release.

You are looking for this commit if you are interested (see the thread
reference as well):

commit: aac6286d8fd17f94f3bce5dd8b942b7fcf9e2a61
author: Tom Lane <tgl@sss.pgh.pa.us>
date: Wed, 28 Feb 2018 18:33:45 -0500
Rename base64 routines to avoid conflict with Solaris built-in
functions.

Solaris 11.4 has built-in functions named b64_encode and b64_decode.
Rename ours to something else to avoid the conflict (fortunately,
ours are static so the impact is limited).

One could wish for less duplication of code in this area, but that
would be a larger patch and not very suitable for back-patching.
Since this is a portability fix, we want to put it into all supported
branches.

Report and initial patch by Rainer Orth, reviewed and adjusted a bit
by Michael Paquier

Discussion: https://postgr.es/m/ydd372wk28h.fsf@CeBiTec.Uni-Bielefeld.DE
--
Michael

Attachments:

  signature.asc (application/pgp-signature, 832B) download

^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2018-03-28 12:12 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2018-03-28 11:57 BUG #15132: Build fails in src/backend/utils/adt/encode.c PG Bug reporting form <noreply@postgresql.org>
2018-03-28 12:09 ` Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
2018-03-28 12:12   ` Michael Paquier <michael@paquier.xyz>

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