Re: meson and tmp_install

From: Andres Freund <andres(at)anarazel(dot)de>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: meson and tmp_install
Date: 2022-12-20 17:29:58
Message-ID: 20221220172958.i4lbgw7h47mw7jkl@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On 2022-12-20 07:12:04 -0500, Andrew Dunstan wrote:
> Yesterday when testing a patch I got annoyed when my test failed. I
> tested it like this:
>
> meson test ldap_password_func/001_mutated_bindpasswd
>
> It turned out that I needed to do this:
>
> meson test tmp_install ldap_password_func/001_mutated_bindpasswd
>
> The Makefile equivalent ensures that you have a tmp_install without
> having to request to explicitly. It would be nice if we could make meson
> do the same thing, and also honor NO_TEMP_INSTALL if set.

I would like that too, but there's no easy fix that doesn't have
downsides as far as I am aware. We could make the temp install a build
target that the tests depend on, but for historical reasons in meson
that means that the 'all' target depends on temp-install. Which isn't
great.

My current thinking is that we should get away from needing the
temporary install and instead allow to run the tests against the build
directory itself. The temp-install adds a fair bit of overhead and
failure potential. The only reason we need it is that a) initdb and a
few other programs insist that postgres needs to be in the same
directory b) contrib modules currently need to reside in one single
directory.

Greetings,

Andres Freund

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2022-12-20 17:35:58 Re: meson files copyright
Previous Message Andres Freund 2022-12-20 17:25:24 Re: meson files copyright