From: Tristan Partin <tristan@neon.tech>
To: Andres Freund <andres@anarazel.de>
Cc: pgsql-hackers@postgresql.org
Subject: Re: Meson build updates
Date: Thu, 29 Jun 2023 14:07:19 -0500
Message-ID: <CTPDBT2W78PQ.2QUDVHFNR5MCS@gonk> (raw)
In-Reply-To: <20230629190242.kgnimiizjbvmdfni@awork3.anarazel.de>
References: <CSPIJVUDZFKX.3KHMOAVGF94RV@c3po>
<20230609164135.77fjwqkqzdxfs3f5@awork3.anarazel.de>
<CT8BP7BRV4A2.AOE7263UX2SH@gonk>
<20230609183603.o56z3ngtak6qhb3s@awork3.anarazel.de>
<CTBSCT2V1TVP.2AUJVJLNWQVG3@gonk>
<20230629190242.kgnimiizjbvmdfni@awork3.anarazel.de>
On Thu Jun 29, 2023 at 2:02 PM CDT, Andres Freund wrote:
> Hi,
>
> On 2023-06-13 14:56:36 -0500, Tristan Partin wrote:
> > I was thinking today. When you initially wrote the build, did you try
> > using the src/bin/meson.build file as the place where all the binaries
> > were built? As you say, most of the src/bin/xxx/meson.build files are
> > extrememly reptitive.
>
> > We had a similar-ish issue in my last project which I solved like:
> >
> > https://github.com/hse-project/hse/blob/master/tools/meson.build#L20-L405
> >
> > This is a pattern I used quite frequently in that project. One benefit
> > of this approach is that the binaries all end up next to each other in
> > the build tree which is eventually how they'll be laid out in the
> > install destination. The other benefit is of course reducing reptitive
> > code.
>
> I think the build directory and the source code directory not matching in
> structure would have made it considerably harder sell for people to migrate.
>
> I.e. I considered it, but due to meson's "no outputs outside of the current
> directory" rule, it didn't (and sadly still doesn't) really seem viable.
Yeah, I guess it is a matter if you like the layout being closer to the
installation or the source tree at the expense of repetition. I am
partial to the installation since it is less to type if you run a binary
from the build directory and less repetition, but all good. Maybe
something that could be reconsidered when autotools is dropped.
I still think the overrides are important, at the very least for libpq,
but I will defer to your aforementioned decision for now.
--
Tristan Partin
Neon (https://neon.tech)
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: tristan@neon.tech, andres@anarazel.de
Subject: Re: Meson build updates
In-Reply-To: <CTPDBT2W78PQ.2QUDVHFNR5MCS@gonk>
* 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