#!/bin/sh set -e . /usr/share/debconf/confmodule file="$1" # Reset existing file, without retaining existing entries as comments (#1029922): >$file # start out with old configuration, if any if [ -e $ROOT/etc/apt/apt.conf ]; then cp -a $ROOT/etc/apt/apt.conf $ROOT/etc/apt/apt.conf.new else >$ROOT/etc/apt/apt.conf.new fi chroot= if [ "$ROOT" ]; then chroot=chroot fi db_get apt-setup/multiarch if [ "$RET" ]; then for arch in $RET; do $chroot $ROOT dpkg --add-architecture "$arch" done else for arch in $($chroot $ROOT dpkg --print-foreign-architectures); do $chroot $ROOT dpkg --remove-architecture "$arch" done fi