bug-gettext
[Top][All Lists]
Advanced

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

Re: [bug-gettext] Bug#671257: gettext: msgfmt output format prevents mul


From: Santiago Vila
Subject: Re: [bug-gettext] Bug#671257: gettext: msgfmt output format prevents multiarch migration (fwd)
Date: Thu, 3 May 2012 10:56:06 +0200 (CEST)
User-agent: Alpine 2.02 (DEB 1266 2009-07-14)

[ Adding Steve Langasek, multiarch architect in Debian, to Cc list ].

On Thu, 3 May 2012, Bruno Haible wrote:

> Hi Santiago,
> 
> > A long time ago, people working on embedded systems in Debian had the
> > idea that it would be a good thing to have .mo files in the same
> > endianness as the architecture on which they are used.
> > 
> > However, the saving in cpu time was too small to justify the need to
> > have native endianness everywhere.
> > 
> > Well, the fact is that this change was made in gettext after all, and
> > now msgfmt creates .mo files in native endianness
> 
> I don't know where you got this history from. AFAIK, GNU 'msgfmt' always
> created .mo files in native endianness since the beginning (1995),
> up until 2005-08-26, when the option --endianness was introduced.

Hmm, 2005-08-26? Are you sure of that? I remember well the bug by Neil Williams:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=468209

where he asked --endianness to be documented, as he was thinking about
using it in his embedded projects to override the current msgfmt default of
always creating little endian .mo files.

This was in 2008. At that time, msgfmt always created little endian .mo files.

The response we gave to him was basically: "You don't need this option,
as .mo files are always little endian and gettext tools handle both
forms just fine. Period."

By "we" I mean the response I gave to him which later you mostly agreed as well:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=468209#37

So, imagine my surprise when I started to receive requests from
multiarch people so that msgfmt changes to be always little endian.


> Paul Martin writes:
> > packages with localized strings fail the requirement of 
> > multiarch of all shared files being identical across architectures.
> 
> Maybe the workaround is simply to exclude *.mo files from this requirement?
> Have you proposed this to the Debian people?

I guess people in charge of multiarch would much prefer not to do any
exceptions. In some way, they have declared the war to "gratuitous
differences in binary files", because, well, they are gratuitous!

> > i.e. we would like msgfmt to create always little endian .mo files, as
> > before.
> 
> You can achieve this behaviour by setting the two environment variables
>   MSGFMT="/usr/bin/msgfmt --endianness=little"
>   GMSGFMT="/usr/bin/msgfmt --endianness=little"
> during the 'configure' run, and forcing an update of the .mo files through
>   cd po ; make update-po
> after "make" has run.

Yes, we could do that, in each and every package, but somehow we feel
that's not the best way to solve this.

> I think it is not too difficult to integrate these two additions into
> Debian's build system (.spec files, templates, whatever)?

Debian's build system is a lot more heterogeneous than that.

Some people use debhelper, some people do not and write debian/rules
in their own style. Some people use debhelper ultrasimplified dh format,
some people do not.

The opinion of people in charge of multiarch is that in the long run,
it would be much better if msgfmt's default changed in gettext to be
little endian again.

[ Steve: I think this summarizes your feelings about this, feel free to
  add any thing I forgot or I didn't explain well to Bruno ].

Thanks.



reply via email to

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