Re: Add version macro to libpq-fe.h - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Add version macro to libpq-fe.h
Date
Msg-id 1036619.1623955300@sss.pgh.pa.us
Whole thread Raw
In response to Re: Add version macro to libpq-fe.h  (Andres Freund <andres@anarazel.de>)
Responses Re: Add version macro to libpq-fe.h  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers
Andres Freund <andres@anarazel.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.

Now we could alternatively invent a libpq_version.h and hope that
packagers remember to install the right version of that.  But I
think it's a better user experience all around to do it the other
way.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Add version macro to libpq-fe.h
Next
From: Andres Freund
Date:
Subject: Re: [Proposal] Fully WAL logged CREATE DATABASE - No Checkpoints