CRM-13068: load .mo files from l10n/xx_XX/LC_MESSAGES/civicrm.mo
authorMathieu Lutfy <mathieu@bidon.ca>
Fri, 2 May 2014 00:27:51 +0000 (20:27 -0400)
committerMathieu Lutfy <mathieu@bidon.ca>
Fri, 2 May 2014 01:39:25 +0000 (21:39 -0400)
commitb395e3c0ecca40ab0e03efe161ae81fcd3b4510e
tree5bbb42c878174d5eb2bfd4ee87297c449f7fbc9c
parente81b4d33bdedc9d802c659d3fef2e74fed133c27
CRM-13068: load .mo files from l10n/xx_XX/LC_MESSAGES/civicrm.mo

Since 4.3, CiviCRM supports two gettext implementations: phpgettext
(default) and native gettext. The performance of native gettext is
much better, but requires a specific file hierarchy and that the
operating system has support for the locale (dpkg-reconfigure locale).

Now that the release scripts package the files as:
l10n/xx_XX/LC_MESSAGES/civicrm.mo, instead of
l10n/xx_XX/civicrm.mo, we needed to modify phpgettext to load the
files from the new directory. However, we also support the old
hierarchy as a fallback, so that we do not break the build scripts
of people who do not use phpgettext.
CRM/Core/I18n.php