[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#168345: locales: impossible to configure noninteractive on first time install



Package: locales
Version: 2.2.5-14

At the moment it is impossible to preconfigure fthe locales package
for the first time install.

I would like to supply a debconf value in the
locales/locales_to_be_generated variable, and get the locales package
to create /etc/locale.gen based on the content of this debconf answer.
This fail, because locales.config will reset the value to '' before
asking debconf for the answer.  The following patch fixes the
situation for the first time install, while still using the content of
/etc/locale.gen if it exists.

Please fix this in Woody too.  The Skolelinux distribution needs it.

--- locales.config.orig Fri Nov  8 20:25:40 2002
+++ locales.config      Fri Nov  8 20:26:09 2002
@@ -175,6 +175,7 @@
 if test -f /etc/locale.gen; then
   LG=/etc/locale.gen
   SELECTED_LOCALES=$(egrep -v "^#|^$" $LG | tr "\n" "," | sed -e "s/,/, /g" -e
"s/, *$//")
+  db_set locales/locales_to_be_generated "${SELECTED_LOCALES}"
 else
   LG=/dev/null
 fi
@@ -184,7 +185,6 @@
 . /usr/share/debconf/confmodule
 db_version 2.0

-db_set locales/locales_to_be_generated "${SELECTED_LOCALES}"
 db_subst locales/locales_to_be_generated locales "${SUPPORTED_LOCALES}"
 db_capb multiselect
 db_input medium locales/locales_to_be_generated || true



Reply to: