diff options
Diffstat (limited to 'community/libvirt')
-rw-r--r-- | community/libvirt/PKGBUILD | 12 | ||||
-rw-r--r-- | community/libvirt/libvirt.install | 27 | ||||
-rw-r--r-- | community/libvirt/python.patch | 22 |
3 files changed, 34 insertions, 27 deletions
diff --git a/community/libvirt/PKGBUILD b/community/libvirt/PKGBUILD index 6b1d869bf..baa038c17 100644 --- a/community/libvirt/PKGBUILD +++ b/community/libvirt/PKGBUILD @@ -1,10 +1,10 @@ -# $Id: PKGBUILD 83366 2013-01-30 13:07:27Z spupykin $ +# $Id: PKGBUILD 83408 2013-01-31 16:11:20Z spupykin $ # Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com> # Contributor: Jonathan Wiersma <archaur at jonw dot org> pkgname=libvirt pkgver=1.0.2 -pkgrel=1 +pkgrel=2 pkgdesc="API for controlling virtualization engines (openvz,kvm,qemu,virtualbox,xen,etc)" arch=('i686' 'x86_64') url="http://libvirt.org/" @@ -34,13 +34,15 @@ source=("http://libvirt.org/sources/$pkgname-$pkgver.tar.gz" libvirtd.conf.d libvirtd-guests.rc.d libvirtd-guests.conf.d - libvirt.tmpfiles.d) + libvirt.tmpfiles.d + python.patch) md5sums=('7e268ed702c4331d393e5b43449cae13' 'c43244c40a0437038c82089618e7beaa' '3ed0e24f5b5e25bf553f5427d64915e6' '0ee5b6c58590ff392a266f20f7928d1f' '0a96ed876ffb1fcb9dff5a9b3a609c1e' - '020971887442ebbf1b6949e031c8dd3f') + '020971887442ebbf1b6949e031c8dd3f' + '4280310abbdebbb7ad756840e4ff5671') build() { cd "$srcdir/$pkgname-$pkgver" @@ -52,6 +54,8 @@ build() { sed -i 's_#!.*/usr/bin/env.*python_#!/usr/bin/env python2_' $file done + patch -p1 <$srcdir/python.patch + export LDFLAGS=-lX11 export RADVD=/usr/sbin/radvd [ -f Makefile ] || ./configure --prefix=/usr --libexec=/usr/lib/"$pkgname" \ diff --git a/community/libvirt/libvirt.install b/community/libvirt/libvirt.install index 32c28d559..efb652a88 100644 --- a/community/libvirt/libvirt.install +++ b/community/libvirt/libvirt.install @@ -1,38 +1,19 @@ _libvirt_setup() { systemd-tmpfiles --create libvirt.conf - rm -f /usr/lib/python?.?/site-packages/libvirt.pyc - echo ">>> To use libvirt as a non-root user:" - echo ">>> Use polkit to grant access." - echo ">>> ...or change the access model in /etc/libvirt/libvirtd.conf." - echo ">>> (see unixperms.patch in PKGBUILD for help)" - echo "" } post_install() { _libvirt_setup || return 1 - echo ">>> Be sure to see optdepends as you may find some of them helpfull." - echo ">>> Especially: bridge-utils, dnsmasq, and hal." - echo "" - echo ">>> To start libvirtd run: '/etc/rc.d/libvirtd start' as root." - echo ">>> Add 'libvirtd' to daemons in /etc/rc.conf if you want it to load upon" - echo ">>> booting." - echo "" + echo ">>> See https://wiki.archlinux.org/index.php/Libvirt for more info" } post_upgrade() { _libvirt_setup || return 1 - echo ">>> To finish the upgrade, restart libvirtd by:" - echo ">>> 'systemctl restart libvirtd' as root (systemd) or" - echo ">>> '/etc/rc.d/libvirtd restart' as root (initscripts) or" - echo ">>> rebooting." - echo ">>> You may also need to run 'rm -rf ~/.libvirt'" - echo "" + echo ">>> You may need to run 'rm -rf ~/.libvirt'" + echo ">>> libvirt runs qemu from nobody:nobody by default" + echo ">>> change it in /etc/libvirt/qemu.conf" } post_remove() { rm -f /usr/lib/python[0-9].[0-9]/site-packages/libvirt.pyc - echo ">>> You may wish to delete the group 'libvirt' if it still exists." - echo ">>> It can be removed by running 'groupdel libvirt' as root." - echo "" - depmod -a } diff --git a/community/libvirt/python.patch b/community/libvirt/python.patch new file mode 100644 index 000000000..c791a54e9 --- /dev/null +++ b/community/libvirt/python.patch @@ -0,0 +1,22 @@ +diff --git a/python/generator.py b/python/generator.py +index 5d27f66..71ca883 100755 +--- a/python/generator.py ++++ b/python/generator.py +@@ -123,7 +123,7 @@ class docParser(xml.sax.handler.ContentHandler): + self.function_return_field = attrs['field'] + elif tag == 'enum': + if (attrs['file'] == "libvirt" or +- attrs['file'] == "virterror"): ++ attrs['file'] == "virerror"): + enum(attrs['type'],attrs['name'],attrs['value']) + elif attrs['file'] == "libvirt-lxc": + lxc_enum(attrs['type'],attrs['name'],attrs['value']) +@@ -137,7 +137,7 @@ class docParser(xml.sax.handler.ContentHandler): + if self.function != None: + if (self.function_module == "libvirt" or + self.function_module == "virevent" or +- self.function_module == "virterror"): ++ self.function_module == "virerror"): + function(self.function, self.function_descr, + self.function_return, self.function_args, + self.function_file, self.function_module, |