Author: pb
Date: 2005-12-29 13:05:26 +0000 (Thu, 29 Dec 2005)
New Revision: 1083

Modified:
   glibc-package/trunk/debian/changelog
   glibc-package/trunk/debian/debhelper.in/libc.postinst
   glibc-package/trunk/debian/local/manpages/locale-gen.8.sgml
   glibc-package/trunk/debian/local/usr_sbin/locale-gen
Log:
  * Apply patch from Colin Watson to add "--keep-existing" option to
    locale-gen.  (Closes: #298913)
  * Also restart exim4 on upgrade.  (Closes: #326554)



Modified: glibc-package/trunk/debian/changelog
===================================================================
--- glibc-package/trunk/debian/changelog        2005-12-28 23:47:05 UTC (rev 
1082)
+++ glibc-package/trunk/debian/changelog        2005-12-29 13:05:26 UTC (rev 
1083)
@@ -24,6 +24,9 @@
     request of Joey Hess.  (Closes: #344954)
   * sysdeps/hppa.mk: Add new /usr/hppa64-linux-gnu/include symlink, per
     request of Matthias Klose.  (Closes: #326583)
+  * Apply patch from Colin Watson to add "--keep-existing" option to
+    locale-gen.  (Closes: #298913)
+  * Also restart exim4 on upgrade.  (Closes: #326554)
 
   [ Clint Adams ]
   * Steal glibc-235-sparc-datastart.dpatch from Ubuntu.

Modified: glibc-package/trunk/debian/debhelper.in/libc.postinst
===================================================================
--- glibc-package/trunk/debian/debhelper.in/libc.postinst       2005-12-28 
23:47:05 UTC (rev 1082)
+++ glibc-package/trunk/debian/debhelper.in/libc.postinst       2005-12-29 
13:05:26 UTC (rev 1083)
@@ -264,7 +264,7 @@
        if dpkg --compare-versions $preversion lt 2.3.5-1; then
            echo -n "Checking for services that may need to be restarted..."
 
-           check="nis smail sendmail exim ssh netbase"
+           check="nis smail sendmail exim exim4-base ssh netbase"
            check="$check ssh-nonfree postfix-tls wu-ftpd boa cron postfix"
            check="$check wu-ftpd-academ vsftpd slapd openldapd wwwoffle"
            check="$check cupsys lprng lpr lpr-ppd autofs snmpd ssh-krb5"
@@ -277,6 +277,9 @@
            # apache2 ships its init script in apache2-common, but the
            # script is apache2
            check=$(echo $check | sed 's/apache2-common/apache2/g')
+           # exim4 ships its init script in exim4-base, but the script
+           # is exim4
+           check=$(echo $check | sed 's/exim4-base/exim4/g')
            # The name of proftpd-{ldap,mysql,pgsql} init script is
            # same as "proftpd".
            check=$(echo $check | sed 's/proftpd-.*/proftpd/g')

Modified: glibc-package/trunk/debian/local/manpages/locale-gen.8.sgml
===================================================================
--- glibc-package/trunk/debian/local/manpages/locale-gen.8.sgml 2005-12-28 
23:47:05 UTC (rev 1082)
+++ glibc-package/trunk/debian/local/manpages/locale-gen.8.sgml 2005-12-29 
13:05:26 UTC (rev 1083)
@@ -13,7 +13,7 @@
   <!ENTITY dhfirstname "<firstname>Eduard</firstname>">
   <!ENTITY dhsurname   "<surname>Bloch</surname>">
   <!-- Please adjust the date whenever revising the manpage. -->
-  <!ENTITY dhdate      "<date>July  27, 2001</date>">
+  <!ENTITY dhdate      "<date>March 10, 2005</date>">
   <!-- SECTION should be 1-8, maybe w/ subsection other parameters are
        allowed: see man(7), man(1). -->
   <!ENTITY dhsection   "<manvolnum>8</manvolnum>">
@@ -54,6 +54,7 @@
   <refsynopsisdiv>
     <cmdsynopsis>
       <command>&dhpackage;</command>
+      <arg><option>--keep-existing</option></arg>
 
     </cmdsynopsis>
   </refsynopsisdiv>
@@ -80,6 +81,24 @@
 
   </refsect1>
   <refsect1>
+    <title>OPTIONS</title>
+
+    <variablelist>
+      <varlistentry>
+        <term><option>--keep-existing</option></term>
+        <listitem>
+          <para>By default, <command>&dhpackage;</command> removes all
+          existing locales and generates new ones afresh. The
+          <option>--keep-existing</option> option prevents this, so that
+          only locales which do not already exist are generated. This is
+          useful if calling locale-gen a number of times in
+          succession.</para>
+        </listitem>
+      </varlistentry>
+    </variablelist>
+
+  </refsect1>
+  <refsect1>
     <title>FILES</title>
 
     <para><filename>/etc/locale.gen</filename></para>

Modified: glibc-package/trunk/debian/local/usr_sbin/locale-gen
===================================================================
--- glibc-package/trunk/debian/local/usr_sbin/locale-gen        2005-12-28 
23:47:05 UTC (rev 1082)
+++ glibc-package/trunk/debian/local/usr_sbin/locale-gen        2005-12-29 
13:05:26 UTC (rev 1083)
@@ -11,10 +11,17 @@
 
 [ -f $LOCALEGEN -a -s $LOCALEGEN ] || exit 0;
 
-# Remove all old locale dir and locale-archive before generating new
-# locale data.
-rm -rf /usr/lib/locale/* || true
+KEEP=
+if [ "$1" = '--keep-existing' ]; then
+       KEEP=1
+fi
 
+if [ -z "$KEEP" ]; then
+       # Remove all old locale dir and locale-archive before generating new
+       # locale data.
+       rm -rf /usr/lib/locale/* || true
+fi
+
 umask 022
 
 is_entry_ok() {
@@ -30,6 +37,10 @@
 while read locale charset; do \
        case $locale in \#*) continue;; "") continue;; esac; \
        is_entry_ok || continue
+       if [ "$KEEP" ] && PERL_BADLANG=0 perl -MPOSIX -e \
+           'exit 1 unless setlocale(LC_ALL, $ARGV[0])' "$locale"; then
+               continue
+       fi
        echo -n "  `echo $locale | sed 's/\([EMAIL PROTECTED]).*/\1/'`"; \
        echo -n ".$charset"; \
        echo -n `echo $locale | sed 's/\([EMAIL PROTECTED])\([EMAIL 
PROTECTED])*/\2/'`; \


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to