Opened 7 years ago

Closed 7 years ago

#3814 closed defect (fixed)

Can't compile against PostgreSQL 11 head

Reported by: robe Owned by: pramsey
Priority: critical Milestone: PostGIS 2.4.0
Component: postgis Version: master
Keywords: Cc:

Description

Hmm looks like they changed something in PostgreSQL 11 branch about a day ago that is causing Debbie to scream. They must have also flipped the branch to PostgreSQL 11 so we've been testing PostgreSQL 11 instead of PostgreSQL 10 for at least a couple of days.

Debbie's breaking on compiling MVT.

https://debbie.postgis.net/job/PostGIS_Regress/6144/console

 -------------- Compiler Info ------------- 
  C compiler:           gcc -g -O2
  SQL preprocessor:     /usr/bin/cpp -traditional-cpp -w -P

 -------------- Dependencies -------------- 
  GEOS config:          /var/lib/jenkins/workspace/geos/rel-3.7.0devw64/bin/geos-config
  GEOS version:         3.7.0dev
  GDAL config:          /var/lib/jenkins/workspace/gdal/rel-2.1w64/bin/gdal-config
  GDAL version:         2.1.4
  SFCGAL config:        /usr/bin/sfcgal-config
  SFCGAL version:       1.3.0
  PostgreSQL config:    /var/lib/jenkins/workspace/pg/rel/pg10.0w64/bin/pg_config
  PostgreSQL version:   PostgreSQL 11devel
  PROJ4 version:        49
  Libxml2 config:       /usr/bin/xml2-config
  Libxml2 version:      2.9.4
  JSON-C support:       yes
  protobuf-c support:   yes
  PCRE support:         yes
  PostGIS debug level:  0
  Perl:                 /usr/bin/perl

 --------------- Extensions --------------- 
  PostGIS Raster:       enabled
  PostGIS Topology:     enabled
  SFCGAL support:       enabled
  Address Standardizer support:       enabled

 -------- Documentation Generation -------- 
  xsltproc:             /usr/bin/xsltproc
  xsl style sheets:     /usr/share/xml/docbook/stylesheet/docbook-xsl
  dblatex:              /usr/bin/dblatex
  convert:              /usr/bin/convert
  mathml2.dtd:          http://www.w3.org/Math/DTD/mathml2/mathml2.dtd

/workspace/pg/rel/pg10.0w64/include/postgresql/internal  -D_GNU_SOURCE   -c -o mvt.o mvt.c
mvt.c: In function ‘parse_column_keys’:
mvt.c:307:45: error: invalid type argument of ‘->’ (have ‘FormData_pg_attribute {aka struct FormData_pg_attribute}’)
   Oid typoid = getBaseType(tupdesc->attrs[i]->atttypid);
                                             ^
mvt.c:312:33: error: invalid type argument of ‘->’ (have ‘FormData_pg_attribute {aka struct FormData_pg_attribute}’)
   char *tkey = tupdesc->attrs[i]->attname.data;
                                 ^
mvt.c: In function ‘parse_values’:
mvt.c:553:32: error: invalid type argument of ‘->’ (have ‘FormData_pg_attribute {aka struct FormData_pg_attribute}’)
   char *key = tupdesc->attrs[i]->attname.data;
                                ^
mvt.c:555:45: error: invalid type argument of ‘->’ (have ‘FormData_pg_attribute {aka struct FormData_pg_attribute}’)
   Oid typoid = getBaseType(tupdesc->attrs[i]->atttypid);
                                             ^
<builtin>: recipe for target 'mvt.o' failed
make[1]: *** [mvt.o] Error 1
make[1]: Leaving directory '/var/lib/jenkins/workspace/postgis/branches/2.4/postgis'
GNUmakefile:16: recipe for target 'all' failed
make: *** [all] Error 1

Change History (8)

comment:1 by robe, 7 years ago

On further inspection PostgreSQL 11 stopped compiling in against PostGIS on 8/20.

I attribute the issue to this PostgreSQL master commit:

Subproject Builds

	Changes

    Change tupledesc->attrs[n] to TupleDescAttr(tupledesc, n). (detail)
    Partially flatten struct tupleDesc so that it can be used in DSM. (detail)



	Revision: c6293249dc178f52dd508c3e6ff353af41c90b58

    refs/remotes/origin/master

https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=c6293249dc178f52dd508c3e6ff353af41c90b58

comment:2 by robe, 7 years ago

Milestone: PostGIS 2.4.0PostGIS 2.5.0

comment:3 by robe, 7 years ago

Milestone: PostGIS 2.5.0PostGIS 2.4.0
Owner: changed from robe to pramsey
Status: assignednew

pramsey while you are on a roll fixing PostgreSQL 11, want to tackle this one?

You might need to compile with protobuf support to see the error though.

comment:4 by robe, 7 years ago

actually looks like a similar error you fixed in r15641

so maybe just do the same thing and don't worry so much about testing if you don't have protobuf set up.

comment:5 by pramsey, 7 years ago

Blindly committed fix at r15653, will get protobuf set up and test

comment:6 by pramsey, 7 years ago

Resolution: fixed
Status: newclosed

comment:7 by pramsey, 7 years ago

Resolution: fixed
Status: closedreopened

Builds and regresses with protobuf enabled, this is done.

comment:8 by pramsey, 7 years ago

Resolution: fixed
Status: reopenedclosed
Note: See TracTickets for help on using tickets.