Re: [RFC PATCH v4 00/19] Modernize the build system
- From
Jeff King <peff@peff.net>
- Date
- Nov 12, 2024, 02:21 UTC
- Message-ID
- <20241112022104.GA77521@coredump.intra.peff.net>
- In-Reply-To
- <f3b00260-ec3d-4607-aaf7-9cfd9898434f@gentoo.org>
On Mon, Nov 11, 2024 at 06:55:38PM -0500, Eli Schwartz wrote:
Show 11 quoted lines
> On 11/11/24 5:13 PM, Jeff King wrote:
> > No, they don't. I don't have msgfmt on my system at all, and always
> > build with NO_GETTEXT.
>
> Well, even systems without msgfmt installed may have the gettext()
> family of symbols available. On various systems, it may even be built
> into their libc.
>
> So, detecting and handling this case sensibly out of the box would be
> good, which I guess means checking for find_program('msgfmt') inside of
> po/meson.buildYes, this is a glibc system where gettext() is in the libc. I agree the fault is in po/meson.build which is not ready to handle the null return from import('i18n'). So it is not handling the case where gettext() is available but msgfmt is not.
Mostly I was responding to your original question, though, which is: do the tests need translations. They definitely do not, as I do not generally build Git with gettext support at all. So if there is a dependency there, it seems wrong.
> That being said, the meson way to handle NO_GETTEXT is to use the build > option > > meson setup builddir -Dgettext=disabled
Yes, that does get "meson setup" to complete for me. That gives me two other questions:
- how would I know this option exists? I think you mentioned elsewhere in the thread the ability to ask about which options exist, but I couldn't find anything via "meson -h", etc.
- is there a way to put configuration like this in a file, similar to our current config.mak?
-Peff