1 # Thanks to falktx for the QtSixa and Sixad utility.
5 pkgdesc="An utility to configure and use sixaxis controller via bluetooth."
6 url="http://sourceforge.net/projects/qtsixa/"
7 arch=('i686' 'x86_64' 'ppc')
9 backup=('etc/default/sixad')
10 depends=('bluez' 'python2-qt' 'qt' 'python2' 'bluez-hcidump' 'jack')
12 source=(http://downloads.sourceforge.net/qtsixa/QtSixA-"$pkgver"-src.tar.gz
15 md5sums=('d61bef5d737367aeddd57a6bc11da52a'
16 'a8c7585f628ac5b2eafeb735e3eab28b'
17 '0496d5e8c16b4519042bd024ad07b32d')
19 # patch for sixad daemon
20 echo "Patching sixad..."
21 patch -p0 < $srcdir/sixad-init.patch
22 patch -p0 < $srcdir/sixad-bin.patch
24 cd $srcdir/QtSixA-$pkgver/qtsixa/gui/
25 echo "Fixed python version..."
26 find . -name "*.py" -exec sed -i "s/python/python2/g" '{}' \;
27 sed -i 's/python/python2/g' ../qtsixa
28 sed -i 's/python/python2/g' ../../sixad/sixad-dbus-blocker
29 echo "Fixed bluetooth daemon"
30 sed -i 's/init.d/rc.d/g' qtsixa_main.py
32 cd $srcdir/QtSixA-$pkgver
36 ## Qtsixa installation, adapted from makefile of qtsixa folder ##
40 $pkgdir/usr/share/applications/ \
41 $pkgdir/usr/share/pixmaps/ \
42 $pkgdir/usr/share/qtsixa/ \
43 $pkgdir/usr/share/qtsixa/game-profiles/ \
44 $pkgdir/usr/share/qtsixa/gui/ \
45 $pkgdir/usr/share/qtsixa/icons/ \
46 $pkgdir/usr/share/qtsixa/pics/ \
47 $pkgdir/usr/share/qtsixa/profiles
48 # $pkgdir/usr/share/doc/qtsixa/manual
49 # $pkgdir/usr/share/qtsixa/lang/ \
50 # $pkgdir/usr/share/doc/qtsixa/ \
55 install -m 655 qtsixa $pkgdir/usr/bin/
56 install -m 655 sixad-lq $pkgdir/usr/bin/
57 install -m 655 sixad-notify $pkgdir/usr/bin/
58 # install -m 644 manual/* $pkgdir/usr/share/doc/qtsixa/manual/
59 install -m 644 game-profiles/* $pkgdir/usr/share/qtsixa/game-profiles/
60 install -m 644 gui/*.py $pkgdir/usr/share/qtsixa/gui/
61 install -m 644 icons/* $pkgdir/usr/share/qtsixa/icons/
62 install -m 644 pics/* $pkgdir/usr/share/qtsixa/pics/
63 install -m 644 profiles/* $pkgdir/usr/share/qtsixa/profiles/
64 # install -m 644 lang/* $pkgdir/usr/share/qtsixa/lang/
65 install -m 644 sixad-notify.desktop $pkgdir/usr/share/qtsixa/
66 install -m 644 qtsixa.desktop $pkgdir/usr/share/applications/
67 install -m 644 qtsixa.xpm $pkgdir/usr/share/pixmaps/
69 ## Sixad installation, adapted from makefile of sixad folder ##
73 $pkgdir/etc/default/ \
75 $pkgdir/etc/logrotate.d/ \
77 $pkgdir/var/lib/sixad/ \
78 $pkgdir/var/lib/sixad/profiles/
83 install -m 644 sixad.default $pkgdir/etc/default/sixad
84 install -m 755 sixad.init $pkgdir/etc/rc.d/sixad
85 install -m 644 sixad.log $pkgdir/etc/logrotate.d/sixad
86 install -m 755 sixad $pkgdir/usr/bin/
87 install -m 755 bins/sixad-bin $pkgdir/usr/sbin/
88 install -m 755 bins/sixad-sixaxis $pkgdir/usr/sbin/
89 install -m 755 bins/sixad-remote $pkgdir/usr/sbin/
90 install -m 755 bins/sixad-3in1 $pkgdir/usr/sbin/
91 install -m 755 bins/sixad-raw $pkgdir/usr/sbin/
92 install -m 755 sixad-dbus-blocker $pkgdir/usr/sbin/
93 #chmod 777 -R $pkgdir/var/lib/sixad/
95 ## Utils installation, adapted from makefile of utils folder ##
99 install -m 755 bins/sixpair $pkgdir/usr/sbin/
100 install -m 755 bins/sixpair-kbd $pkgdir/usr/sbin/
101 install -m 755 bins/hidraw-dump $pkgdir/usr/sbin/
102 install -m 755 bins/sixad-jack $pkgdir/usr/bin/