[Balloon] New features in langupdate for multistrap support

Top Page
Attachments:
Message as email
+ (text/plain)
+ (application/pgp-signature)
Delete this message
Reply to this message
Author: Neil Williams
Date:  
To: Balloonboard.org
CC: Debian Embedded
Subject: [Balloon] New features in langupdate for multistrap support
I've been experimenting with langupdate and I've got a new feature that
could be useful:

# LANG=fr langupdate -a armel --suite stable --prefix=/opt/emdebian/debootstrap/grip

The following NEW packages will be installed:
shadow-locale-fr
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 18.0kB of archives.
After this operation, 102kB of additional disk space will be used.
Get:1 http://www.emdebian.org stable/pt shadow-locale-fr 1:4.1.1-6 [18.0kB]
Fetched 18.0kB in 0s (39.1kB/s)
Download complete and in download only mode
langupdate: Extracting TDeb 'shadow-locale-fr_1%3a4.1.1-6_amd64.deb' into '/opt/emdebian/debootstrap/grip'
langupdate: copying unpacked TDeb to system cache: '/opt/emdebian/debootstrap/grip/var/cache/apt/archives/shadow-locale-pt_1%3a4.1.1-6_amd64.deb'

i.e. this can identify, download and extract TDebs to add specific
translations only for the list of packages currently installed in the
debootstrap (or multistrap) according to the configuration of locales
within that environment - without needing to use chroot, so it can work
across architectures. It could run within the multistrap process using
the existing Makefile. The locales themselves can be pre-seeded using
debconf but langupdate doesn't need the locales to be *configured* to
work, it just needs the LANG environment variable and
$prefix/etc/locale.gen to exist.

LANG="pt:de" allows more than one locale to be added at the same time.

The following NEW packages will be installed:
shadow-locale-de
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 18.2kB of archives.
After this operation, 98.3kB of additional disk space will be used.
Get:1 http://www.emdebian.org stable/de shadow-locale-de 1:4.1.1-6 [18.2kB]
etc.

This should allow Grip multistrap root filesystems to contain all the
localisation support necessary, without needing to run langupdate
itself on the device (because that would require network access).

TBH the extracting is probably best done as an option because we
probably need multistrap to not just extract the .mo files but also
generate the correct dpkg status data and handle the package control
data but it won't hurt to extract with langupdate and then do a proper
unpack with multistrap.

(Extract doesn't list the TDeb in the apt or dpkg status information,
it just puts the contents into the filesystem using a prefix.)

Some more testing and this will get into langupdate 0.1.0 - although I
do need to allow time for the newly added strings to be translated
within langupdate itself (yes, it has it's own TDebs) so the new
release will be in about 2 weeks time.

Note that as this is not currently altering the dpkg status
information, repeated runs of this particular option will cause the
same TDebs to be downloaded and extracted. Once the multistrap support
is added, this issue will go away.

http://buildd.emdebian.org/svn/browser/current/host/trunk/langupdate/trunk/

http://buildd.emdebian.org/svn/log/current/host/trunk/langupdate/trunk/src?rev=5803

--


Neil Williams
=============
http://www.data-freedom.org/
http://www.nosoftwarepatents.com/
http://www.linux.codehelp.co.uk/