From 9b4819f33afea788b3ea8c991392db5d3b11b34f Mon Sep 17 00:00:00 2001 From: Juan RP Date: Wed, 27 May 2015 17:24:48 +0200 Subject: installer: make remote install work with musl live images. --- installer.sh.in | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'installer.sh.in') diff --git a/installer.sh.in b/installer.sh.in index 3942d49..ed2782b 100644 --- a/installer.sh.in +++ b/installer.sh.in @@ -794,12 +794,20 @@ install_packages() { cp -a /usr/share/xbps.d $TARGETDIR/usr/share/ cp /var/db/xbps/keys/*.plist $TARGETDIR/var/db/xbps/keys mkdir -p $TARGETDIR/boot/grub - stdbuf -oL xbps-install -r $TARGETDIR -Sy ${_syspkg} ${_grub} 2>&1 | \ + + _arch=$(xbps-uhelper arch) + + stdbuf -oL env XBPS_ARCH=${_arch} \ + xbps-install -r $TARGETDIR -Sy ${_syspkg} ${_grub} 2>&1 | \ DIALOG --title "Installing base system packages..." \ --programbox 24 80 if [ $? -ne 0 ]; then DIE 1 fi + # If uname -m != _arch perform a reconfiguration. + if [ "$(uname -m)" != "${_arch}" ]; then + XBPS_ARCH=${_arch} xbps-reconfigure -r $TARGETDIR -a + fi } enable_dhcpd() { -- cgit 1.4.1