pgsql: meson: Avoid PATH bloat from NLS .mo targets in tmp_install test

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: meson: Avoid PATH bloat from NLS .mo targets in tmp_install test
Date: 2026-11-01 21:44:26
Message-ID: E1xNdLm-00000001i0h-09uQ@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

meson: Avoid PATH bloat from NLS .mo targets in tmp_install test

On Windows, meson adds the build directory of every target in a test's
'depends:' to that test's PATH. tmp_install depended on
installed_targets, which with NLS enabled includes several hundred .mo
targets, pushing PATH past the Windows length limit. tmp_install and
initdb_cache then failed with no output.

Fix by depending on a stamp custom_target that itself depends on
installed_targets. Meson doesn't walk a custom_target's dependencies
when building the test PATH, so this adds at most one entry. This can
be removed once we mandate a meson version containing the upstream fix
(expected in 1.13).

Reviewed-by: Tristan Partin <tristan(at)partin(dot)io>
Backpatch-through: 16
Discussion: https://postgr.es/m/CAD5tBcJXAX8bz5q9ngE4znvVLiXaPO89D0yTFhJgEPrPyT-Erw@mail.gmail.com

Branch
------
REL_19_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/ab5a39e1672e28b59e7699b6d8f461ef9f4b3874

Modified Files
--------------
meson.build | 19 ++++++++++++++++++-
1 file changed, 18 insertions(+), 1 deletion(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2026-11-01 22:28:32 pgsql: Move plpython's rejection of pseudotype arguments/results.
Previous Message Daniel Gustafsson 2026-11-01 19:14:40 pgsql: doc: Add missing field description for postmaster.pid