[packages/vdfuse] - up to 0.83 (epoch incremented) - VirtualBox includes up to 5.1.18 - patch for EBR signature proble

adwol adwol at pld-linux.org
Tue Mar 28 13:44:13 CEST 2017


commit 50a917ad6cea1b6542beba924bdd788e6b104a36
Author: Adam Osuchowski <adwol at pld-linux.org>
Date:   Tue Mar 28 13:41:46 2017 +0200

    - up to 0.83 (epoch incremented)
    - VirtualBox includes up to 5.1.18
    - patch for EBR signature problem

 vdfuse-ebr.patch | 20 ++++++++++++++++++++
 vdfuse.spec      | 25 +++++++++++++++----------
 2 files changed, 35 insertions(+), 10 deletions(-)
---
diff --git a/vdfuse.spec b/vdfuse.spec
index 95ae589..fb54060 100644
--- a/vdfuse.spec
+++ b/vdfuse.spec
@@ -1,17 +1,20 @@
 # TODO
 # - split VirtualBox spec to -libs and -devel so this package could be built
-%define		virtualbox_version 4.1.8
+%define		virtualbox_version 5.1.18
 Summary:	A FUSE module for mounting VirtualBox disk images (VDI/VMDK/VHD) on the host
 Name:		vdfuse
-Version:	8.2a
+Version:	0.83
 Release:	1
+Epoch:		2
 License:	GPL v3
 Group:		Base/Kernel
 URL:		http://forums.virtualbox.org/viewtopic.php?f=7&t=17574
 Source0:	VirtualBox-%{virtualbox_version}-include-only.tar.bz2
-# Source0-md5:	2444d8604cc628ff2b2fa17adf0d3e58
-Source1:	%{name}-v82a.c
-# Source1-md5:	0450afd90bf7157a4a3057431f635108
+# Source0-md5:	a47cca26712ba293567f55c6b0a9683b
+Source1:	%{name}-%{version}.c
+# Source1-md5:	9185cc68b7b5227694e295d814b77d36
+# https://bugs.launchpad.net/ubuntu/+source/virtualbox-ose/+bug/759988
+Patch0:		%{name}-ebr.patch
 BuildRequires:	VirtualBox
 BuildRequires:	libfuse-devel
 BuildRequires:	pkgconfig
@@ -27,18 +30,20 @@ readonly and the partitions themselves can only be mounted readonly.
 NB: you will need to add "user_allow_other" to /etc/fuse.conf
 
 %prep
-%setup -q -n VirtualBox-%{virtualbox_version}_OSE
+%setup -q -n VirtualBox-%{virtualbox_version}
+%{__cp} %{SOURCE1} .
+%patch0 -p0
 
 %build
 export LD_LIBRARY_PATH=%{_libdir}/VirtualBox
 FUSE_CFLAGS=$(pkg-config --cflags --libs fuse)
-%{__cc} %{SOURCE1} -o %{name} \
+%{__cc} %{name}-%{version}.c -o %{name} \
 	$FUSE_CFLAGS \
 	-I./include \
 	-Wl,-rpath,%{_libdir}/VirtualBox \
-	-l:%{_libdir}/VirtualBox/VBoxDD.so \
-	-l:%{_libdir}/VirtualBox/VBoxDD2.so \
-	-l:%{_libdir}/VirtualBox/VBoxDDU.so \
+	%{_libdir}/VirtualBox/VBoxDD.so \
+	%{_libdir}/VirtualBox/VBoxDD2.so \
+	%{_libdir}/VirtualBox/VBoxDDU.so \
 	-Wall %{rpmcflags}
 
 %install
diff --git a/vdfuse-ebr.patch b/vdfuse-ebr.patch
new file mode 100644
index 0000000..31c4569
--- /dev/null
+++ b/vdfuse-ebr.patch
@@ -0,0 +1,20 @@
+--- vdfuse-0.83.c.orig	2017-03-28 13:02:17.156773628 +0200
++++ vdfuse-0.83.c	2017-03-28 13:29:07.636623796 +0200
+@@ -491,7 +491,7 @@
+ 			lastPartition++;
+ 			Partition *p = partitionTable + i;
+ 
+-			DISKread (uStart + uOffset + EBR_START, &ebr, sizeof (ebr));
++			DISKread (uStart + uOffset, &ebr, sizeof (ebr));
+ 
+ 			if (ebr.signature != 0xaa55)
+ 				usageAndExit ("Invalid EBR signature found on image");
+@@ -512,7 +512,7 @@
+ 				break;
+ 			if (!PARTTYPE_IS_EXTENDED (ebr.chain.type))
+ 				usageAndExit ("Logical partition chain broken");
+-			uOffset = (ebr.chain).offset;
++			uOffset = (off_t)((ebr.chain).offset) * BLOCKSIZE;
+ 		}
+ 	}
+ //
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/vdfuse.git/commitdiff/50a917ad6cea1b6542beba924bdd788e6b104a36



More information about the pld-cvs-commit mailing list