aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2018-02-10 13:31:11 -0600
committerWilliam Pitcock <nenolod@dereferenced.org>2018-02-12 14:48:38 +0000
commit5ae83ccf3e1cc61b24f9e5f130462386aaf840cb (patch)
treebde1a4f2315a2d3b138ff9c372c1db1bca37f0e4 /main
parentbdfc6072a0e314d740af3512d11d81e1232ac495 (diff)
downloadaports-5ae83ccf3e1cc61b24f9e5f130462386aaf840cb.tar.bz2
aports-5ae83ccf3e1cc61b24f9e5f130462386aaf840cb.tar.xz
main/polkit: modernise, fix license, add tests
Diffstat (limited to 'main')
-rw-r--r--main/polkit/APKBUILD58
-rw-r--r--main/polkit/disable-ck-test.patch15
-rw-r--r--main/polkit/fix-test-fgetpwent.patch20
3 files changed, 56 insertions, 37 deletions
diff --git a/main/polkit/APKBUILD b/main/polkit/APKBUILD
index 664117a043..f1df68435e 100644
--- a/main/polkit/APKBUILD
+++ b/main/polkit/APKBUILD
@@ -2,11 +2,11 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=polkit
pkgver=0.105
-pkgrel=7
+pkgrel=8
pkgdesc="Application development toolkit for controlling system-wide privileges"
url="http://www.freedesktop.org/wiki/Software/polkit/"
arch="all"
-license="LGPL"
+license="LGPL-2.0+"
depends=
options="suid"
depends_dev="eggdbus-dev dbus-glib-dev"
@@ -23,23 +23,19 @@ source="http://www.freedesktop.org/software/polkit/releases/polkit-$pkgver.tar.g
automake.patch
fix-parallel-make.patch
fix-consolekit-db-stat.patch
+ fix-test-fgetpwent.patch
+ disable-ck-test.patch
"
-_builddir="$srcdir"/polkit-$pkgver
-
prepare() {
- cd "$_builddir"
- update_config_sub || return 1
- for i in $source; do
- case $i in
- *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
- esac
- done
- libtoolize --force && aclocal && autoconf && automake --add-missing || return 1
+ cd "$builddir"
+ update_config_sub
+ default_prepare
+ libtoolize --force && aclocal && autoconf && automake --add-missing
}
build() {
- cd "$_builddir"
+ cd "$builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
@@ -56,35 +52,21 @@ build() {
--with-os-type=alpine \
--disable-gtk-doc \
--disable-gtk-doc-html \
- --disable-gtk-doc-pdf \
- || return 1
+ --disable-gtk-doc-pdf
+
+ make
+}
- make || return 1
+check() {
+ cd "$builddir"
+ make check
}
package() {
- cd "$_builddir"
- make DESTDIR="$pkgdir" install || return 1
+ cd "$builddir"
+ make DESTDIR="$pkgdir" install
}
-md5sums="9c29e1b6c214f0bd6f1d4ee303dfaed9 polkit-0.105.tar.gz
-bb4e7bffa5bad89bf3033b3d866a4087 0001-Bug-50145-make-netgroup-support-optional.patch
-2f2b7a0a5e79516582ce12a80c5677a2 CVE-2013-4288.patch
-a3d38d5b0bd35c066806b61cedc175d6 CVE-2015-3218.patch
-ff484f4397db117a6924fe6a65eb552e CVE-2015-3255.patch
-d18b03f6a0efe134e3c201a2c2410d33 CVE-2015-4625.patch
-38dfb2ffefa4f84d64e4cd93fda145f2 automake.patch
-cca56781a0ac23c0c56b5390fc8f8238 fix-parallel-make.patch
-3d049fef3f78c78b9bd0a6d9e7731692 fix-consolekit-db-stat.patch"
-sha256sums="8fdc7cc8ba4750fcce1a4db9daa759c12afebc7901237e1c993c38f08985e1df polkit-0.105.tar.gz
-80bf119937c5b75887bf6405e69e364a31e6e2edcac7957816ed7d8ea6b2a5a3 0001-Bug-50145-make-netgroup-support-optional.patch
-394be8089e90ed662af0b2043fa6abdda0c062d89970ce5f5a25df8633123d5e CVE-2013-4288.patch
-b15b54e86195a5c87efe058cc970db69f1dddbfebd97399689fccc77794f678a CVE-2015-3218.patch
-90b2a03cabe3a6ea5a5bab13cfb4236b8b7c6820f7a6d27786c601b0331a70e0 CVE-2015-3255.patch
-f34f46d445391234f75b0f92b63af70a5b9597555981dcc34bec78fd46229a98 CVE-2015-4625.patch
-de9e99ec691e45fc204eba576e301299952c0eb13ecedcb7399ba1b6aab94200 automake.patch
-fb0352d687b4b23acace3d211d9f48635d2eae43f5a478cbdda0f1e42784f735 fix-parallel-make.patch
-f0de45566d1ac79c0d9256e5c36244dfc74936dbc45f2af63ce9c6893dedea52 fix-consolekit-db-stat.patch"
sha512sums="7c0f84b9639814b4690e42b570285ff2018a5ea4cfd7216d9abf44c84ece6592c530f2d6211511c1346963daf4f135e9fa79d1b2f592b454115950991b5e4bc3 polkit-0.105.tar.gz
09ca9c14044c0a281e9069919efbb6d14918f23f58a282b5ce25c8a6640966396904373822869fe994c711f40c33d5c34cf3b77f85a59e239ba3d0c22a31ca8e 0001-Bug-50145-make-netgroup-support-optional.patch
d6de3beb063243c11906f525ef2eb65aeca823c25b1f44dde4a16f4fc2c5ce587b129e0bfb25a4a4b88ac2bf5713c47e57700c139323d961c9f9b6ba4c03fffb CVE-2013-4288.patch
@@ -93,4 +75,6 @@ d6de3beb063243c11906f525ef2eb65aeca823c25b1f44dde4a16f4fc2c5ce587b129e0bfb25a4a4
32ecc38db938fc1e3d14ffd9c492d12a42a91750e0eb1f66f8346d0cefd6e18fd0dffac8bffc65578cfb56c9598d3b336721477e8496de2619d6d69f1a6b309e CVE-2015-4625.patch
25465a23332247d0873e24cb5f011a267413615526755a8295a6367d64fc5eb8c2aa3c9c1fdcfa183b39e3ece14f33b25f15a339d966a31f3feb861b3f17adbf automake.patch
6b0d9262ba8b3c000acdcc8c86bd6fc043e5750a0155730638d4e3a92e63f43cb476d63b11856c041d60d8f38f7eb5ada0eb0eced9100bdac3bc2c7dd5108ddd fix-parallel-make.patch
-95493ef842b46ce9e724933a5d86083589075fb452435057b8f629643cac7c7eff67a24fd188087987e98057f0130757fad546d0c090767da3d71ebaf8485a24 fix-consolekit-db-stat.patch"
+95493ef842b46ce9e724933a5d86083589075fb452435057b8f629643cac7c7eff67a24fd188087987e98057f0130757fad546d0c090767da3d71ebaf8485a24 fix-consolekit-db-stat.patch
+966825aded565432f4fda9e54113a773b514ebf7ee7faa83bcb8b97d218ae84a8707d6747bbc3cb8a828638d692fdef34c05038f150ad38e02a29f2c782aba5b fix-test-fgetpwent.patch
+f73ab05ab5fdc90d3961fdcf88fa57eee8c90af4960b20d7ac845d2395c4cc20873ddc72bfd00fd127471336807faa705d0845444a0218343e74063e8f190980 disable-ck-test.patch"
diff --git a/main/polkit/disable-ck-test.patch b/main/polkit/disable-ck-test.patch
new file mode 100644
index 0000000000..e1987d40d1
--- /dev/null
+++ b/main/polkit/disable-ck-test.patch
@@ -0,0 +1,15 @@
+This test requires ConsoleKit to be running.
+
+--- polkit-0.105/test/polkitbackend/Makefile.am.old 2012-04-24 11:05:34.000000000 -0500
++++ polkit-0.105/test/polkitbackend/Makefile.am 2017-09-27 20:48:42.479959296 -0500
+@@ -36,8 +36,8 @@
+ TEST_PROGS += polkitbackendlocalauthorizationstoretest
+ polkitbackendlocalauthorizationstoretest_SOURCES = polkitbackendlocalauthorizationstoretest.c
+
+-TEST_PROGS += polkitbackendlocalauthoritytest
+-polkitbackendlocalauthoritytest_SOURCES = polkitbackendlocalauthoritytest.c
++#TEST_PROGS += polkitbackendlocalauthoritytest
++#polkitbackendlocalauthoritytest_SOURCES = polkitbackendlocalauthoritytest.c
+
+ # ----------------------------------------------------------------------------------------------------
+
diff --git a/main/polkit/fix-test-fgetpwent.patch b/main/polkit/fix-test-fgetpwent.patch
new file mode 100644
index 0000000000..7bc6481cc8
--- /dev/null
+++ b/main/polkit/fix-test-fgetpwent.patch
@@ -0,0 +1,20 @@
+--- polkit-0.105/test/mocklibc/src/pwd.c.old 2012-04-24 11:05:34.000000000 -0500
++++ polkit-0.105/test/mocklibc/src/pwd.c 2017-09-27 19:40:57.883227673 -0500
+@@ -16,6 +16,7 @@
+ * Author: Nikki VonHollen <vonhollen@gmail.com>
+ */
+
++#define _GNU_SOURCE
+ #include <pwd.h>
+
+ #include <stdio.h>
+--- polkit-0.105/test/mocklibc/src/grp.c.old 2012-04-24 11:05:34.000000000 -0500
++++ polkit-0.105/test/mocklibc/src/grp.c 2017-09-27 19:44:57.759238450 -0500
+@@ -16,6 +16,7 @@
+ * Author: Nikki VonHollen <vonhollen@gmail.com>
+ */
+
++#define _GNU_SOURCE
+ #include <grp.h>
+
+ #include <stdio.h>