aboutsummaryrefslogtreecommitdiffstats
path: root/create_arm_image.sh
diff options
context:
space:
mode:
authorNeal Gompa <ngompa13@gmail.com>2020-01-12 04:05:01 -0500
committerNeal Gompa <ngompa13@gmail.com>2020-01-12 04:17:25 -0500
commit5b42a8d15b058f95e709b3d2c5564bfcfeed81b7 (patch)
tree09123ff64a6c006a3bb49fc9866fff760b0f8fdf /create_arm_image.sh
parent57d9815a4882677ebdffec0d3d568e00addc34a8 (diff)
downloadmageia4arm-5b42a8d15b058f95e709b3d2c5564bfcfeed81b7.tar
mageia4arm-5b42a8d15b058f95e709b3d2c5564bfcfeed81b7.tar.gz
mageia4arm-5b42a8d15b058f95e709b3d2c5564bfcfeed81b7.tar.bz2
mageia4arm-5b42a8d15b058f95e709b3d2c5564bfcfeed81b7.tar.xz
mageia4arm-5b42a8d15b058f95e709b3d2c5564bfcfeed81b7.zip
Work around issues with filesystem package by preparing chroot skeleton
There are issues with the filesystem package in Mageia that lead to unpredictable setup for the filesystem hierarchy when setting up chroots. In order to work around this problem, let's create some of the basic paths ourselves while we wait for the issue to be fixed. Reference: https://bugs.mageia.org/show_bug.cgi?id=26044
Diffstat (limited to 'create_arm_image.sh')
-rwxr-xr-xcreate_arm_image.sh13
1 files changed, 13 insertions, 0 deletions
diff --git a/create_arm_image.sh b/create_arm_image.sh
index b1d6324..b07e3ea 100755
--- a/create_arm_image.sh
+++ b/create_arm_image.sh
@@ -234,6 +234,19 @@ function installbasesystem()
info "Build path exists"
fi
+ # Workaround mga#26044.
+ info "Preparing root filesystem tree"
+ mkdir -p "${BUILD_PATH}/usr/bin"
+ mkdir -p "${BUILD_PATH}/usr/sbin"
+ mkdir -p "${BUILD_PATH}/usr/lib"
+ ln -sr "${BUILD_PATH}/usr/bin" "${BUILD_PATH}/bin"
+ ln -sr "${BUILD_PATH}/usr/sbin" "${BUILD_PATH}/sbin"
+ ln -sr "${BUILD_PATH}/usr/lib" "${BUILD_PATH}/lib"
+ if [ "${ARM_VERSION}" = "aarch64" ]; then
+ mkdir -p "${BUILD_PATH}/usr/lib64"
+ ln -sr "${BUILD_PATH}/usr/lib64" "${BUILD_PATH}/lib64"
+ fi
+
title "installing basesystem"
/usr/bin/dnf --installroot="${BUILD_PATH}" ${DNF_MIRROROPTS} --assumeyes install shadow-utils basesystem-minimal
if [ ${?} -ne 0 ]; then