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

Re: new proposal: Translating Debian packages' descriptions



Hi Michael,

On Thu, 13 Sep 2001, Michael Bramer wrote:

> > The end-user tools would never have to deal with outdated translations if the
> > ".mo" file is assembled ahead of time in a central location.  Match up the
> > translations, insert them into the distilled .po file using the package
> > name/version as the key, and you're done.

> one point:
>  I get the package-1.2 from 'commercial german distributor' with german
>  translation. And I watch (with apt-cache show) the description
>  package-1.2.1 from security.debian.org?

>  I don't see the german description...

> other point:
>  I have a gnome-base-1.2 from HelixCode and show the description from
>  gnome-base-1.2 from debian... But the description from both packages
>  is not the same....

>  (I know our package management don't support this case, but we have
>  this case in real (maybe)...)

This is an interesting point, but the solution is simple.  If package+version
can't be used as a key to uniquely identify packages in the dpkg status
database, then we key on whatever /is/ used by this database.

> next point:
>  You have in your apt-source some sources. Like a older CD-Rom with
>  2.1 and 2.2_r0, a uptodate 2.2_r3 from ftp.debian.org, testing and
>  sid from http.debian.org.

>  With this you have alle descriptions many times in the .mo file.
>  (like package-0.9 from 2.1, package-1.4 from 2.2_r0, package-1.4.1
>  from 2.2_r3 and package-1.5 from testing and sid...)

If the descriptions remain constant for the packages, you're correct that
there would be duplication.  But should we not optimize for the common case?
Most users won't keep /old/ sources in the list; few will even have testing,
unstable, and stable in the list at the same time.

And if we use a file format other than .mo files, it's also possible to design
a system of indirect lookups that /still/ edges out standard gettext lookups
for efficiency.

> > I'm not suggesting replacing the format that translators will work with.  I'm
> > just disagreeing that standard .mo files are the best solution to be
> > integrated into dpkg and apt.
> ...
> > More direct lookups.  Smaller .po files.  Better integration with existing
> > tools, instead of grafting a new arm onto our existing /var/lib/dpkg
> > structure.

> Yes, .mo files are not the best thing. this is your point and you are
> right.

> But this is a other problem and we can solve this problem parallel.

> I propose this:
>   - use (a unchanged) gettext now in dpkg and get the thing rolling.
>   - change the gettext to use a optional 'md5sum-like' thing for a
>     lookups.

>     (save the translation with the md5sum of the orignal text as key)

For the goal of getting support for translated descriptions into Debian as
soon as possible, I think use of unmodified gettext is a reasonable choice.

Steve Langasek
postmodern programmer



Reply to: