From 43cbe6481aba99323f20f7d505e351cce004aaa4 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 1 Jan 1970 00:00:00 +0000 Subject: [PATCH] Fix registration bug and endianness issues. --- libvirt/mingw32-libvirt-0.4.6-debug-registration.patch | 12 ++++++++++++ libvirt/mingw32-libvirt-0.4.6-register-remote.patch | 14 ++++++++++++++ libvirt/mingw32-libvirt.spec | 15 +++++++++++++-- 3 files changed, 39 insertions(+), 2 deletions(-) create mode 100644 libvirt/mingw32-libvirt-0.4.6-debug-registration.patch create mode 100644 libvirt/mingw32-libvirt-0.4.6-register-remote.patch diff --git a/libvirt/mingw32-libvirt-0.4.6-debug-registration.patch b/libvirt/mingw32-libvirt-0.4.6-debug-registration.patch new file mode 100644 index 0000000..180f195 --- /dev/null +++ b/libvirt/mingw32-libvirt-0.4.6-debug-registration.patch @@ -0,0 +1,12 @@ +--- libvirt-0.4.6/src/libvirt.c.orig 2008-09-22 14:12:12.000000000 +0100 ++++ libvirt-0.4.6/src/libvirt.c 2008-10-14 15:30:56.000000000 +0100 +@@ -540,6 +540,9 @@ + return -1; + } + ++ DEBUG ("registering %s as driver %d", ++ driver->name, virDriverTabCount); ++ + virDriverTab[virDriverTabCount] = driver; + return virDriverTabCount++; + } diff --git a/libvirt/mingw32-libvirt-0.4.6-register-remote.patch b/libvirt/mingw32-libvirt-0.4.6-register-remote.patch new file mode 100644 index 0000000..4d0d77d --- /dev/null +++ b/libvirt/mingw32-libvirt-0.4.6-register-remote.patch @@ -0,0 +1,14 @@ +--- libvirt-0.4.6/src/libvirt.c.orig 2008-10-14 15:33:00.000000000 +0100 ++++ libvirt-0.4.6/src/libvirt.c 2008-10-14 15:48:54.000000000 +0100 +@@ -297,10 +297,10 @@ + if (lxcRegister() == -1) return -1; + #endif + if (storageRegister() == -1) return -1; ++#endif + #ifdef WITH_REMOTE + if (remoteRegister () == -1) return -1; + #endif +-#endif + + return(0); + } diff --git a/libvirt/mingw32-libvirt.spec b/libvirt/mingw32-libvirt.spec index 02719da..78c353e 100644 --- a/libvirt/mingw32-libvirt.spec +++ b/libvirt/mingw32-libvirt.spec @@ -6,7 +6,7 @@ Name: mingw32-libvirt Version: 0.4.6 -Release: 4%{?dist}%{?extra_release} +Release: 6%{?dist}%{?extra_release} Summary: MinGW Windows libvirt virtualization library License: LGPLv2+ @@ -15,6 +15,9 @@ URL: http://libvirt.org/ Source0: ftp://libvirt.org/libvirt/libvirt-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +Patch0: mingw32-libvirt-0.4.6-debug-registration.patch +Patch1: mingw32-libvirt-0.4.6-register-remote.patch + BuildRequires: mingw32-filesystem >= 23 BuildRequires: mingw32-gcc BuildRequires: mingw32-binutils @@ -23,7 +26,8 @@ BuildRequires: mingw32-libgcrypt BuildRequires: mingw32-gnutls BuildRequires: mingw32-gettext BuildRequires: mingw32-libxml2 -BuildRequires: mingw32-portablexdr +# Portable XDR <= 4.0.10 contains a serious endianness bug on Windows. +BuildRequires: mingw32-portablexdr >= 4.0.11 BuildRequires: mingw32-readline BuildRequires: pkgconfig # Need native version for msgfmt @@ -38,6 +42,8 @@ MinGW Windows libvirt virtualization library. %prep %setup -q -n libvirt-%{version} +%patch0 -p1 +%patch1 -p1 %build @@ -90,6 +96,11 @@ rm -rf $RPM_BUILD_ROOT %changelog +* Wed Oct 15 2008 Richard Jones - 0.4.6-6 +- Add patches from + https://www.redhat.com/archives/libvir-list/2008-October/msg00328.html +- BR mingw32-portablexdr >= 4.0.11 to fix serious Windows endianness bug. + * Tue Oct 14 2008 Richard Jones - 0.4.6-4 - +BR mingw32-readline. -- 1.8.3.1