<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>1379</bug_id>
          
          <creation_ts>2002-10-08 23:24:04 +0400</creation_ts>
          <short_desc>GROUP value printed in Russian in other locales</short_desc>
          <delta_ts>2005-12-19 17:12:59 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>rpm</component>
          <version>unstable</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P5</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="imz">vanyaz</reporter>
          <assigned_to name="placeholder@altlinux.org">placeholder</assigned_to>
          <cc>at</cc>
    
    <cc>glebfm</cc>
    
    <cc>imz</cc>
    
    <cc>ldv</cc>
    
    <cc>placeholder</cc>
    
    <cc>vt</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1300</commentid>
    <comment_count>0</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-08 23:24:04 +0400</bug_when>
    <thetext>I\&apos;m testing how rpm prints localized values in mainly UTF-8 locales. The results differ between rpm-4.0.4-alt4 and
rpm-4.0.4-alt7, but both are not correct.
---
With rpm-4.0.4-alt7:

$ LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Коммуникации

date demonstrates that genrally the specified locale is valid:

$ LANG=de_AT.UTF-8 date -d \&apos;Jan 6 2002\&apos;
Son Jц╓n  6 00:00:00 MSK 2002

With LANG=\&apos;\&apos;, LANG=en and LANG=de rpm prints the English word (which I consider to be correct if there is no German translation available). With LANG=en_US, LANG=de_DE -- the Russian in KOI8-R (incorrect).

rpm-4.0.4-alt4 is the same except for that it doesn\&apos;t covert the output string to UTF-8 -- always KOI8-R.

---

</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>4236</commentid>
    <comment_count>1</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2002-10-09 18:20:03 +0400</bug_when>
    <thetext>It\&apos;s because of algorithm implemented in rpm.

lib/header.c:headerFindI18NString()
checks environment variables in this order:
LC_ALL, LC_MESSAGES, LANG.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7601</commentid>
    <comment_count>2</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2002-10-09 18:20:03 +0400</bug_when>
    <thetext>It\&apos;s because of algorithm implemented in rpm.

lib/header.c:headerFindI18NString()
checks environment variables in this order:
LC_ALL, LC_MESSAGES, LANG.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>4237</commentid>
    <comment_count>3</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:30:07 +0400</bug_when>
    <thetext>What does it mean: \&amp;quot;checks environment variables in this order\&amp;quot;: latter override former or vice versa?

This still doen\&apos;t explain why only changing LANG with the rest of the environment remaining the same we can get either English (with invalid (?) LANG=\&apos;\&apos;, LANG=en and LANG=de) or Russian (LANG=de_AT.UTF-8) Group names:

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7602</commentid>
    <comment_count>4</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:30:07 +0400</bug_when>
    <thetext>What does it mean: \&amp;quot;checks environment variables in this order\&amp;quot;: latter override former or vice versa?

