Opened 4 years ago
Closed 4 years ago
#4663 closed defect (fixed)
Remove unnecessary #include
Reported by: | Laurenz Albe | Owned by: | pramsey |
---|---|---|---|
Priority: | medium | Milestone: | |
Component: | postgis | Version: | master |
Keywords: | Cc: |
Description
PostgreSQL v13 has split access/tuptoaster.h
into several files, so building PostGIS with current PostgreSQL master fails.
However, it seems that the #include
is not really required, so the attached patch simply removes it.
I didn't test, but I don't think it creates problems with older PostgreSQL versions as well.
Attachments (2)
Change History (8)
by , 4 years ago
Attachment: | 0001-Remove-unnecessary-include.patch added |
---|
comment:1 by , 4 years ago
comment:2 by , 4 years ago
Yes, I noticed that when building. Here is a second patch that fixes the problem - we need the #include
after all.
by , 4 years ago
Attachment: | 0001-Change-include-for-VARATT_EXTERNAL_GET_POINTER.patch added |
---|
comment:3 by , 4 years ago
Note that this patch will only work for v13.
It would need conditional compilation to make this work with all PostgreSQL versions.
comment:4 by , 4 years ago
Thanks.
I think something like:
#if POSTGIS_PGSQL_VERSION < 130 #include "access/tuptoaster.h" #else #include "access/detoast.h" #endif
fixes both compilations.
I'm going to update out PG13 image which was broken because of other dependencies and see if that fixes the Travis build too.
comment:5 by , 4 years ago
Pushing the fix to close this issue and I'll open a different one to fix the latest
build, which is failing because of sfcgal changes in the build (the changed the placement of static libraries and added a pkg-config)
It breaks, at least, PG12: