1 # Contributor: Daniel Golle <daniel.golle@gmail.com>
2 # AUR Category: emulators
4 # original PKGBUILD by Bernhard Walle <bernhard.walle@gmx.de>
5 # patches taken from OpenSuSE kvm-84 package
10 pkgdesc="KVM Userspace Package"
12 url="http://kvm.qumranet.com"
16 makedepends=( dev86 iasl )
18 conflicts=( kvm kvm-git qemu )
22 install=('kvm-opensuse.install')
23 source=('http://dl.sourceforge.net/sourceforge/kvm/kvm-84.tar.gz'
24 'http://ovh.dl.sourceforge.net/sourceforge/kvm/NETKVM-20081229.iso'
25 'kvm-opensuse.install'
27 'kvm-fix-with-evdev.patch'
29 'kvm-qemu-default-memsize.patch'
30 'kvm-qemu-no-fallback-if-open-kvm-fails.patch'
32 'kvm-qemu-applesmc.patch'
33 'kvm-qemu-ide-ich6.patch'
34 'kvm-qemu-macmodel.patch'
35 'kvm-qemu-rtl8139-link.patch'
36 'kvm-qemu-multiboot.patch'
37 'kvm-kernel-cpuid4.patch'
38 'kvm-kernel-msr.patch'
42 'kvm-preXX-init-on-demand.patch'
43 'kvm-preXX-altgr-and-dead-keys-with-VNC.patch' )
48 md5sums=( 'a3bf65b31e70b7f214b8de4e39f8adee'
49 '39b7206ef400845800f081a5b901f757' )
52 cd "${srcdir}/kvm-${pkgver}"
53 # patch -p1 -i $startdir/qemu-datadir.diff
54 patch -p1 -i $startdir/kvm-qemu-default-memsize.patch
55 patch -p1 -i $startdir/kvm-qemu-no-fallback-if-open-kvm-fails.patch
58 patch -p1 -i $startdir/kvm-qemu-lpc.patch
59 patch -p1 -i $startdir/kvm-qemu-applesmc.patch
60 patch -p1 -i $startdir/kvm-qemu-ide-ich6.patch
61 patch -p1 -i $startdir/kvm-qemu-macmodel.patch
62 patch -p1 -i $startdir/kvm-qemu-rtl8139-link.patch
63 patch -p1 -i $startdir/kvm-qemu-multiboot.patch
64 patch -p1 -i $startdir/kvm-kernel-cpuid4.patch
65 patch -p1 -i $startdir/kvm-kernel-msr.patch
66 patch -p1 -i $startdir/kvm-maccpuid.patch
67 patch -p1 -i $startdir/kvm-ioapic.patch
68 patch -p1 -i $startdir/kvm-bios.patch
69 # Post-release upstream patches
70 patch -p1 -i $startdir/kvm-preXX-init-on-demand.patch
71 patch -p1 -i $startdir/kvm-preXX-altgr-and-dead-keys-with-VNC.patch
73 #patch -p1 -i $startdir/ia64-fix-pagesize.pl
74 #patch -p1 -i $startdir/IA64-kvm-suse.patch
75 # archlinux supplied patch
76 patch -p1 -i $startdir/kvm-fix-with-evdev.patch
82 ./configure --prefix=/usr --audio-drv-list=oss,alsa,pa --with-patched-kernel --audio-card-list="ac97 adlib cs4231a gus" \
85 make -C bios-mac || return 1
86 make DESTDIR="${pkgdir}/" install
87 cp bios-mac/BIOS-bochs-latest "${pkgdir}/usr/share/qemu/bios-mac.bin"
88 cp ${srcdir}/NETKVM-20081229.iso "${pkgdir}/usr/share/qemu/"
89 rm -fr $pkgdir/usr/include/linux/
94 mkdir -p $pkgdir/etc/udev/rules.d
95 cp $startdir/65-kvm.rules $pkgdir/etc/udev/rules.d