Bug 5226

Summary: luit fails to find locale.alias
Product: xorg Reporter: Egmont Koblinger <egmont>
Component: App/luitAssignee: Xorg Project Team <xorg-team>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: high CC: patrakov
Version: 6.99.99.902 (7.0 RC2)   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Bug Depends on:    
Bug Blocks: 1690    

Description Egmont Koblinger 2005-12-02 23:58:02 UTC
The path to locale.alias is hardcoded into luit's source, namely in parser.h:
#ifndef LOCALE_ALIAS_FILE
#define LOCALE_ALIAS_FILE "/usr/X11R6/lib/X11/locale/locale.alias"
#endif

LOCALE_ALIAS_FILE is not defined anywhere else neither in luit's source nor
in any other X library's source. As a result, luit tries to open
/usr/X11R6/lib/X11/locale/locale.alias, but it fails since libx11 has
installed this file to a different location (and anyway it'll be X11R7 soon).

As a result, luit starts up with a warning like this:
Warning: couldn't find charset data for locale hu_HU; using ISO 8859-1.
and then operates incorrectly since assumes an incorrect charset.

Suggested fixes:

either: preprocess parser.h, just as luit.man is preprocessed now, so the
manpage of luit mentions the real location of my locale.alias file;

or: define LOCALE_ALIAS_FILE in a header file shipped by libx11 (which ships
this locale.alias file too) and make sure to include this from luit.
Comment 1 Kevin E. Martin 2005-12-09 17:15:35 UTC
Fixed in CVS.
Thanks for the bug report.
Comment 2 Alexander E. Patrakov 2006-02-28 00:43:44 UTC
*** Bug 5470 has been marked as a duplicate of this bug. ***

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.