Re: evolution-exchange, pot-file missing



Rodney, 
Can you take a look at this soon (as in RSN, release is fast
approaching)?

I have been using patched intltool for my purposes, and I would
suggest other translators try it as well (patch inlined below â you
may patch your bin/intltool-update with it) until other solutions are
proposed. 

Yet, this is far from ideal, since we're omitting some error-checking
from intltool-update, which is, as always, a Bad Thing.  Perhaps we
can use shell command to check existence of POT file as well, like
"test -f $MODULE.pot" (again, with backticks, instead of system() call)?

Cheers,
Danilo


On August 30th, Danilo Segan wrote:

> Hi Rodney,
>
> ÐÑÑÐ Ñ 23:42, Rodney Dawes ÐÐÐÐÑÐ:
>
>> Kjartan broke configure.in on 2004-06-01 when he added the "no"
>> translation, by accidentally removing the -${BASE_VERSION} part
>> of the GETTEXT_PACKAGE declaration. There is a little bit of perl
>> I need to figure out and add to intltool to fix the problem, but
>> running "intltool-update <lang>" won't work where the GETTEXT_PACKAGE
>> string contains a shell evaluation that needs to occur. I'm not sure
>> why, but "intltool-update -p" works, and correctly checks for the pot
>> file. I want to fix it so that the shell expansions get evaluated
>> properly before being stored as variable values.
>
> I can tell you why it works "somewhat" ;-)
>
> It works because it is blindly passed into shell command (at least it
> appears that way, if you use --verbose option).  It fails when
> intltool tries to find if such a file exists, before going from -p
> (POT creation) onto updating a translation (msgmerge).
>
> You can "fix" it by simply omitting this test from intltool, and using
> Perl backticks for running msgmerge instead of system() call.  But
> this would fix only "shell-syntax" cases, and we'll surely get others
> with time.
>
>> It is not a static string, becuase static strings make it harder
>> to maintain. It is a bug in intltool, and will be fixed as soon as
>> I figure out how to do it properly, and can get the time to do so.
>
> Well, sure, that's the ideal solution, so be my guest ;-)  [I'm a bit
> afraid we'll replicate all of "make" parsing rules in intltool, but
> lets hope not]
>
> Here's the patch to do this.
>
> --- /brlja/bin/intltool-update~ Fri Aug 20 11:58:08 2004
> +++ /brlja/bin/intltool-update  Mon Aug 30 00:48:00 2004
> @@ -751,7 +751,7 @@
>  
>  sub POFile_Update
>  {
> -    -f "$MODULE.pot" or die "$PROGRAM: $MODULE.pot does not exist.\n";
> +    #-f "$MODULE.pot" or die "$PROGRAM: $MODULE.pot does not exist.\n";
>  
>      my ($lang, $outfile) = @_;
>  
> @@ -761,7 +761,7 @@
>      $outfile = "$lang.po" if ($outfile eq "");
>  
>      # I think msgmerge won't overwrite old file if merge is not successful
> -    system ("msgmerge", "-o", $outfile, $infile, "$MODULE.pot");
> +    print `msgmerge -o $outfile $infile $MODULE.pot`;
>  }
>  
>  sub Console_WriteError_NotExisting
> *** cut here ***
>
> Cheers,
> Danilo
> _______________________________________________
> gnome-i18n mailing list
> gnome-i18n gnome org
> http://mail.gnome.org/mailman/listinfo/gnome-i18n


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