summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Baumann <daniel@debian.org>2012-07-31 19:30:59 +0200
committerDaniel Baumann <daniel@debian.org>2012-07-31 19:30:59 +0200
commit281e42d267ca9109e5c39bc0f451739d8765caa4 (patch)
tree8d69725b7732081a321e9811cfd38615bc1bf3b6
parentb2eb7a885bb935dac09a3ad1ccad0fcf89fdb70e (diff)
downloadvyos-live-build-281e42d267ca9109e5c39bc0f451739d8765caa4.tar.gz
vyos-live-build-281e42d267ca9109e5c39bc0f451739d8765caa4.zip
Concentrating all parted calls within lb_binary_hdd into one place in order to make things simpler.
-rwxr-xr-xscripts/build/lb_binary_hdd21
1 files changed, 4 insertions, 17 deletions
diff --git a/scripts/build/lb_binary_hdd b/scripts/build/lb_binary_hdd
index 21690bdfb..b924e2f76 100755
--- a/scripts/build/lb_binary_hdd
+++ b/scripts/build/lb_binary_hdd
@@ -176,6 +176,8 @@ case "${LB_BUILD_WITH_CHROOT}" in
true)
Chroot chroot "parted -s ${FREELO} mklabel ${PARTITION_TABLE_TYPE}" || true
Chroot chroot "parted -s ${FREELO} mkpart primary ${PARTITION_TYPE} 0.0 100%" || true
+ Chroot chroot "parted -s ${FREELO} set 1 boot on" || true
+ Chroot chroot "parted -s ${FREELO} set 1 lba off" || true
if [ "${LB_BOOTLOADER}" = "syslinux" ]
then
@@ -186,6 +188,8 @@ case "${LB_BUILD_WITH_CHROOT}" in
false)
parted -s ${FREELO} mklabel ${PARTITION_TABLE_TYPE} || true
parted -s ${FREELO} mkpart primary ${PARTITION_TYPE} 0.0 100% || true
+ parted -s "${FREELO}" set 1 boot on || true
+ parted -s "${FREELO}" set 1 lba off || true
if [ "${LB_BOOTLOADER}" = "syslinux" ]
then
@@ -292,23 +296,6 @@ Lodetach ${FREELO}
echo "!!! The above error/warning messages can be ignored !!!"
-FREELO="$(${LB_LOSETUP} -f)"
-Losetup "${FREELO}" chroot/binary.img 0
-
-case "${LB_BUILD_WITH_CHROOT}" in
- true)
- Chroot chroot "parted -s ${FREELO} set 1 boot on" || true
- Chroot chroot "parted -s ${FREELO} set 1 lba off" || true
- ;;
-
- false)
- parted -s "${FREELO}" set 1 boot on || true
- parted -s "${FREELO}" set 1 lba off || true
- ;;
-esac
-
-Lodetach ${FREELO}
-
if [ -n "${MAKEDEV}" ]
then
rm -rf chroot/dev