Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- *** setup_sdcard.sh_bak 2014-01-24 14:42:10.000000000 -0800
- --- setup_sdcard.sh 2014-02-16 15:56:51.272797370 -0800
- ***************
- *** 472,478 ****
- echo "-----------------------------"
- LC_ALL=C sfdisk --force --in-order --Linux --unit M "${media}" <<-__EOF__
- ! ${conf_boot_startmb},${conf_boot_endmb},${sfdisk_fstype},*
- ,,,-
- __EOF__
- --- 472,479 ----
- echo "-----------------------------"
- LC_ALL=C sfdisk --force --in-order --Linux --unit M "${media}" <<-__EOF__
- ! ${conf_boot_endmb},${conf_boot_endmb},${sfdisk_fstype},*
- ! ,1000,S
- ,,,-
- __EOF__
- ***************
- *** 499,505 ****
- format_partition_error () {
- echo "LC_ALL=C ${mkfs} ${media_prefix}1 ${mkfs_label}"
- ! echo "LC_ALL=C mkfs.${ROOTFS_TYPE} ${media_prefix}2 ${ROOTFS_LABEL}"
- echo "Failure: formating partition"
- exit
- }
- --- 500,506 ----
- format_partition_error () {
- echo "LC_ALL=C ${mkfs} ${media_prefix}1 ${mkfs_label}"
- ! echo "LC_ALL=C mkfs.${ROOTFS_TYPE} ${media_prefix}3 ${ROOTFS_LABEL}"
- echo "Failure: formating partition"
- exit
- }
- ***************
- *** 514,521 ****
- format_rootfs_partition () {
- echo "Formating rootfs Partition as ${ROOTFS_TYPE}"
- echo "-----------------------------"
- ! LC_ALL=C mkfs.${ROOTFS_TYPE} ${media_prefix}2 -L ${ROOTFS_LABEL} || format_partition_error
- sync
- }
- create_partitions () {
- --- 515,524 ----
- format_rootfs_partition () {
- echo "Formating rootfs Partition as ${ROOTFS_TYPE}"
- echo "-----------------------------"
- ! LC_ALL=C mkfs.${ROOTFS_TYPE} -q ${media_prefix}3 -L ${ROOTFS_LABEL} || format_partition_error
- sync
- +
- + LC_ALL=C mkswap ${media_prefix}2
- }
- create_partitions () {
- ***************
- *** 822,830 ****
- fi
- partprobe ${media}
- ! if ! mount -t ${ROOTFS_TYPE} ${media_prefix}2 ${TEMPDIR}/disk; then
- echo "-----------------------------"
- ! echo "Unable to mount ${media_prefix}2 at ${TEMPDIR}/disk to complete populating rootfs Partition"
- echo "Please retry running the script, sometimes rebooting your system helps."
- echo "-----------------------------"
- exit
- --- 825,833 ----
- fi
- partprobe ${media}
- ! if ! mount -t ${ROOTFS_TYPE} ${media_prefix}3 ${TEMPDIR}/disk; then
- echo "-----------------------------"
- ! echo "Unable to mount ${media_prefix}3 at ${TEMPDIR}/disk to complete populating rootfs Partition"
- echo "Please retry running the script, sometimes rebooting your system helps."
- echo "-----------------------------"
- exit
- ***************
- *** 860,866 ****
- if [ "${BTRFS_FSTAB}" ] ; then
- echo "/dev/mmcblk0p2 / btrfs defaults 0 1" >> ${TEMPDIR}/disk/etc/fstab
- else
- ! echo "/dev/mmcblk0p2 / ${ROOTFS_TYPE} noatime,errors=remount-ro 0 1" >> ${TEMPDIR}/disk/etc/fstab
- fi
- echo "/dev/mmcblk0p1 /boot/uboot auto defaults 0 0" >> ${TEMPDIR}/disk/etc/fstab
- echo "debugfs /sys/kernel/debug debugfs defaults 0 0" >> ${TEMPDIR}/disk/etc/fstab
- --- 863,870 ----
- if [ "${BTRFS_FSTAB}" ] ; then
- echo "/dev/mmcblk0p2 / btrfs defaults 0 1" >> ${TEMPDIR}/disk/etc/fstab
- else
- ! echo "/dev/sda3 / ${ROOTFS_TYPE} errors=remount-ro 0 1" >> ${TEMPDIR}/disk/etc/fstab
- ! echo "/dev/sda2 none swap sw 0 0" >> ${TEMPDIR}/disk/etc/fstab
- fi
- echo "/dev/mmcblk0p1 /boot/uboot auto defaults 0 0" >> ${TEMPDIR}/disk/etc/fstab
- echo "debugfs /sys/kernel/debug debugfs defaults 0 0" >> ${TEMPDIR}/disk/etc/fstab
- ***************
- *** 1020,1026 ****
- echo "Background: usually occured in days before Ubuntu Lucid.."
- echo "-----------------------------"
- ! SPACE_LEFT=$(df ${TEMPDIR}/disk/ | grep ${media_prefix}2 | awk '{print $4}')
- let SIZE=${SWAP_SIZE}*1024
- if [ ${SPACE_LEFT} -ge ${SIZE} ] ; then
- --- 1024,1030 ----
- echo "Background: usually occured in days before Ubuntu Lucid.."
- echo "-----------------------------"
- ! SPACE_LEFT=$(df ${TEMPDIR}/disk/ | grep ${media_prefix}3 | awk '{print $4}')
- let SIZE=${SWAP_SIZE}*1024
- if [ ${SPACE_LEFT} -ge ${SIZE} ] ; then
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement