[livecd-tools/f14/master] Backport missing parts of the regex patch.

Bruno Wolff III bruno at fedoraproject.org
Tue Sep 14 03:03:35 UTC 2010


commit 898f80298a67fab2bdcba772c49e54f8f090c4e2
Author: Bruno Wolff III <bruno at wolff.to>
Date:   Mon Sep 13 21:58:36 2010 -0500

    Backport missing parts of the regex patch.

 livecd-tools.spec |    7 ++++++-
 regex.patch       |   35 +++++++++++++++++++++++++++++++++++
 2 files changed, 41 insertions(+), 1 deletions(-)
---
diff --git a/livecd-tools.spec b/livecd-tools.spec
index c191701..4b753e2 100644
--- a/livecd-tools.spec
+++ b/livecd-tools.spec
@@ -5,7 +5,7 @@
 Summary: Tools for building live CDs
 Name: livecd-tools
 Version: 034
-Release: 3%{?dist}
+Release: 4%{?dist}
 License: GPLv2
 Group: System Environment/Base
 URL: http://git.fedorahosted.org/git/livecd
@@ -16,6 +16,7 @@ URL: http://git.fedorahosted.org/git/livecd
 # scp livecd*.tar.bz2 fedorahosted.org:livecd
 Source0: http://fedorahosted.org/releases/l/i/livecd/%{name}-%{version}.tar.bz2
 Patch0: vesa.patch
+Patch1: regex.patch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
 Requires: python-imgcreate = %{version}-%{release}
 Requires: mkisofs
@@ -60,6 +61,7 @@ like live image or appliances.
 %prep
 %setup -q
 %patch0 -p1
+%patch1 -p1
 
 %build
 make
@@ -92,6 +94,9 @@ rm -rf $RPM_BUILD_ROOT
 %{python_sitelib}/imgcreate/*.pyc
 
 %changelog
+* Mon Sep 13 2010 Bruno Wolff III <bruno at wolff.to> - 034-4
+- Backport missing parts of the regex fix patch
+
 * Mon Sep 13 2010 Bruno Wolff III <bruno at wolff.to> - 034-3
 - Backported fix for vesa boot menu item
 
diff --git a/regex.patch b/regex.patch
new file mode 100644
index 0000000..c40614e
--- /dev/null
+++ b/regex.patch
@@ -0,0 +1,35 @@
+diff --git a/tools/livecd-iso-to-disk.sh b/tools/livecd-iso-to-disk.sh
+index 6023509..00f201a 100755
+--- a/tools/livecd-iso-to-disk.sh
++++ b/tools/livecd-iso-to-disk.sh
+@@ -70,7 +70,7 @@ getdisk() {
+ }
+ 
+ resetMBR() {
+-    if [[ "$DEV" =~ "/dev/loop*" ]]; then
++    if isdevloop "$DEV"; then
+        return
+     fi
+     getdisk $1
+@@ -129,7 +129,7 @@ checkPartActive() {
+     if [ "$dev" = "$device" ]; then
+ 	return
+     fi
+-    if [[ "$dev" =~ "/dev/loop*" ]]; then
++    if isdevloop "$DEV"; then
+         return
+     fi
+ 
+@@ -189,7 +189,11 @@ createMSDOSLayout() {
+     partinfo=$(LC_ALL=C /sbin/parted --script -m $device "unit b print" |grep ^$device:)
+     size=$(echo $partinfo |cut -d : -f 2 |sed -e 's/B$//')
+     /sbin/parted --script $device unit b mkpart primary fat32 17408 $(($size - 17408)) set 1 boot on
+-    USBDEV=${device}1
++    if ! isdevloop "$DEV"; then
++        USBDEV=${device}1
++    else
++        USBDEV=${device}
++    fi
+     # Sometimes automount can be _really_ annoying.
+     echo "Waiting for devices to settle..."
+     /sbin/udevadm settle


More information about the scm-commits mailing list