Package: libselinux1 Version: 2.0.82-1 Severity: normal Tags: patch Hello,
libselinux1 fails to install when init is not launched (it tries to call telinit, which tries to access /dev/initclt)... which happens always with qemubuilder (the build process is directly launched as process #1). A possible solution to fix this is to check whether /proc/1/exe points to /sbin/init, as in the attached patch. I'm not sure this is the right solution, though. By the way, the same error happens with libsepol1, too. Cheers, -- Stéphane -- System Information: Debian Release: squeeze/sid APT prefers testing APT policy: (990, 'testing'), (500, 'unstable'), (500, 'stable'), (1, 'experimental') Architecture: amd64 (x86_64) Kernel: Linux 2.6.30-1-amd64 (SMP w/2 CPU cores) Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Versions of packages libselinux1 depends on: ii libc6 2.9-23 GNU C Library: Shared libraries libselinux1 recommends no packages. libselinux1 suggests no packages. -- no debconf information
--- postinst.orig 2009-09-01 18:04:09.000000000 +0200 +++ postinst 2009-09-01 18:07:10.000000000 +0200 @@ -101,7 +101,7 @@ # Update ld.so cache ldconfig if [ -x /sbin/init ] && [ -x /bin/readlink ] && [ -d /proc/1 ] ; then - if [ "$(stat -c %d/%i /)" = "$(stat -Lc %d/%i /proc/1/root 2>/dev/null)" ]; then + if [ "$(stat -c %d/%i /)" = "$(stat -Lc %d/%i /proc/1/root 2>/dev/null)" ] && [ "$(readlink -f /proc/1/root)" = "/sbin/init" ]; then # the devicenumber/inode pair of / is the same as that of # /sbin/init's root, so we're *not* in a chroot