This still doen\&apos;t explain why only changing LANG with the rest of the environment remaining the same we can get either English (with invalid (?) LANG=\&apos;\&apos;, LANG=en and LANG=de) or Russian (LANG=de_AT.UTF-8) Group names:

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>4238</commentid>
    <comment_count>5</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:35:22 +0400</bug_when>
    <thetext>Here are the corresponding locale values: LC_MESSAGES is unset, LC_ALL is empty (also unset).

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ locale
LANG=ru_RU.KOI8-R
LC_CTYPE=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_NUMERIC=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_TIME=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_COLLATE=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_MONETARY=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_MESSAGES=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_PAPER=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_NAME=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_ADDRESS=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_TELEPHONE=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_MEASUREMENT=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_IDENTIFICATION=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_ALL=
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de_AT.UTF-8 locale
LANG=de_AT.UTF-8
LC_CTYPE=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_NUMERIC=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_TIME=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_COLLATE=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_MONETARY=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_MESSAGES=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_PAPER=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_NAME=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_ADDRESS=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_TELEPHONE=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_MEASUREMENT=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_IDENTIFICATION=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_ALL=
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de locale
LANG=de
LC_CTYPE=\&amp;quot;de\&amp;quot;
LC_NUMERIC=\&amp;quot;de\&amp;quot;
LC_TIME=\&amp;quot;de\&amp;quot;
LC_COLLATE=\&amp;quot;de\&amp;quot;
LC_MONETARY=\&amp;quot;de\&amp;quot;
LC_MESSAGES=\&amp;quot;de\&amp;quot;
LC_PAPER=\&amp;quot;de\&amp;quot;
LC_NAME=\&amp;quot;de\&amp;quot;
LC_ADDRESS=\&amp;quot;de\&amp;quot;
LC_TELEPHONE=\&amp;quot;de\&amp;quot;
LC_MEASUREMENT=\&amp;quot;de\&amp;quot;
LC_IDENTIFICATION=\&amp;quot;de\&amp;quot;
LC_ALL=
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7603</commentid>
    <comment_count>6</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:35:22 +0400</bug_when>
    <thetext>Here are the corresponding locale values: LC_MESSAGES is unset, LC_ALL is empty (also unset).

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ locale
LANG=ru_RU.KOI8-R
LC_CTYPE=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_NUMERIC=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_TIME=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_COLLATE=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_MONETARY=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_MESSAGES=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_PAPER=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_NAME=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_ADDRESS=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_TELEPHONE=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_MEASUREMENT=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_IDENTIFICATION=\&amp;quot;ru_RU.KOI8-R\&amp;quot;
LC_ALL=
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de_AT.UTF-8 locale
LANG=de_AT.UTF-8
LC_CTYPE=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_NUMERIC=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_TIME=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_COLLATE=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_MONETARY=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_MESSAGES=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_PAPER=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_NAME=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_ADDRESS=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_TELEPHONE=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_MEASUREMENT=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_IDENTIFICATION=\&amp;quot;de_AT.UTF-8\&amp;quot;
LC_ALL=
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de locale
LANG=de
LC_CTYPE=\&amp;quot;de\&amp;quot;
LC_NUMERIC=\&amp;quot;de\&amp;quot;
LC_TIME=\&amp;quot;de\&amp;quot;
LC_COLLATE=\&amp;quot;de\&amp;quot;
LC_MONETARY=\&amp;quot;de\&amp;quot;
LC_MESSAGES=\&amp;quot;de\&amp;quot;
LC_PAPER=\&amp;quot;de\&amp;quot;
LC_NAME=\&amp;quot;de\&amp;quot;
LC_ADDRESS=\&amp;quot;de\&amp;quot;
LC_TELEPHONE=\&amp;quot;de\&amp;quot;
LC_MEASUREMENT=\&amp;quot;de\&amp;quot;
LC_IDENTIFICATION=\&amp;quot;de\&amp;quot;
LC_ALL=
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>4239</commentid>
    <comment_count>7</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:37:35 +0400</bug_when>
    <thetext>Several more strange examples:

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de_AT.UTF-8 LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ echo $LANGUAGE 
ru_RU.KOI8-R
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7604</commentid>
    <comment_count>8</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:37:35 +0400</bug_when>
    <thetext>Several more strange examples:

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de_AT.UTF-8 LANG=de_AT.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ echo $LANGUAGE 
ru_RU.KOI8-R
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>4240</commentid>
    <comment_count>9</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:46:15 +0400</bug_when>
    <thetext>If we assume that LANGUAGE is the variable that specifies the language of Group value (and neither LANG nor LC_*), then this test remains unexplained:

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru_RU.KOI8-R LANG=invalid rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7605</commentid>
    <comment_count>10</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 20:46:15 +0400</bug_when>
    <thetext>If we assume that LANGUAGE is the variable that specifies the language of Group value (and neither LANG nor LC_*), then this test remains unexplained:

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru_RU.KOI8-R LANG=invalid rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>4241</commentid>
    <comment_count>11</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2002-10-09 21:10:30 +0400</bug_when>
    <thetext>I\&apos;ve planned to add LANGUAGE to the head of the variables list rpm uses in that algorithm.
rpm-4.1 also checks LANGUAGE.

(first nonempty variable from that list is used.)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7606</commentid>
    <comment_count>12</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2002-10-09 21:10:30 +0400</bug_when>
    <thetext>I\&apos;ve planned to add LANGUAGE to the head of the variables list rpm uses in that algorithm.
rpm-4.1 also checks LANGUAGE.

(first nonempty variable from that list is used.)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>4242</commentid>
    <comment_count>13</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 22:51:28 +0400</bug_when>
    <thetext>After reading the info page on \&amp;quot;Using gettextized software\&amp;quot;, I think that 2 parallel list hav to be used by rpm for getting different information: (LANGUAGE, ) LC_ALL, LC_MESSAGES, LANG should be examined to get the language (perhaps, a short name like \&amp;quot;de\&amp;quot;), and LANGUAGE, LC_ALL, LC_CTYPE, LANG for the codeset to convert to. I\&apos;m not sure whether LANGUAGE should be included in the second list.

It seems that rpm does all this already (without LANGUAGE in the 2nd list):

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=en LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=de_DE.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=de rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=invalid rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de:ru LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de:ru_RU.UTF-8 LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de:ru_RU.UTF-8 LC_CTYPE=de_DE.ISO8859-1 rpmquery -q minicom --qf=%{GROUP}\\\\n 
????????????

If LC_TYPE is invalid, it outputs the English value.

I do not see any important misbahaviour. It seems it was my error to report this bug because I didn\&apos;t understand how all the locale variables work together quiet well.

