po entry made obsolete on make

slideshowbob

Joined: 2007-11-27
Posts: 2
Posted: Tue, 2007-11-27 08:58

Hi all,

I tried to modify the entry for "Add Album" in /modules/core/po/zh_TW.po. This was for the "Add Album" item link defined in module.inc. Then, following the instructions on the Gallery::Localization page, I did a "make install PO=zh_TW" in the po directory. However, not only did the new translated text fail to appear ("Add Album" was shown instead), when I looked at the contents of zh_TW.po, the entry was marked as obsolete (i.e. prepended by a "#~").

So, on a fresh install of gallery-2.2.3, I did "make test.po" in the same directory. According to the Localization page, this should scan for {g->text} tags in tpl files and translate()/i18n() in php code and place appropriate entries in test.po. But when I looked at the resulting test.po file, the "Add Album" entry was missing. It was as though module.inc did not get scanned at all.

Is this a bug or did I do something wrong?

Thanks.

Bob

 
slideshowbob

Joined: 2007-11-27
Posts: 2
Posted: Wed, 2007-11-28 15:13

OK, the problem lies not with gallery itself but version 7.0 (18-Dec-2006) of the PCRE regexp library which came bundled with php-5.2.2 that I was using. Due to a bug in that version of PCRE no match was found when scanning for translate()/i18n()... in the .inc files. Now I have upgraded php to version 5.2.5 which uses PCRE 7.3 2007-08-28 and everything is working as expected.

Regards,

Bob

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Fri, 2007-12-07 13:40

interesting. i guess that bug was neither present in earlier nor in later php versions. else we should have seen it too.

--------------
Documentation: Support / Troubleshooting | Installation, Upgrade, Configuration and Usage