From: | Andres Freund <andres(at)anarazel(dot)de> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Robert Haas <robertmhaas(at)gmail(dot)com>, Boris Kolpackov <boris(at)codesynthesis(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Álvaro Herrera <alvaro(dot)herrera(at)2ndquadrant(dot)com> |
Subject: | Re: Add version macro to libpq-fe.h |
Date: | 2021-06-17 19:13:03 |
Message-ID: | 20210617191303.bmzx5jfod23nph7x@alap3.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
On 2021-06-17 14:41:40 -0400, Tom Lane wrote:
> Andres Freund <andres(at)anarazel(dot)de> writes:
> > I'm not sure I understand why you think that exposing the version number
> > for libpq is such a bad idea?
> > I think it'd be reasonable to add a few more carefully chosen macros to
> > pg_config_ext.h.
>
> The primary problem I've got with that is the risk of confusion
> between server and libpq version numbers. In particular, if we do
> it like that then we've just totally screwed the Debian packagers.
> They will have to choose whether to install pg_config_ext.h from
> their server build or their libpq build. Both choices are wrong,
> depending on what applications want to know.
That's a fair point.
However, we kind of already force them to do so - libpq already depends
on pg_config_ext.h, so they need to deal with the issue in some
form. It's not particularly likely to lead to a problem to have a
mismatching pg_config_ext.h, though, so maybe that's not too bad.
Our make install actually forsees the issue to some degree, and installs
pg_config_ext.h in two places, which then debian builds on:
$ apt-file search pg_config_ext.h
libpq-dev: /usr/include/postgresql/pg_config_ext.h
postgresql-server-dev-13: /usr/include/postgresql/13/server/pg_config_ext.h
postgresql-server-dev-14: /usr/include/postgresql/14/server/pg_config_ext.h
Greetings,
Andres Freund
From | Date | Subject | |
---|---|---|---|
Next Message | Dagfinn Ilmari Mannsåker | 2021-06-17 19:15:42 | Re: Add version macro to libpq-fe.h |
Previous Message | Andres Freund | 2021-06-17 18:48:01 | Re: [Proposal] Fully WAL logged CREATE DATABASE - No Checkpoints |