On 2019-Dec-09, Alvaro Herrera wrote:
> I see four possible ways forward, with nuances. In order of preference:
>
> 1. change enough of the build system so that pg_encoding_mbcliplen is
> available. (Offhand I see no reason why we couldn't move the
> function from mbutils.c to wchar.c, but I haven't tried.)
Ah, this seems to require putting encnames.o and wchar.o in src/common's
Makefile and moving pg_encoding_mbcliplen() from mbutils.c to wchar.c.
Fairly simple.
(There's a little bit of additional fallout because libpq also has
encnames/wchar in its roster, but I think this means we can just remove
them from there and let them be acquired via libpgcommon.)
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services