[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gettext don't search on bindtextdomain dir

From: Samega 7Cattac
Subject: gettext don't search on bindtextdomain dir
Date: Fri, 11 Dec 2020 23:13:09 +0000

I made a little test code to test gettext.
The point was to change language even if it's not listed on `locale -a` like, for example, inkscape does.

test code: http://ix.io/2HCN

The idea is straightforward I have the .mo files inside a `locales` folder on the project dir, inside it it's the language, in this test I created "pt_PT" and "ja_JP" and inside both "LC_MESSAGES".
I set the bindtextdomain to the locales folder and I changed the LANG env var to change the language, pt_PT worked but ja_JP didn't.

normal output: http://ix.io/2HCa

When I did a strace I noticed that if the language isn't on `locale -a` it doesn't try to read from the bindtextdomain but from the default system path instead.
output with strace: http://ix.io/2HCf

reply via email to

[Prev in Thread] Current Thread [Next in Thread]