Bug#453326: locales-all: postinst script does not respect TMPDIR
Package: locales-all
Version: 2.7-2
Severity: important
Tags: patch
Hi,
I have a very small /tmp partition. Without the patch, locales-all
cannot be installed on my system. Please the find patch below.
--- locales-all.postinst.orig 2007-11-29 00:06:35.000000000 +0600
+++ locales-all.postinst 2007-11-29 00:33:48.000000000 +0600
@@ -7,7 +7,7 @@
# Remove existing locales, otherwise localedef does not
# overwrite them and exits with a non-null value
rm -f /usr/lib/locale/locale-archive 2>/dev/null || true
- tmpdir=$(mktemp -d /tmp/locales.XXXXXXXXXX)
+ tmpdir=$(mktemp -d ${TMPDIR:-/tmp}/locales.XXXXXXXXXX)
trap 'rm -rf "$tmpdir" > /dev/null 2>&1' exit
tar --use-compress-program /usr/bin/lzma -xf
/usr/lib/locales-all/supported.tar.lzma -C "$tmpdir"
localedef --quiet --add-to-archive "$tmpdir"/*
-- System Information:
Debian Release: lenny/sid
APT prefers unstable
APT policy: (500, 'unstable'), (500, 'testing'), (500, 'stable'), (1, 'experimental')
Architecture: i386 (i686)
Kernel: Linux 2.6.23.1-toi (SMP w/1 CPU core)
Locale: LANG=ru_RU.UTF-8, LC_CTYPE=ru_RU.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages locales-all depends on:
ii libc6 [glibc-2.7-1] 2.7-2 GNU C Library: Shared libraries
ii lzma 4.43-9 Default and general compression me
locales-all recommends no packages.
-- no debconf information
Reply to: