i18n module only checks for gettext and misses xgettext
See original GitHub issueDescribe the bug
We have a configure file in our build that uses i18n.merge_file
. In the users log we saw
Program gettext found: YES (/usr/bin/gettext)
But when Meson reached the i18n.merge_file
this error was spit out.
WARNING: Gettext not found, all translation targets will be ignored.
To Reproduce
It took some time to figure out, but the user is on Debian stable, but the issue was that they had gettext-base
installed that contains /usr/bin/gettext
but xgettext
that i18n.merge_file
requires is actually in the gettext
package.
Expected behavior
It would have been awesome if when detecting the gettext binary, meson would check for xgettext as well if i18n.merge_file
is in use. If it couldn’t find it, it would be much nicer if it would mention the executable it was looking for as I had to dig through the meson source to figure out what it was complaining about as the user already verified that they had /usr/bin/gettext
installed.
system parameters
The user was on Debian stable with meson 0.56.2, but their system isn’t relevant here out side of the gettext-base
was installed but gettext
was not installed scenario.
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (6 by maintainers)
I opened a PR which fixes this in two ways:
WARNING: Gettext not found [...]
is still printed, but immediately beforehand it also mentions the exact tool name it is looking for, so that should presumably be easy to interpret.Thanks!