Bug#272478: libglib2.0-0: Shouldn't require to set G_FILENAME_ENCODING in non UTF-8 locale

Laurent Martelli Laurent Martelli <laurent@aopsys.com>, 272478@bugs.debian.org
Mon, 20 Sep 2004 22:16:14 +0200


>>>>> "Josselin" == Josselin Mouette <joss@debian.org> writes:

  Josselin> Le lundi 20 septembre 2004 à 20:15 +0200, Laurent Martelli
  Josselin> a écrit :
  >> >>>>> "Sebastien" == Sebastien Bacher <seb128@debian.org> writes:
  >> 
  Sebastien> severity 272478 wishlist tag 272478 + wontfix thanks
  >>
  Sebastien> Hi,
  >>
  Sebastien> This has already been discuted again and again upstream,
  Sebastien> there is no better solution than the current one to have
  Sebastien> a working utf-8 support.  I'll add some pointers to
  Sebastien> previous discussion a big later. For the moment I change
  Sebastien> the severity of the bug to wishlist + wontfix since
  Sebastien> upstreams are not going to change that.
  >>  If a user wants UTF-8 filenames, shouldn't he use an utf-8
  >> locale ?  And all will be fine for him with a patch like
  >> mine. The current behavious is completly bogus with a non utf-8
  >> locale since programs use the locale's encoding for filenames. Am
  >> I missing something ?

  Josselin> You're missing the point; especially, the locale setting
  Josselin> is not system- wide, and the files' accessibility
  Josselin> shouldn't be affected by a locale change. As there is no
  Josselin> way to tell a filesystem which encoding the filenames are
  Josselin> in, the only solution is to use a single encoding for all
  Josselin> files.

Sure, but then all programs which do not consider that filenames are
utf-8 encoded are buggy. And theer is quite a number of them. So I
think it would be best for the consistency of the system that all
programs behave the same "buggy" way. Or none at all.

Like I said to Sébastien in private, it seems worse to me that a user
cannot handle 2 file with 2 programs under the same locale than one
program with 2 different locales. Systems where different users use
different locales are not going to be fixed overnight with the
behaviour of glib. They will have to reencode all their filenames in
utf-8 and be sure that users use only utf-8 locales (in order to be
able to use all the programs still buggy). I believe the transition
would be smoother for all the systems like mine (one encoding is used
on all the system by all users) -- and not harder for others using
mixed locales -- if glib defaulted to using the locale's encoding for
filenames.

Regards,
Laurent

-- 
Laurent Martelli
laurent@aopsys.com                                Java Aspect Components
http://www.aopsys.com/                          http://jac.objectweb.org