diff options
author | Martin Schlemmer <azarah@gentoo.org> | 2003-11-09 23:46:10 +0000 |
---|---|---|
committer | Martin Schlemmer <azarah@gentoo.org> | 2003-11-09 23:46:10 +0000 |
commit | ea4960ae593df6f5c5afa6c68b1c8ed8461f7484 (patch) | |
tree | ea9bc120e5b58eb8bde85b4580f0a87c70c252cb /sys-libs | |
parent | Update version (diff) | |
download | gentoo-2-ea4960ae593df6f5c5afa6c68b1c8ed8461f7484.tar.gz gentoo-2-ea4960ae593df6f5c5afa6c68b1c8ed8461f7484.tar.bz2 gentoo-2-ea4960ae593df6f5c5afa6c68b1c8ed8461f7484.zip |
Update version
Diffstat (limited to 'sys-libs')
-rw-r--r-- | sys-libs/pam/ChangeLog | 12 | ||||
-rw-r--r-- | sys-libs/pam/Manifest | 5 | ||||
-rw-r--r-- | sys-libs/pam/files/digest-pam-0.77 | 3 | ||||
-rw-r--r-- | sys-libs/pam/pam-0.77.ebuild | 278 |
4 files changed, 294 insertions, 4 deletions
diff --git a/sys-libs/pam/ChangeLog b/sys-libs/pam/ChangeLog index 3594501bff83..1d269a6e4150 100644 --- a/sys-libs/pam/ChangeLog +++ b/sys-libs/pam/ChangeLog @@ -1,6 +1,16 @@ # ChangeLog for sys-libs/pam # Copyright 2002-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-libs/pam/ChangeLog,v 1.33 2003/10/29 04:01:01 pebenito Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-libs/pam/ChangeLog,v 1.34 2003/11/09 23:46:00 azarah Exp $ + +*pam-0.77 (10 Nov 2003) + + 10 Nov 2003; Martin Schlemmer <azarah@gentoo.org> pam-0.77.ebuild: + New version. The bulk of the work was done by Donny Davies + <woodchip@gentoo.org>. I just added all the gentoo patches, as well + as made the db stuff link to our own version of db, and not ndbm. I + also (in gentoo patches) made pam_pwdb, pam_radius and pam_crack link + to static versions of libraries, and split new pwdb as an new version + of our existing sys-libs/pwdb. Other cleanups. 28 Oct 2003; Chris PeBenito <pebenito@gentoo.org> pam-0.75-r11.ebuild, files/pam-0.75-selinux.diff.bz2: diff --git a/sys-libs/pam/Manifest b/sys-libs/pam/Manifest index 1b443d44c830..44b3c3a304be 100644 --- a/sys-libs/pam/Manifest +++ b/sys-libs/pam/Manifest @@ -1,8 +1,7 @@ -MD5 7647626979e59069a6972d4ade094705 .pam-0.77.ebuild.swp 24576 MD5 dcaa1c02e7f5d00cf0aeacf53e877fb8 pam-0.75-r9.ebuild 4110 MD5 df9f17b6bc137ef27a0fa5c2e51a5231 pam-0.75-r7.ebuild 4098 -MD5 12a2979bfce44a4168213b4206d54932 ChangeLog 5062 -MD5 0d0228504adff4e7df65e9fc4f857d0e pam-0.77.ebuild 6359 +MD5 6199137bb7092e226275eaddd05e640b ChangeLog 5551 +MD5 8fee27d607677afad89e22c95dac6f1c pam-0.77.ebuild 7095 MD5 d9b7f898f1a20564a56c43638de7aad6 pam-0.75-r8.ebuild 3659 MD5 c366f917105da5082cafe4d4a821cfb2 pam-0.75-r11.ebuild 4702 MD5 04493e7fb78879ce6385f5c545a7315b pam-0.75-r10.ebuild 4228 diff --git a/sys-libs/pam/files/digest-pam-0.77 b/sys-libs/pam/files/digest-pam-0.77 new file mode 100644 index 000000000000..5106b2de67e5 --- /dev/null +++ b/sys-libs/pam/files/digest-pam-0.77 @@ -0,0 +1,3 @@ +MD5 be5a470e553ba71c20e9bbc7665f3754 Linux-PAM-0.77.tar.gz 442569 +MD5 dbe8d741991132203d7e5f924b3077c1 pam-0.77-patches-1.0.tar.bz2 110994 +MD5 df71961002b552c0e72c6e4e358f27e1 db-4.1.25.tar.gz 3080234 diff --git a/sys-libs/pam/pam-0.77.ebuild b/sys-libs/pam/pam-0.77.ebuild new file mode 100644 index 000000000000..adc348d54ed6 --- /dev/null +++ b/sys-libs/pam/pam-0.77.ebuild @@ -0,0 +1,278 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-libs/pam/pam-0.77.ebuild,v 1.1 2003/11/09 23:46:00 azarah Exp $ + +# Note that we link to static versions of glib (pam_console.so) +# and pwdb (pam_pwdb.so) ... + +DESCRIPTION="Pluggable Authentication Modules" +HOMEPAGE="http://www.kernel.org/pub/linux/libs/pam/" + +IUSE="berkdb pwdb" + +PATCH_LEVEL="1.0" +BDB_VER="4.1.25" +PAM_REDHAT_VER="0.77-4" + +S="${WORKDIR}/Linux-PAM-${PV}" +S2="${WORKDIR}/pam-${PVR}-patches" +SRC_URI="http://www.kernel.org/pub/linux/libs/pam/pre/library/Linux-PAM-${PV}.tar.gz + mirror://gentoo/${P}-patches-${PATCH_LEVEL}.tar.bz2 + berkdb? ( http://www.sleepycat.com/update/snapshot/db-${BDB_VER}.tar.gz )" + +LICENSE="PAM" +#KEYWORDS="~amd64 ~x86 ~ppc ~sparc ~alpha ~mips ~hppa ~arm ~ia64" +KEYWORDS="-*" +SLOT="0" + +DEPEND="dev-lang/perl + >=sys-libs/cracklib-2.7-r8 + =dev-libs/glib-1.2* + >=sys-devel/autoconf-2.5 + >=sys-devel/automake-1.6 + >=sys-devel/flex-2.5.4a-r5 + pwdb? ( >=sys-libs/pwdb-0.62 ) + selinux? ( sys-libs/libselinux )" +# Have python sandbox issues currently ... +# doc? ( app-text/sgmltools-lite ) + +RDEPEND=">=sys-libs/cracklib-2.7-r8 + selinux? ( sys-libs/libselinux ) + berkdb? ( >=sys-libs/db-${BDB_VER} )" + +# BDB is internalized to get a non-threaded lib for pam_userdb.so to +# be built with. The runtime-only dependency on BDB suggests the user +# will use the system-installed db_load to create pam_userdb databases. +# PWDB is internalized because it is specifically designed to work +# with Linux-PAM. I'm not really certain how pervasive the Radius +# and NIS services of PWDB are at this point. +# +# With all the arch's we support, I rather use external pwdb, and then +# link statically to it - <azarah@gentoo.org> (09 Nov 2003). + +#inherit needs to be after DEPEND definition to protect RDEPEND +inherit gcc eutils flag-o-matic + +apply_pam_patches() { + local x= + local patch= + + for x in redhat gentoo + do + cat ${S2}/list.${x}-patches | grep -v '^#' | grep -v '^$' | while read X + do + patch="$(echo $X | sed -e 's|^Patch.*: \(.*\)|\1|')" + epatch ${S2}/${x}-patches/${patch} + done + done +} + +pkg_setup() { + local x= + + for x in libpwdb.a libcrack.a + do + [ -z "$(use pwdb)" ] && continue + + [ ! -f "${ROOT}/usr/lib/${x}" ] && { + eerror "Could not find /usr/lib/${x} needed to build Linux-PAM!" + die "Could not find /usr/lib/${x} needed to build Linux-PAM!" + } + done +} + +src_unpack() { + unpack ${A} || die "Couldn't unpack ${A}" + + cd ${S} || die + tar -zxf ${S2}/pam-redhat-${PAM_REDHAT_VER}.tar.gz \ + || die "Couldn't unpack pam-redhat-${PAM_REDHAT_VER}.tar.gz" + + apply_pam_patches + + use selinux && epatch ${S2}/gentoo-patches/pam-selinux.patch + + for readme in modules/pam_*/README ; do + cp -f "${readme}" doc/txts/README.$(dirname "${readme}" | \ + sed -e 's|^modules/||') + done + + cp /usr/share/automake/install-sh . || die + export WANT_AUTOCONF_2_5=1 + autoconf || die +} + +src_compile() { + export CFLAGS="${CFLAGS} -fPIC" + + if [ -n "$(use berkdb)" ] + then + einfo "Building Berkley DB ${BDB_VER}..." + cd ${WORKDIR} + cd db-${BDB_VER}/dist || die + echo db_cv_mutex=UNIX/fcntl > config.cache + ./s_config + ./configure \ + --cache-file=config.cache \ + --disable-compat185 \ + --disable-cxx \ + --disable-diagnostic \ + --disable-dump185 \ + --disable-java \ + --disable-rpc \ + --disable-tcl \ + --disable-shared \ + --with-pic \ + --with-uniquename=_pam \ + --prefix=${S} \ + --includedir=${S}/include \ + --libdir=${S}/lib || die "Bad BDB ./configure" + + # XXX hack out O_DIRECT support in db4 for now. + perl -pi -e 's/#define HAVE_O_DIRECT 1/#undef HAVE_O_DIRECT/' \ + db_config.h + + make || die "BDB build failed" + make install || die + + export CPPFLAGS="-I${S}/include" + export LDFLAGS="-L${S}/lib" + export LIBNAME="lib" + fi + + if [ "${ARCH}" = "alpha" ] + then + if [ ! -z "$(strings -a /usr/lib/libglib.a | grep -i 'Compaq Computer Corp.')" ] + then + # should be LDFLAGS, but this configure is screwy. + echo + einfo "It looks like you compiled glib with ccc, this is okay, but" + einfo "I'll need to force gcc to link with libots...." + echo + append-flags -lots + sed -i -e 's/$(CC) -o/$(CC) -lots -o/g' ${S}/modules/pam_pwdb/Makefile + fi + fi + + einfo "Building Linux-PAM ${PV}..." + cd ${S} + ./configure \ + --libdir=/lib \ + --enable-static-libpam \ + --enable-fakeroot=${D} \ + --enable-isadir=/lib/security \ + --host=${CHOST} || die + + # Python stuff in docs gives sandbox problems + sed -i -e 's|modules doc examples|modules|' Makefile + + # Fix warnings for gcc-2.95.3 + if [ "$(gcc-version)" = "2.95" ] + then + sed -i -e "s:-Wpointer-arith::" Make.Rules + fi + + if [ -z "$(use berkdb)" ] + then + # Do not build pam_userdb.so ... + sed -i -e "s:^HAVE_NDBM_H=yes:HAVE_NDBM_H=no:" \ + -e "s:^HAVE_LIBNDBM=yes:HAVE_LIBNDBM=no:" \ + -e "s:^HAVE_LIBDB=yes:HAVE_LIBDB=no:" \ + Make.Rules + else + # Do not link pam_userdb.so to db-1.85 ... + sed -i -e "s:^HAVE_NDBM_H=yes:HAVE_NDBM_H=no:" \ + -e "s:^HAVE_LIBNDBM=yes:HAVE_LIBNDBM=no:" \ + Make.Rules + fi + + make || die "PAM build failed" +} + +src_install() { + local x= + + einfo "Installing Linux-PAM ${PV}..." + make FAKEROOT=${D} \ + LDCONFIG="" \ + install || die + + # Make sure every module built. + # Do not remove this, as some module can fail to build + # and effectively lock the user out of his system. + einfo "Checking if all modules were built..." + for x in ${S}/modules/pam_* + do + if [ -d ${x} ] + then + # Its OK if the module failed when we didnt ask for it anyway + if ! ls -1 ${D}/lib/security/$(basename ${x})*.so &> /dev/null + then + if [ -z "$(use berkdb)" -a "$(basename ${x})" = "pam_userdb" ] + then + continue + fi + if [ -z "$(use pwdb)" -a "$(basename ${x})" = "pam_pwdb" ] + then + continue + fi + if [ -z "$(use pwdb)" -a "$(basename ${x})" = "pam_radius" ] + then + continue + fi + eerror "ERROR: $(basename ${x}) module did not build." + exit 1 + else + # Remove the ones we didnt want if it ended up building ok anyways + if [ -z "$(use berkdb)" -a "$(basename ${x})" = "pam_userdb" ] + then + rm -f ${D}/lib/security/pam_userdb* + fi + if [ -z "$(use pwdb)" -a "$(basename ${x})" = "pam_pwdb" ] + then + rm -f ${D}/lib/security/pam_pwdb* + fi + if [ -z "$(use pwdb)" -a "$(basename ${x})" = "pam_radius" ] + then + rm -f ${D}/lib/security/pam_radius* + fi + fi + fi + done + + dodir /usr/lib + cd ${D}/lib + for x in pam pamc pam_misc + do + rm lib${x}.so + ln -s lib${x}.so.${PV} lib${x}.so + ln -s lib${x}.so.${PV} lib${x}.so.0 + mv lib${x}.a ${D}/usr/lib + # See bug #4411 + gen_usr_ldscript lib${x}.so + done + + cd ${S} + doman doc/man/*.[58] + + dodoc CHANGELOG Copyright README + docinto modules ; dodoc modules/README ; dodoc doc/txts/README.* + docinto txt ; dodoc doc/specs/*.txt #doc/txts/*.txt +# docinto print ; dodoc doc/ps/*.ps + +# docinto html +# dohtml -r doc/html/ + + # need this for pam_console + keepdir /var/run/console + + insinto /etc/pam.d + for x in ${FILESDIR}/${PVR}/pam.d/* + do + if [ -f ${x} ] + then + doins ${x} + fi + done +} + |