summaryrefslogtreecommitdiff
path: root/extra/rtkit/PKGBUILD
blob: 7d5f551d7a46ea3e96cf103d96a52a7f1f4e8b26 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# $Id: PKGBUILD 185307 2013-05-13 06:17:53Z heftig $
# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Corrado Primier <bardo@aur.archlinux.org>

pkgname=rtkit
pkgver=0.11
pkgrel=2
pkgdesc="Realtime Policy and Watchdog Daemon"
arch=(i686 x86_64)
url="http://git.0pointer.de/?p=rtkit.git"
license=(GPL 'custom:BSD')
depends=(dbus polkit systemd)
install=rtkit.install
source=(http://0pointer.de/public/$pkgname-$pkgver.tar.xz
        libsystemd.patch)
md5sums=('a96c33b9827de66033d2311f82d79a5d'
         '35089c0a284005f4abcf45168415857e')

prepare() {
  cd $pkgname-$pkgver
  patch -Np1 -i ../libsystemd.patch
  autoreconf -fi
}

build() {
  cd $pkgname-$pkgver
  ./configure \
    --prefix=/usr \
    --sbindir=/usr/bin \
    --sysconfdir=/etc \
    --libexecdir=/usr/lib/$pkgname \
    --with-systemdsystemunitdir=/usr/lib/systemd/system
  make

  ./rtkit-daemon --introspect > org.freedesktop.RealtimeKit1.xml
}

package() {
  cd $pkgname-$pkgver
  make DESTDIR="$pkgdir" install

  install -Dm644 org.freedesktop.RealtimeKit1.xml \
    "$pkgdir/usr/share/dbus-1/interfaces/org.freedesktop.RealtimeKit1.xml"

  install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
  sed -ne '4,25p' rtkit.c >"$pkgdir/usr/share/licenses/$pkgname/COPYING"
}