From 45820739866327860c1c6ac5d1ccb66db32b1dec Mon Sep 17 00:00:00 2001 From: Michael Prokop Date: Mon, 20 Dec 2010 17:48:35 +0100 Subject: [PATCH] Add patch 19_revert_toram_bootoption_to_expected_behaviour.dpatch. --- debian/patches/00list | 1 + ...t_toram_bootoption_to_expected_behaviour.dpatch | 53 ++++++++++++++++++++++ 2 files changed, 54 insertions(+) create mode 100755 debian/patches/19_revert_toram_bootoption_to_expected_behaviour.dpatch diff --git a/debian/patches/00list b/debian/patches/00list index 2317ab7..170e6dc 100644 --- a/debian/patches/00list +++ b/debian/patches/00list @@ -11,3 +11,4 @@ 16_nodhcp.dpatch 17_fix_usage_of_manual_add_modules.dpatch 18_support_mtdblock_as_device_name.dpatch +19_revert_toram_bootoption_to_expected_behaviour.dpatch diff --git a/debian/patches/19_revert_toram_bootoption_to_expected_behaviour.dpatch b/debian/patches/19_revert_toram_bootoption_to_expected_behaviour.dpatch new file mode 100755 index 0000000..9c53cd6 --- /dev/null +++ b/debian/patches/19_revert_toram_bootoption_to_expected_behaviour.dpatch @@ -0,0 +1,53 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 19_revert_toram_bootoption_to_expected_behaviour.dpatch by Michael Prokop +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Revert toram bootoption to expected behaviour. +## DP: +## DP: In commit 36bb11382c81d5bce4b69f6d3d618dfd1c38dffb +## DP: of live-initramfs-grml (when merging Debian's version 1.157.4-1) +## DP: the behaviour of toram bootoption was modified, see +## DP: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=534878 +## DP: +## DP: On Grml we want to have the option to load the whole medium +## DP: into RAM to e.g. have additional directories like /deb, +## DP: /scripts or whatever. This is possible using the toram bootoption +## DP: without any additional arguments. +## DP: +## DP: If you do NOT want to load the whole medium to RAM just +## DP: boot using toram=grml.squashfs (or whatever it's named, +## DP: there's a ready-to-use bootoption in Grml's bootsplash +## DP: menu available) instead. +## DP: +## DP: Ammusingly the requested behaviour is available in Debian's +## DP: live-boot if rsync is not available, so this patch +## DP: actually just unifies the code paths and reverts the +## DP: behaviour change back to what the log message says. + +@DPATCH@ + +index d79beed..1b6926e 100755 +--- a/scripts/live ++++ b/scripts/live +@@ -484,7 +484,7 @@ copy_live_to () + + if [ -z "${MODULETORAM}" ] + then +- size=$(fs_size "" ${copyfrom}/${LIVE_MEDIA_PATH} "used") ++ size=$(fs_size "" ${copyfrom}/ "used") + else + MODULETORAMFILE="${copyfrom}/${LIVE_MEDIA_PATH}/${MODULETORAM}" + +index d79beed..57d1b41 100755 +--- a/scripts/live ++++ b/scripts/live +@@ -553,8 +553,7 @@ copy_live_to () + echo " * Copying whole medium to RAM" 1>/dev/console + rsync -a --progress ${copyfrom}/* ${copyto} 1>/dev/console # "cp -a" from busybox also copies hidden files + else +- mkdir -p ${copyto}/${LIVE_MEDIA_PATH} +- cp -a ${copyfrom}/${LIVE_MEDIA_PATH}/* ${copyto}/${LIVE_MEDIA_PATH} ++ cp -a ${copyfrom}/* ${copyto}/ + if [ -e ${copyfrom}/${LIVE_MEDIA_PATH}/.disk ] + then + cp -a ${copyfrom}/${LIVE_MEDIA_PATH}/.disk ${copyto} -- 2.1.4