This concerns GROUP. I see misbahaviour in recoding SUMMARY. They should be recoded just as the GROUPs are (and the error messages), I think. A testing script is attached. I run it twice:

cat /user/imz/test_i18n_rpm_language.sh |  sh
cat /user/imz/test_i18n_rpm_language.sh | sed -e \&apos;s!LANGUAGE!LC_MESSAGES!g\&apos; | sh

The results are different.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7607</commentid>
    <comment_count>14</comment_count>
    <who name="imz">vanyaz</who>
    <bug_when>2002-10-09 22:51:28 +0400</bug_when>
    <thetext>After reading the info page on \&amp;quot;Using gettextized software\&amp;quot;, I think that 2 parallel list hav to be used by rpm for getting different information: (LANGUAGE, ) LC_ALL, LC_MESSAGES, LANG should be examined to get the language (perhaps, a short name like \&amp;quot;de\&amp;quot;), and LANGUAGE, LC_ALL, LC_CTYPE, LANG for the codeset to convert to. I\&apos;m not sure whether LANGUAGE should be included in the second list.

It seems that rpm does all this already (without LANGUAGE in the 2nd list):

[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=en LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=de_DE.UTF-8 rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=de rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=ru LC_CTYPE=invalid rpmquery -q minicom --qf=%{GROUP}\\\\n | iconv -f utf-8 -t koi8-r
Communications
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de:ru LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de:ru_RU.UTF-8 LC_CTYPE=ru_RU.KOI8-R rpmquery -q minicom --qf=%{GROUP}\\\\n 
Коммуникации
[&lt;a href=&quot;mailto:imz@altair&quot; target=&quot;_new&quot;&gt;imz@altair&lt;/a&gt; imz]$ LANGUAGE=de:ru_RU.UTF-8 LC_CTYPE=de_DE.ISO8859-1 rpmquery -q minicom --qf=%{GROUP}\\\\n 
????????????

If LC_TYPE is invalid, it outputs the English value.

I do not see any important misbahaviour. It seems it was my error to report this bug because I didn\&apos;t understand how all the locale variables work together quiet well.

This concerns GROUP. I see misbahaviour in recoding SUMMARY. They should be recoded just as the GROUPs are (and the error messages), I think. A testing script is attached. I run it twice:

cat /user/imz/test_i18n_rpm_language.sh |  sh
cat /user/imz/test_i18n_rpm_language.sh | sed -e \&apos;s!LANGUAGE!LC_MESSAGES!g\&apos; | sh

The results are different.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>15659</commentid>
    <comment_count>15</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2004-06-27 02:23:50 +0400</bug_when>
    <thetext>Fixed in rpm-4.0.4-alt39</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>121</attachid>
            <date>2002-10-09 22:53:06 +0400</date>
            <delta_ts>2002-10-09 22:53:06 +0400</delta_ts>
            <desc>0001379-test_i18n_rpm_language.sh</desc>
            <filename>0001379-test_i18n_rpm_language.sh</filename>
            <type>application/x-sh</type>
            <size>522</size>
            <attacher name="imz">vanyaz</attacher>
            
              <data encoding="base64">IyEvYmluL2Jhc2gKClFVRVJZPSgtcSBycG0gJy0tcWY9JXtHUk9VUH1cbiV7U1VNTUFSWX1cbicp
Cgp0ZXN0KCkgewogICAgcnBtcXVlcnkgLXEgIiR7UVVFUllbQF19IgogICAgcnBtcXVlcnkgLXEg
LS1xZj0le0VSUn0KfQoKdW5zZXQgTEFORycnVUFHRSBMQU5HIExDX01FU1NBR0VTIExDX0NUWVBF
IExDX0FMTApleHBvcnQgTEFORycnVUFHRSBMQU5HIExDX01FU1NBR0VTIExDX0NUWVBFIExDX0FM
TAoKTEFORz1lbl9VUwojZXhwb3J0IExBTkcKCiNleHBvcnQgTEFOR1VBR0UgTENfQ1RZUEUKCmVj
aG8gIlVzaW5nIExBTkc9JExBTkcuLi4iCgpmb3IgTEFOR1VBR0UgaW4gcnUgZGUgcnVfUlUuS09J
OC1yIHJ1X1JVLlVURi04OyBkbwogICAgZm9yIExDX0NUWVBFIGluIHJ1X1JVLktPSTgtUiBydV9S
VS5VVEYtOCBkZV9ERS5JU084ODU5LTEgZGVfREUuVVRGLTggaW52YWxpZDsgZG8KCWVjaG8KCWVj
aG8gIkxBTkdVQUdFPSRMQU5HVUFHRTsgTENfQ1RZUEU9JExDX0NUWVBFOiAiCgl0ZXN0CiAgICBk
b25lCmRvbmUK
</data>

          </attachment>
      

    </bug>

</bugzilla>