Re: __pg_log_level in anonynous enum should be initialized? (Was: pgsql: Change SHA2 implementation based on OpenSSL to use EVP digest ro) - Mailing list pgsql-hackers

From Tom Lane
Subject Re: __pg_log_level in anonynous enum should be initialized? (Was: pgsql: Change SHA2 implementation based on OpenSSL to use EVP digest ro)
Date
Msg-id 607460.1601386158@sss.pgh.pa.us
Whole thread Raw
In response to Re: __pg_log_level in anonynous enum should be initialized? (Was: pgsql: Change SHA2 implementation based on OpenSSL to use EVP digest ro)  (Michael Paquier <michael@paquier.xyz>)
Responses Re: __pg_log_level in anonynous enum should be initialized? (Was: pgsql: Change SHA2 implementation based on OpenSSL to use EVP digest ro)  (Michael Paquier <michael@paquier.xyz>)
List pgsql-hackers
Michael Paquier <michael@paquier.xyz> writes:
> On Mon, Sep 28, 2020 at 12:49:29PM -0400, Tom Lane wrote:
>> Since prairiedog is not likely to be around forever, I propose that
>> we ought to enforce this going forward by arranging for common/logging.c
>> to not get built into the libpgcommon_shlib library variant.

> Agreed.  This makes sense in the long term, so attached is a proposal
> of patch.  I did not really see the point in complicating the MSVC
> scripts for that though.  The new variable names look natural to me
> like that, the new comment may need some tweaks.

Hm, it doesn't seem like "OBJS_PGCOMMON" conveys much.  I think
OBJS_FRONTEND ought to be the set of files built for frontend
application use (i.e., libpgcommon.a), so we need a new name
for what will go into libpgcommon_shlib.a.  Maybe OBJS_SHLIB,
or to be even more explicit, OBJS_FRONTEND_SHLIB.

As for the comment, maybe "logging.c is excluded from OBJS_SHLIB
as a matter of policy, because it is not appropriate for general
purpose libraries such as libpq to report errors directly."

            regards, tom lane



pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: [HACKERS] logical decoding of two-phase transactions
Next
From: Alvaro Herrera
Date:
Subject: Re: Optimize memory allocation code