Bug 1046341 - xterm does not display EUCJP encoding
Summary: xterm does not display EUCJP encoding
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: libfontenc
Version: 19
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Hans de Goede
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-12-24 16:58 UTC by Christian Horn
Modified: 2014-11-03 05:23 UTC (History)
8 users (show)

Fixed In Version: libfontenc-1.1.2-3.fc21
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-11-03 05:23:45 UTC
Type: Bug


Attachments (Terms of Use)
rawhide from 2014/07/15 screenshot (80.86 KB, image/png)
2014-07-15 14:52 UTC, Christian Horn
no flags Details
Screenshot with proof of the pudding (115.32 KB, image/png)
2014-07-15 15:03 UTC, Hans de Goede
no flags Details


Links
System ID Priority Status Summary Last Updated
Red Hat Bugzilla 1158468 unspecified CLOSED problems to print pure text files with the lpr or lp command in F21: only blank sheets are printed 2020-10-14 00:28:05 UTC

Internal Links: 1158468

Description Christian Horn 2013-12-24 16:58:06 UTC
Description of problem:
  xterm does not display EUCJP encoding

Version-Release number of selected component (if applicable):
  xterm-293-1.fc19.x86_64
  (not sure if this is an issue in xterm, glibc or something else)

How reproducible:
  always

Steps to Reproduce:
1. # verify eucjp and utf8 locales exist
   locale -a|grep ja_JP   
2. # ensure this is a terminal capable of displaying the chars we request later
   LC_ALL="ja_JP.utf8" echo 日本語
   LC_ALL="ja_JP.utf8" date
3. LC_ALL="ja_JP.eucjp" luit
4. date

Actual results:
2013G/ 127n 24F| 2PMKF| 17:49:59 CET

Expected results:
2013年 12月 24日 火曜日 17:49:04 CET

Additional info:
- the above works on debian stable
- I tried to verify on RHEL7beta, but we do not ship luit there.
- tried this in "xterm -en eucjp" terminal, as well as gnome-terminal
- in the eucjp output, the high bits seem stripped off by something
- setting "stty raw" does not lead to the expected output
- also creating a utf8 textfile, converting to eucjp with "iconv" and outputting this gives same result
- the output of "date +%A| xxd|md5sum" in a "LC_ALL=ja_JP.eucjp luit" environment is identical on the debian and the fedora system

Comment 1 Miroslav Lichvar 2014-01-07 11:08:05 UTC
To me it looks like a problem in luit. With xorg-x11-apps-7.7-6.fc19 and in a UTF-8 terminal (I tried it with xterm and urxvt) I get:

$ LC_ALL=ja_JP.eucJP luit date
2014G/  17n  7F| 2PMKF| 12:02:33 CET
$ LC_ALL=ja_JP.eucJP date | iconv -f eucjp -t utf8
2014年  1月  7日 火曜日 12:02:33 CET

Comment 2 Christian Horn 2014-05-02 18:49:51 UTC
Same issue on RHEL7: bz1093788.

Comment 3 Hans de Goede 2014-07-15 10:35:57 UTC
Hi,

This works for me in Fedora when using rawhide, using gnome-terminal (I seem to be missing a font to get it to work in xterm). Can you please re-test on Fedora 20 ?

Thanks,

Hans

Comment 4 Christian Horn 2014-07-15 10:55:25 UTC
The steps from #0 and #1 still fail on current Fedora20 for me. Let me setup a raw in a VM and retest..

Comment 5 Christian Horn 2014-07-15 14:49:09 UTC
Hm.. fails for me still on rawhide, attaching screenshot.

Comment 6 Christian Horn 2014-07-15 14:52:15 UTC
Created attachment 918184 [details]
rawhide from 2014/07/15 screenshot

Comment 7 Hans de Goede 2014-07-15 15:03:53 UTC
Created attachment 918190 [details]
Screenshot with proof of the pudding

Works for me, see my screenshot :)

Tested on 2 different rawhide installs.

Can you do (in a terminal): "printenv | grep LC" and paste the output here?

Comment 8 Christian Horn 2014-07-16 08:29:15 UTC
[root@localhost chris]# LC_ALL="ja_JP.utf8" echo 日本語
日本語
[root@localhost chris]# LC_ALL="ja_JP.utf8" date
2014年  7月 16日 水曜日 04:24:22 EDT
[root@localhost chris]# LC_ALL="ja_JP.eucjp" luit
[root@localhost chris]# date
2014G/  77n 16F| ?eMKF| 04:24:27 EDT
[root@localhost chris]# printenv | grep LC
LC_ALL=ja_JP.eucjp
[root@localhost chris]# 

Same for xterm, and an access via VNC vs. x-forwarded terminal (but the latter 2 variants I expected to be similiar anyway)

I deployed a Fedora in this VM and then upgraded via yum to rawhide.
Well, if you see the issue on RHEL7 as I do and see it fixed in rawhide, we could also just asume a mistake here on my setup and these 2 states could help you to see more on the difference between working/nonworking.

Comment 9 Hans de Goede 2014-07-16 09:11:21 UTC
Ok, I've managed to reproduce and fix this using a somewhat minimal F-20 install. To fix this do the following (both as root):

yum install xorg-x11-fonts-misc
ln -s ../X11/fonts /usr/share/fonts/X11

I'll add the symlink to the xorg-x11-fonts-misc package, and a requires to xorg-x11-apps for xorg-x11-fonts-misc, I plan to only do this for rawhide / F-21 though, as I do not consider this bug important enough to roll out updates for existing Fedora releases.

Comment 10 Christian Horn 2014-07-16 09:59:47 UTC
Works, thanks!

Comment 11 Hans de Goede 2014-07-19 15:02:48 UTC
Fixed for F-21+, note I've ended up adding the symlink to xorg-x11-font-utils, as that seems to be the xorg fonts equivalent of fontpackages-filesystem.

Comment 12 Hans de Goede 2014-10-31 11:10:08 UTC
Note adding the /usr/share/fonts/X11 symlink to xorg-x11-font-util turns out to be a bad idea as that causes all the old X fonts to be part of the default font search path, which is not what we want.

So instead we need to fix luit, or actually libfontenc to search for the encoding files in the proper place. I'm preparing a patch for that now.

Comment 13 Fedora Update System 2014-10-31 13:16:13 UTC
libfontenc-1.1.2-3.fc21,xorg-x11-font-utils-7.5-23.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/libfontenc-1.1.2-3.fc21,xorg-x11-font-utils-7.5-23.fc21

Comment 14 Fedora Update System 2014-11-01 17:03:24 UTC
Package libfontenc-1.1.2-3.fc21, xorg-x11-font-utils-7.5-23.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing libfontenc-1.1.2-3.fc21 xorg-x11-font-utils-7.5-23.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-14122/libfontenc-1.1.2-3.fc21,xorg-x11-font-utils-7.5-23.fc21
then log in and leave karma (feedback).

Comment 15 Fedora Update System 2014-11-03 05:23:45 UTC
libfontenc-1.1.2-3.fc21, xorg-x11-font-utils-7.5-23.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.