Bug#179994: Use chroot instead of LD_LIBRARY_PATH and -o...
On Thu, Feb 06, 2003 at 02:21:51PM +0100, Mario Lang wrote:
> tag 179994 + patch
> thanks.
>
> The following patch fixes this problem.
> I'm somewhat hesitent to apply it though, since I didn't
> write the original trickery, and I'm still not sure why
> they didn't use chroot in the first place.
>
> Index: tools/base-installer/debian/postinst
> ===================================================================
> RCS file: /cvs/debian-boot/debian-installer/tools/base-installer/debian/postinst,v
> retrieving revision 1.30
> diff -u -r1.30 postinst
> +++ tools/base-installer/debian/postinst 6 Feb 2003 13:18:48 -0000
> @@ -104,17 +104,6 @@
>
> echo "deb ${PROTOCOL}://${MIRROR}${DIRECTORY} ${DISTRIBUTION} main" > /target/etc/apt/sources.list
>
> - PATH=$PATH:/target/usr/bin:/target/bin:/target/usr/sbin:/target/sbin \
> - LD_LIBRARY_PATH=/target/lib:/target/usr/lib \
> - /target/usr/bin/apt-get \
> - -o Dir::State=/target/var/lib/apt \
> - -o Dir::State::status=/target/var/lib/dpkg/status \
> - -o Dir::Cache=/target/var/cache/apt \
> - -o Dir::Etc=/target/etc/apt \
> - -o Dir::Bin::methods=/target/usr/lib/apt/methods \
> - -o Dir::Bin::gzip=/target/bin/gzip \
> - -o Dir::Bin::dpkg=/target/usr/bin/dpkg \
> - -o Dpkg::Options::=--root=/target \
> - update
> + chroot /target /usr/bin/apt-get update
> fi
> exit 0
Note to whoever fixes this: please update the apt-get invocation
in kernel-installer's postinst as well.
Matt
--
Oink!
Reply to: