Bug 251093

Summary: databases/postgresql95-server: Fails to build on 11.4 amd64: dbcommands.c:1977:1: error: conflicting types for *
Product: Ports & Packages Reporter: Victor Sudakov <vas>
Component: Individual Port(s)Assignee: pgsql
Status: Closed FIXED    
Severity: Affects Some People CC: girgen, vas
Priority: --- Keywords: needs-qa
Version: LatestFlags: bugzilla: maintainer-feedback? (pgsql)
koobs: merge-quarterly?
Hardware: amd64   
OS: Any   
Attachments:
Description Flags
Poudriere log none

Description Victor Sudakov 2020-11-13 08:13:39 UTC
Created attachment 219626 [details]
Poudriere log

The databases/postgresql95-server port does not compile on 11.4 amd64 (compiler error in poudriere). Attached please find the complete poudriere build log.




protector-strong -fno-strict-aliasing  -I../../../src/include -I/usr/local/include -I/usr/local/include/libxml2 -I/usr/include -I/usr/local/include -I/usr/local/include  -c -o dbcommands.o dbcommands.c
dbcommands.c:531:20: warning: incompatible pointer types passing 'bool [13]' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                                                        new_record, new_record_nulls);
                                                                    ^~~~~~~~~~~~~~~~
../../../src/include/access/htup_details.h:802:26: note: passing argument to parameter 'isnull' here
                                Datum *values, bool *isnull);
                                                     ^
dbcommands.c:770:1: error: conflicting types for 'dropdb'
dropdb(const char *dbname, bool missing_ok)
^
../../../src/include/commands/dbcommands.h:23:13: note: previous declaration is here
extern void dropdb(const char *dbname, bool missing_ok);
            ^
dbcommands.c:1268:11: warning: incompatible pointer types passing 'bool [13]' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                                                                         new_record_nulls, new_record_repl);
                                                                         ^~~~~~~~~~~~~~~~
../../../src/include/access/htup_details.h:806:13: note: passing argument to parameter 'replIsnull' here
                                  bool *replIsnull,
                                        ^
dbcommands.c:1268:29: warning: incompatible pointer types passing 'bool [13]' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                                                                         new_record_nulls, new_record_repl);
                                                                                           ^~~~~~~~~~~~~~~
../../../src/include/access/htup_details.h:807:13: note: passing argument to parameter 'doReplace' here
                                  bool *doReplace);
                                        ^
dbcommands.c:1367:1: error: conflicting types for 'AlterDatabase'
AlterDatabase(AlterDatabaseStmt *stmt, bool isTopLevel)
^
../../../src/include/commands/dbcommands.h:25:12: note: previous declaration is here
extern Oid      AlterDatabase(AlterDatabaseStmt *stmt, bool isTopLevel);
                ^
dbcommands.c:1520:10: warning: incompatible pointer types passing 'bool [13]' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                                                                 new_record_nulls, new_record_repl);
                                                                 ^~~~~~~~~~~~~~~~
../../../src/include/access/htup_details.h:806:13: note: passing argument to parameter 'replIsnull' here
                                  bool *replIsnull,
                                        ^
dbcommands.c:1520:28: warning: incompatible pointer types passing 'bool [13]' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                                                                 new_record_nulls, new_record_repl);
                                                                                   ^~~~~~~~~~~~~~~
../../../src/include/access/htup_details.h:807:13: note: passing argument to parameter 'doReplace' here
                                  bool *doReplace);
                                        ^
dbcommands.c:1646:14: warning: incompatible pointer types passing 'bool *' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                aclDatum = heap_getattr(tuple,
                           ^~~~~~~~~~~~~~~~~~~
../../../src/include/access/htup_details.h:782:50: note: expanded from macro 'heap_getattr'
                        heap_getsysattr((tup), (attnum), (tupleDesc), (isnull)) \
                                                                      ^~~~~~~~
../../../src/include/access/htup_details.h:797:11: note: passing argument to parameter 'isnull' here
                                bool *isnull);
                                      ^
dbcommands.c:1658:72: warning: incompatible pointer types passing 'bool [13]' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                newtuple = heap_modify_tuple(tuple, RelationGetDescr(rel), repl_val, repl_null, repl_repl);
                                                                                     ^~~~~~~~~
../../../src/include/access/htup_details.h:806:13: note: passing argument to parameter 'replIsnull' here
                                  bool *replIsnull,
                                        ^
dbcommands.c:1658:83: warning: incompatible pointer types passing 'bool [13]' to parameter of type 'bool *' (aka 'char *') [-Wincompatible-pointer-types]
                newtuple = heap_modify_tuple(tuple, RelationGetDescr(rel), repl_val, repl_null, repl_repl);
                                                                                                ^~~~~~~~~
../../../src/include/access/htup_details.h:807:13: note: passing argument to parameter 'doReplace' here
                                  bool *doReplace);
                                        ^
dbcommands.c:1977:1: error: conflicting types for 'get_database_oid'
get_database_oid(const char *dbname, bool missing_ok)
^
../../../src/include/commands/dbcommands.h:29:12: note: previous declaration is here
extern Oid      get_database_oid(const char *dbname, bool missingok);
                ^
8 warnings and 3 errors generated.
gmake[1]: *** [<builtin>: dbcommands.o] Error 1
gmake[1]: Leaving directory '/wrkdirs/usr/ports/databases/postgresql95-server/work/postgresql-9.5.23/src/backend/commands'
gmake: *** [common.mk:41: commands-recursive] Error 2
*** Error code 2

Stop.
make: stopped in /usr/ports/databases/postgresql95-server
=>> Cleaning up wrkdir
===>  Cleaning for postgresql95-server-9.5.23
build of databases/postgresql95-server | postgresql95-server-9.5.23 ended at Fri Nov 13 01:05:49 MST 2020
build time: 00:03:18
!!! build failure encountered !!!
Comment 1 Victor Sudakov 2020-11-13 08:23:16 UTC
Not that 9.5 is very popular but I still need it for some legacy things and would prefer to have it around.
Comment 2 Palle Girgensohn freebsd_committer freebsd_triage 2020-11-13 10:26:56 UTC
Yes, something changed in the ICU package that makes the build fail. I'm looking into this.

Palle
Comment 3 Palle Girgensohn freebsd_committer freebsd_triage 2020-11-13 10:52:06 UTC
The patch-icu68 from postgresql96-server/files seems to fix it. Testing the port right now.
Comment 4 Palle Girgensohn freebsd_committer freebsd_triage 2020-11-13 20:13:06 UTC
Hi!

This was due to a change in ICU. It failed only when the ICU patch was enabled. It is fixed now.

Palle
Comment 5 Victor Sudakov 2020-11-14 04:51:42 UTC
Thanks, it builds fine now.