pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jacob Champion <pchampion@vmware.com>
To: peter.eisentraut@enterprisedb.com <peter.eisentraut@enterprisedb.com>
To: tgl@sss.pgh.pa.us <tgl@sss.pgh.pa.us>
Cc: daniel@yesql.se <daniel@yesql.se>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Cc: michael@paquier.xyz <michael@paquier.xyz>
Subject: Re: Preventing abort() and exit() calls in libpq
Date: Thu, 1 Jul 2021 18:21:04 +0000
Message-ID: <05ced65e02e53c61bc182a24e385395c8a3718ff.camel@vmware.com> (raw)
In-Reply-To: <745046.1625163264@sss.pgh.pa.us>
References: <3128896.1624742969@sss.pgh.pa.us>
	<18eda75d-af6d-3fc0-03b6-607eff9f392a@enterprisedb.com>
	<622907.1625084114@sss.pgh.pa.us>
	<630837.1625092151@sss.pgh.pa.us>
	<67ddcb26f82acaffb26c59b7d8e4cd75399b2cd3.camel@vmware.com>
	<9d35a4ac-2c75-cb44-95ab-61d69deb072e@enterprisedb.com>
	<745046.1625163264@sss.pgh.pa.us>

On Thu, 2021-07-01 at 14:14 -0400, Tom Lane wrote:
> Peter Eisentraut <peter.eisentraut@enterprisedb.com> writes:
> > Somewhere in the $(shlib) rule would seem most appropriate.  But I don't 
> > understand the rest: What ifeq, and why .DELETE_ON_ERROR?
> 
> The variant of this I'd been thinking of was
> 
>  $(shlib): $(OBJS) | $(SHLIB_PREREQS)
>  	$(LINK.shared) -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK)
> +ifneq (,$(SHLIB_EXTRA_ACTION))
> +	$(SHLIB_EXTRA_ACTION)
> +endif
> 
> (and similarly in several other places); then libpq's Makefile
> could set SHLIB_EXTRA_ACTION to the desired thing.
> 
> The problem then is, what happens when the extra action fails?
> Without .DELETE_ON_ERROR, the shlib is still there and the next
> make run will think everything's good.

Yep, that was pretty much what was in my head. ifeq (or ifneq in your
example) to gate the extra nm check, and .DELETE_ON_ERROR to make the
failure stick for future make invocations.

--Jacob


view thread (57+ messages)  latest in thread

Message-ID: <05ced65e02e53c61bc182a24e385395c8a3718ff.camel@vmware.com>
Permalink:  ../05ced65e02e53c61bc182a24e385395c8a3718ff.camel@vmware.com/
Also on:    postgresql.org/message-id/05ced65e02e53c61bc182a24e385395c8a3718ff.camel@vmware.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: pchampion@vmware.com, peter.eisentraut@enterprisedb.com, tgl@sss.pgh.pa.us, daniel@yesql.se, michael@paquier.xyz
  Subject: Re: Preventing abort() and exit() calls in libpq
  In-Reply-To: <05ced65e02e53c61bc182a24e385395c8a3718ff.camel@vmware.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox