[postgis-devel] protobuf configure options

Paul Ramsey pramsey at cleverelephant.ca
Wed Aug 14 10:09:59 PDT 2019


I ran into an issue trying to build on an old Ubuntu with protobuf-c and postgis 3, basically there was no pkg-config entry for it and it wasn’t installed in a neat directory location for —with-protobufdir to latch onto it. I have re-worked the protobuf part of configure and added

—with-protobuf-inc
—with-protobuf-lib

So it’s more like gdal in terms of allowing each half to be separately configured. The “chain of being is now”:

- if the user asks for a particular path, try to detect lib/inc there
- if there is a pkg-config entry, use paths from there, and try to detect
- just try and detect naively and see if things work (simple system installs)

I think it’s an improvement. I left the —with-protobufdir option in place, but that means we now have

—with-protobuf
—with-protobufdir
—with-protobuf-inc
—with-protobuf-lib

as options! The reason —with-protobuf is there is so people can use it for the negative option (—without-protobuf) if they want to turn it off entirely. I’m not sure why we consider that an important use case… 
We can remove —with-protobufdir because the inc/lib options supercede it, but it’ll break a bunch of build scripts I imagine, so I don’t want to summarily strip it until at least a few build people say “sure, go ahead”.

P.


More information about the postgis-devel mailing list