updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / ulatencyd / PKGBUILD
blob02e3aac180da2939fbfbf35fb449788d364f9e18
1 # Maintainer: SpepS <dreamspepser at yahoo dot it>
3 pkgname=ulatencyd
4 pkgver=0.5.0
5 pkgrel=3
6 pkgdesc="Daemon to minimize latency on a linux system using cgroups"
7 arch=(i686 x86_64)
8 url="https://github.com/poelzi/ulatencyd"
9 license=('GPL3')
10 depends=('luaposix' 'dbus-glib' 'libxcb' 'polkit')
11 optdepends=('python2-qt: qt gui'
12             'systemd: systemd service')
13 makedepends=('cmake')
14 conflicts=("$pkgname-git")
15 backup=("etc/$pkgname/$pkgname.conf")
16 options=('!emptydirs')
17 source=("https://github.com/downloads/poelzi/$pkgname/$pkgname-$pkgver.tar.gz"
18         "$pkgname.d" "$pkgname" "std.patch")
19 md5sums=('ef03b9c62ebc2f24327963e0c3a55eae'
20          'ceb27033cb79d2a9ad71e390b0b75d7d'
21          '2fb2440ceab34523d6207dfc53dc79d5'
22          '6c3356fb18bd53dcb05987eb1a111d65')
24 build() {
25   cd "$srcdir/$pkgname-$pkgver"
27   # man path fix
28   sed -i "s|/man/man|/share&|g" docs/CMakeLists.txt
30   # closing STD* in daemon mode cause 100% CPU
31   # quick fix: remove close(STD*_FILENO);
32   # TODO: Signal this bug upstream
33   # UPDATE: Applied official patch from poelzi
34   patch -p1 -i ../std.patch
36   cmake . -DCMAKE_INSTALL_PREFIX=/usr
37   make
40 package() {
41   cd "$srcdir/$pkgname-$pkgver"
43   make DESTDIR="$pkgdir/" install
45   # daemon
46   install -Dm755 ../$pkgname "$pkgdir/etc/rc.d/$pkgname"
47   install -Dm644 ../$pkgname.d "$pkgdir/etc/conf.d/$pkgname"
49   # pyqt gui python2 fix
50   sed -i 's/env python/&2/' "$pkgdir/usr/bin/ulatency"
53 # vim:set ts=2 sw=2 et: