[xen] add a patch to remove a dependency on PyXML and Require python-lxml instead of PyXML (#842843)

myoung myoung at fedoraproject.org
Tue Jul 24 20:57:33 UTC 2012


commit b1e5b4aded8c4d96b556ddf9be444a21d414bd89
Author: Michael Young <m.a.young at durham.ac.uk>
Date:   Tue Jul 24 21:56:37 2012 +0100

    add a patch to remove a dependency on PyXML and Require python-lxml
    instead of PyXML (#842843)

 xen-no-pyxml.patch |   13 +++++++++++++
 xen.spec           |   10 ++++++++--
 2 files changed, 21 insertions(+), 2 deletions(-)
---
diff --git a/xen-no-pyxml.patch b/xen-no-pyxml.patch
new file mode 100644
index 0000000..276994b
--- /dev/null
+++ b/xen-no-pyxml.patch
@@ -0,0 +1,13 @@
+diff -up xen-4.1.2/tools/python/xen/xm/create.py.bak xen-4.1.2/tools/python/xen/xm/create.py
+--- xen-4.1.2/tools/python/xen/xm/create.py.bak	2012-07-24 10:23:05.096849992 -0700
++++ xen-4.1.2/tools/python/xen/xm/create.py	2012-07-24 10:23:34.453610629 -0700
+@@ -1538,8 +1538,7 @@ def main(argv):
+             SXPPrettyPrint.prettyprint(config)
+ 
+         if opts.vals.xmldryrun and serverType == SERVER_XEN_API:
+-            from xml.dom.ext import PrettyPrint as XMLPrettyPrint
+-            XMLPrettyPrint(doc)
++            print doc.toprettyxml()
+ 
+     if opts.vals.dryrun or opts.vals.xmldryrun:
+         return                                               
diff --git a/xen.spec b/xen.spec
index 36ff265..0536ba7 100644
--- a/xen.spec
+++ b/xen.spec
@@ -20,7 +20,7 @@
 Summary: Xen is a virtual machine monitor
 Name:    xen
 Version: 4.1.2
-Release: 22%{?dist}
+Release: 23%{?dist}
 Group:   Development/Libraries
 License: GPLv2+ and LGPLv2+ and BSD
 URL:     http://xen.org/
@@ -79,6 +79,7 @@ Patch41: xen-4.1-testing.23297.patch
 Patch42: CVE-2012-0217.patch
 Patch43: CVE-2012-0218.patch
 Patch44: CVE-2012-2934.patch
+Patch45: xen-no-pyxml.patch
 
 Patch50: upstream-23936:cdb34816a40a-rework
 Patch51: upstream-23937:5173834e8476
@@ -116,7 +117,7 @@ BuildRequires: bzip2-devel xz-devel
 # libfsimage
 BuildRequires: e2fsprogs-devel
 Requires: bridge-utils
-Requires: PyXML
+Requires: python-lxml
 Requires: udev >= 059
 Requires: xen-runtime = %{version}-%{release}
 # Not strictly a dependency, but kpartx is by far the most useful tool right
@@ -249,6 +250,7 @@ manage Xen virtual machines.
 %patch42 -p1
 %patch43 -p1
 %patch44 -p1
+%patch45 -p1
 
 %patch50 -p1
 %patch51 -p1
@@ -713,6 +715,10 @@ rm -rf %{buildroot}
 %endif
 
 %changelog
+* Tue Jul 24 2012 Michael Young <m.a.young at durham.ac.uk> - 4.1.2-23
+- add a patch to remove a dependency on PyXML and Require python-lxml
+  instead of PyXML (#842843)
+
 * Sun Jul 22 2012 Michael Young <m.a.young at durham.ac.uk> - 4.1.2-22
 - adjust systemd service files not to report failures when running without
   a hypervisor or when xendomains.service doesn't find anything to start


More information about the scm-commits mailing list