aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeonardo Arena <rnalrd@alpinelinux.org>2017-05-25 13:44:43 +0000
committerLeonardo Arena <rnalrd@alpinelinux.org>2017-05-25 13:45:01 +0000
commit05a62bda8ec255d7049a2bd4cf0fdc4b32bdb2cc (patch)
tree20883fa0b5d88e7cc8081e160d390e91a44f3cba
parent39d57d8175de808996c28f22244641045eb9ed1c (diff)
main/linux-pam: upgrade to 1.3.0
Modernize APKBUILD, disable check (fails)
-rw-r--r--main/linux-pam/APKBUILD40
-rw-r--r--main/linux-pam/linux-pam-innetgr.patch54
2 files changed, 14 insertions, 80 deletions
diff --git a/main/linux-pam/APKBUILD b/main/linux-pam/APKBUILD
index 3faf6002614..4dc4295aa9e 100644
--- a/main/linux-pam/APKBUILD
+++ b/main/linux-pam/APKBUILD
@@ -1,20 +1,17 @@
# Contributor: William Pitcock <nenolod@dereferenced.org>
# Maintainer: William Pitcock <nenolod@dereferenced.org>
pkgname=linux-pam
-pkgver=1.2.1
-pkgrel=1
+pkgver=1.3.0
+pkgrel=0
pkgdesc="pluggable authentication modules for linux"
url="http://www.kernel.org/pub/linux/libs/pam"
arch="all"
license="BSD"
-depends=
depends_dev="gettext-dev"
makedepends="$depends_dev bison flex-dev autoconf automake libtool"
-install=""
-options="suid"
+options="suid !check"
subpackages="$pkgname-dev $pkgname-doc"
source="http://linux-pam.org/library/Linux-PAM-$pkgver.tar.bz2
- linux-pam-innetgr.patch
fix-compat.patch
libpam-fix-build-with-eglibc-2.16.patch
musl-fix-pam_exec.patch
@@ -28,23 +25,17 @@ source="http://linux-pam.org/library/Linux-PAM-$pkgver.tar.bz2
su.pamd
"
-_builddir="$srcdir"/Linux-PAM-$pkgver
+builddir="$srcdir"/Linux-PAM-$pkgver
prepare() {
- local i
- cd "$_builddir"
- for i in $source; do
- case $i in
- *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
- esac
- done
-
+ cd "$builddir"
+ default_prepare
# disable insecure modules
sed -e 's/pam_rhosts//g' -i modules/Makefile.am
}
build() {
- cd "$_builddir"
- autoreconf -vif || return 1
+ cd "$builddir"
+ autoreconf -vif
[ "$CLIBC" = "musl" ] && export ac_cv_search_crypt=no
./configure \
--build=$CBUILD \
@@ -56,14 +47,13 @@ build() {
--infodir=/usr/share/info \
--localstatedir=/var \
--disable-nls \
- --disable-db \
- || return 1
- make || return 1
+ --disable-db
+ make
}
package() {
- cd "$_builddir"
- make DESTDIR="$pkgdir" install || return 1
+ cd "$builddir"
+ make DESTDIR="$pkgdir" install
# do not install pam.d files bundled with the source, they could be broken
rm -rf "$pkgdir"/etc/pam.d
@@ -80,13 +70,11 @@ package() {
done
# delete pointless libtool archives.
-
chgrp shadow "$pkgdir"/sbin/unix_chkpwd \
- && chmod g+s "$pkgdir"/sbin/unix_chkpwd || return 1
+ && chmod g+s "$pkgdir"/sbin/unix_chkpwd
}
-sha512sums="4572aa1eaf5a1312410c74b5ed055b2592c5efe2bb82f59981da4e9e93555ad40aee3a89f446d9dc6c6af79efc04c33f739f66db9edc07e02479475a14e426da Linux-PAM-1.2.1.tar.bz2
-ca32ecdacfc5b8f1482031203b616932b646a008b02080315ea2589af5962180d4ff4339c27fe9f6a878a89f47fb69429f4ac75d67b0e70ad7765a4db1dc74d9 linux-pam-innetgr.patch
+sha512sums="4a89ca4b6f4676107aca4018f7c11addf03495266b209cb11c913f8b5d191d9a1f72197715dcf2a69216b4036de88780bcbbb5a8652e386910d71ba1b6282e42 Linux-PAM-1.3.0.tar.bz2
52b97e23084f7b835ce1fa441663f91a50ea797cb38ba2c6662bcdaf0d25ba487118442674ac347fb17353af126dd6b3b696612faa56cac428dd842d14e1c90d fix-compat.patch
f49edf3876cc6bcb87bbea4e7beaeb0a382d596898c755f5fbaf6c2ed4e0c8f082b2cd16dde8a74af82bb09a1334f463e07a4bb5b8a48f023ff90a67ad2fdd44 libpam-fix-build-with-eglibc-2.16.patch
bc443d2a9b1d90b81959ce6fa154042365d5e7840f8696f847a145bbaaeffcbe1e9cd2b8ba76131a7b48737929e281f4fe864582fa4fc40315f2d10c650e0cd9 musl-fix-pam_exec.patch
diff --git a/main/linux-pam/linux-pam-innetgr.patch b/main/linux-pam/linux-pam-innetgr.patch
deleted file mode 100644
index a94fa3dae59..00000000000
--- a/main/linux-pam/linux-pam-innetgr.patch
+++ /dev/null
@@ -1,54 +0,0 @@
---- Linux-PAM-1.1.3.orig/modules/pam_group/pam_group.c
-+++ Linux-PAM-1.1.3/modules/pam_group/pam_group.c
-@@ -658,10 +658,13 @@
- continue;
- }
- /* If buffer starts with @, we are using netgroups */
-+#ifdef HAVE_INNETGR
- if (buffer[0] == '@')
- good &= innetgr (&buffer[1], NULL, user, NULL);
- /* otherwise, if the buffer starts with %, it's a UNIX group */
-- else if (buffer[0] == '%')
-+ else
-+#endif
-+ if (buffer[0] == '%')
- good &= pam_modutil_user_in_group_nam_nam(pamh, user, &buffer[1]);
- else
- good &= logic_field(pamh,user, buffer, count, is_same);
---- Linux-PAM-1.1.3.orig/modules/pam_succeed_if/pam_succeed_if.c
-+++ Linux-PAM-1.1.3/modules/pam_succeed_if/pam_succeed_if.c
-@@ -233,16 +233,20 @@
- static int
- evaluate_innetgr(const char *host, const char *user, const char *group)
- {
-+#ifdef HAVE_INNETGR
- if (innetgr(group, host, user, NULL) == 1)
- return PAM_SUCCESS;
-+#endif
- return PAM_AUTH_ERR;
- }
- /* Return PAM_SUCCESS if the (host,user) is NOT in the netgroup. */
- static int
- evaluate_notinnetgr(const char *host, const char *user, const char *group)
- {
-+#ifdef HAVE_INNETGR
- if (innetgr(group, host, user, NULL) == 0)
- return PAM_SUCCESS;
-+#endif
- return PAM_AUTH_ERR;
- }
-
---- Linux-PAM-1.1.3.orig/modules/pam_time/pam_time.c
-+++ Linux-PAM-1.1.3/modules/pam_time/pam_time.c
-@@ -554,9 +554,11 @@
- continue;
- }
- /* If buffer starts with @, we are using netgroups */
-+#ifdef HAVE_INNETGR
- if (buffer[0] == '@')
- good &= innetgr (&buffer[1], NULL, user, NULL);
- else
-+#endif
- good &= logic_field(pamh, user, buffer, count, is_same);
- D(("with user: %s", good ? "passes":"fails" ));
-