From e8b1fd0fdbe6f50168979901b4f443d339ddc794 Mon Sep 17 00:00:00 2001 From: Guillem Jover Date: Mon, 15 Apr 2019 18:45:50 +0200 Subject: [PATCH] TT#56903 Remove apt's auxfiles directory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit apt > 1.6 started creating this directory, but older apt versions do not know how to clean it up. When using a newer host apt than the one that will be used in the chroot, the chroot apt will be unable to remove it properly, and will emit a warning. mmdebstrap was supposedly fixed in version 0.4.0-1, but the code was inserted before further «apt-get update» calls, so the directory gets regenerated. We workaround this here for now, after having run grml-debootstrap which might be calling mmdebstrap depending on the release. Change-Id: I13ad1b7ecc9f60414ab7e9222bada10d09baa2ab --- templates/scripts/includes/deployment.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/templates/scripts/includes/deployment.sh b/templates/scripts/includes/deployment.sh index e8d613e..6489fa8 100755 --- a/templates/scripts/includes/deployment.sh +++ b/templates/scripts/includes/deployment.sh @@ -1489,6 +1489,12 @@ if [ -n "${FALLBACK_FS}" ] ; then mkdir -p "${TARGET}/ngcp-fallback" fi +# TT#56903: mmdebstrap 0.4.1-2 does not properly remove this dir. +if [ -d "${TARGET}/var/lib/apt/lists/auxfiles" ]; then + echo "Removing apt's > 1.6 auxfiles directory" + rmdir "${TARGET}/var/lib/apt/lists/auxfiles" +fi + # MT#7805 if "$NGCP_INSTALLER" ; then cat << EOT | augtool --root="$TARGET"