updated on Thu Jan 19 12:17:07 UTC 2012
[aur-mirror.git] / eee-control / PKGBUILD
blob535ab646f7e961a0e44917995a7535c30de08316
1 # Maintainer: Stunts <f.pinamartins@gmail.com>
2 # Contributor: dieghen89 <dieghen89@gmail.com>
4 pkgname=eee-control
5 pkgver=0.9.7.2
6 pkgrel=2
7 pkgdesc="A utility for the EeePC family which allows the user to modify the FSB, toggle hardware on and off and more."
8 arch=('i686' 'x86_64')
9 url="http://launchpad.net/eee-control/"
10 license=('BSDL')
11 backup=('etc/eee-control.conf')
12 depends=('python2' 'dbus-python' 'gconf' 'python-wnck' 'pygtk' 'python-notify' 'acpid' 'consolekit' 'python2-gconf')
13 makedepends=('bzr')
15 source=(eee-control-daemon.rc
16         eee-control-daemon.conf.diff
17         eee-control-daemon.diff)
19 _bzrtrunk="lp:eee-control"
20 _bzrmod="eee-control"
22 build() {
23   echo $startdir
24   cd "${srcdir}"
26   msg "Connecting to the server...."
28   if [ -d ${_bzrmod} ]; then
29     bzr up ${_bzrmod}
30     msg "The local files are updated."
31   else
32     bzr co ${_bzrtrunk} ${_bzrmod}
33   fi
35   msg "BZR checkout done or server timeout"
36   msg "Starting make..."
38   rm -rf "${_bzrmod}-build"
39   cp -r "${_bzrmod}" "${_bzrmod}-build"
40   cd "${_bzrmod}-build"
41   
42   python2 setup.py install --prefix=$pkgdir/usr
44   # Some patches for compatibility in arch
45   cd $pkgdir
46   patch -Np1 < $srcdir/../eee-control-daemon.diff
47   patch -Np1 < $srcdir/../eee-control-daemon.conf.diff
48   cd $srcdir
49   # Now python 2.7 is called python2 (not needed when building from source)
50   #for i in eee-control-daemon eee-control-tray ; do
51     #sed -i -e "s|/usr/bin/python|/usr/bin/python2|g" $pkgdir/usr/bin/$i
52   #done 
54   #Remove some conflicting lines
55   sed -i '329d' $pkgdir/usr/lib/python2.7/site-packages/EeeControl/tray.py
56   sed -i '329d' $pkgdir/usr/lib/python2.7/site-packages/EeeControl/tray.py
57   
58   install -D -m 755 $pkgdir/usr/share/eee-control/eee-control.conf $pkgdir/etc/eee-control.conf
59   install -D -m 755 $startdir/eee-control-daemon.rc $pkgdir/etc/rc.d/eee-control-daemon 
61 md5sums=('f66a56858f0e9ee4b274c55df5fcf7fc'
62          '9a03658a5c1d358fc4d0a12fd95305ea'
63          'b22072d36fb4febae53698d841115112')