livecd-rootfs/live-build/ubuntu-core/hooks/12-add-foreign-libc6.chroot
Oliver Grawert d61ed6ef41 Import patches-unapplied version 2.326 to ubuntu/wily-proposed
Imported using git-ubuntu import.

Changelog parent: 1dc9986ac981d50eddc583b479016b28b7dc515b

New changelog entries:
  * snappy: install libc6:i386 on amd64 images for multiarch support out of
    the box. (LP: #1444049)
2015-07-07 09:53:33 +00:00

22 lines
517 B
Bash

#!/bin/sh
set -ex
echo "I: Checking if we are amd64 and libc6:i386 should be installed"
if [ "$(dpkg --print-architecture)" = "amd64" ]; then
echo "I: Enabling i386 multiarch support on amd64"
dpkg --add-architecture i386
apt-get -y update
echo "I: Installing libc6:i386 in amd64 image"
apt-get -y install libc6:i386
echo "I: Removing /var/lib/apt/lists/*"
find /var/lib/apt/lists/ -type f | xargs rm -f
echo "I: Removing /var/cache/apt/*.bin"
rm -f /var/cache/apt/*.bin
fi