diff options
| author | Brian Bidulock <bidulock@openss7.org> | 2014-05-08 17:26:31 -0600 |
|---|---|---|
| committer | Brian Bidulock <bidulock@openss7.org> | 2015-06-10 15:33:32 -0600 |
| commit | 3bc83ef4aa0f8af83c5e477ad6cc75a35da7b2e6 (patch) | |
| tree | 8639b2a16d6c508a55fc2dfd3577df2dc8179802 | |
| parent | fa3e2e74e8da040429332ecc468b29e9e44ef0cc (diff) | |
| download | polkit-git-3bc83ef4aa0f8af83c5e477ad6cc75a35da7b2e6.tar.gz polkit-git-3bc83ef4aa0f8af83c5e477ad6cc75a35da7b2e6.tar.bz2 | |
version 20120725-1
| -rw-r--r-- | .SRCINFO | 11 | ||||
| -rw-r--r-- | PKGBUILD | 52 | ||||
| -rw-r--r-- | polkit.install | 30 |
3 files changed, 48 insertions, 45 deletions
@@ -1,9 +1,8 @@ pkgbase = polkit-git pkgdesc = Application development toolkit for controlling system-wide privileges - pkgver = 0.112.r33.g8277d89 + pkgver = 20120725 pkgrel = 1 - epoch = 1 - url = http://www.freedesktop.org/wiki/Software/polkit + url = http://www.freedesktop.org/wiki/Software/PolicyKit install = polkit.install arch = i686 arch = x86_64 @@ -15,13 +14,11 @@ pkgbase = polkit-git depends = glib2 depends = pam depends = expat - depends = systemd - depends = js17 + depends = js provides = polkit conflicts = polkit - source = polkit-git::git+http://anongit.freedesktop.org/git/polkit.git + replaces = policykit source = polkit.pam - md5sums = SKIP md5sums = 6564f95878297b954f0572bc1610dd15 pkgname = polkit-git @@ -1,47 +1,47 @@ -# $Id: PKGBUILD 210524 2014-04-14 20:07:24Z jgc $ -# Maintainer: Brian Bidulock <bidulock@openss7.org> -# Contributor: Jan de Groot <jgc@archlinux.org> -# Contributor: Aline Freitas <aline@alinefreitas.com.br> +# Maintainer: Aline Freitas <aline@alinefreitas.com.br> pkgname=polkit-git -pkgver=0.112.r33.g8277d89 +pkgver=20120725 pkgrel=1 -epoch=1 pkgdesc="Application development toolkit for controlling system-wide privileges" arch=(i686 x86_64) -license=(LGPL) -url="http://www.freedesktop.org/wiki/Software/polkit" -depends=(glib2 pam expat systemd js17) -makedepends=(intltool gtk-doc gobject-introspection git) -install=polkit.install +license=('LGPL') +url="http://www.freedesktop.org/wiki/Software/PolicyKit" +depends=('glib2' 'pam' 'expat' 'js') +makedepends=('intltool' 'gtk-doc' 'gobject-introspection' 'git') +replaces=('policykit') provides=('polkit') conflicts=('polkit') -source=($pkgname::git+http://anongit.freedesktop.org/git/polkit.git - polkit.pam) +source=('polkit.pam') +md5sums=('6564f95878297b954f0572bc1610dd15') +install=polkit.install -pkgver() { - cd $pkgname - git describe --tags --long|sed -r 's,([^-]*-g),r\1,;s,-,.,g' -} +_gitroot=('http://anongit.freedesktop.org/git/polkit.git') +_gitname=('polkit') build() { - cd $pkgname + cd ${srcdir} + msg "Connecting to GIT server...." + if [ -d ${_gitname} ]; then + cd ${_gitname} && git pull origin + msg "The local files are updated." + else + git clone ${_gitroot} ${_gitname} + fi + + msg "GIT checkout done or server timeout." + + cd ${srcdir}/${_gitname} ./autogen.sh --prefix=/usr --sysconfdir=/etc \ --localstatedir=/var --libexecdir=/usr/lib/polkit-1 \ - --enable-libsystemd-login=yes --disable-static \ - --enable-gtk-doc --with-mozjs=mozjs-17.0 + --disable-static --enable-gtk-doc make } package() { - cd $pkgname + cd ${srcdir}/${_gitname} make DESTDIR="$pkgdir" install - chown 102 "$pkgdir/etc/polkit-1/rules.d" - chown 102 "$pkgdir/usr/share/polkit-1/rules.d" - install -m644 "$srcdir/polkit.pam" "$pkgdir/etc/pam.d/polkit-1" } -md5sums=('SKIP' - '6564f95878297b954f0572bc1610dd15') diff --git a/polkit.install b/polkit.install index fbb9891..6a8d5c1 100644 --- a/polkit.install +++ b/polkit.install @@ -1,18 +1,24 @@ post_install() { - getent group polkitd >/dev/null || groupadd -g 102 polkitd - getent passwd polkitd >/dev/null || useradd -c 'Policy Kit Daemon' -u 102 -g polkitd -d '/' -s /bin/false polkitd - passwd -l polkitd &>/dev/null + # Check if user/group polkitd exists + getent group polkitd > /dev/null || groupadd polkitd + getent passwd polkitd > /dev/null || useradd -c "Polkitd system" -g polkitd -s /bin/false -d / polkitd + # Fix permissions + chown -R polkitd:polkitd /etc/polkit-1/rules.d + chmod 700 /etc/polkit-1/rules.d + + chown -R polkitd:polkitd /var/lib/polkit-1/rules.d + chmod 700 /etc/polkit-1/rules.d } post_upgrade() { - post_install -} + # Check if user/group polkitd exists + getent group polkitd > /dev/null || groupadd polkitd + getent passwd polkitd > /dev/null || useradd -c "Polkitd system" -g polkitd -s /bin/false -d / polkitd + # Fix permissions + chown -R polkitd:polkitd /etc/polkit-1/rules.d + chmod 700 /etc/polkit-1/rules.d -post_remove() { - if getent passwd polkitd >/dev/null; then - userdel polkitd - fi - if getent group polkitd >/dev/null; then - groupdel polkitd - fi + chown -R polkitd:polkitd /var/lib/polkit-1/rules.d + chmod 700 /etc/polkit-1/rules.d } + |
