diff options
Diffstat (limited to 'net-mail/cmd5checkpw/cmd5checkpw-0.22-r2.ebuild')
-rw-r--r-- | net-mail/cmd5checkpw/cmd5checkpw-0.22-r2.ebuild | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/net-mail/cmd5checkpw/cmd5checkpw-0.22-r2.ebuild b/net-mail/cmd5checkpw/cmd5checkpw-0.22-r2.ebuild new file mode 100644 index 000000000000..08b2605f1cd8 --- /dev/null +++ b/net-mail/cmd5checkpw/cmd5checkpw-0.22-r2.ebuild @@ -0,0 +1,63 @@ +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-mail/cmd5checkpw/cmd5checkpw-0.22-r2.ebuild,v 1.1 2005/02/13 12:22:39 hansmi Exp $ + +inherit eutils gcc + +DESCRIPTION="A checkpassword compatible authentication program that used CRAM-MD5 authentication mode." +SRC_URI="http://members.elysium.pl/brush/cmd5checkpw/dist/${P}.tar.gz" +HOMEPAGE="http://members.elysium.pl/brush/cmd5checkpw/" + +LICENSE="as-is" +SLOT="0" +KEYWORDS="~x86 ~ppc ~sparc ~mips ~alpha ~arm ~hppa ~amd64 ~ia64" +IUSE="" + +DEPEND="virtual/libc" + +douser() { + enewuser cmd5checkpw 212 /bin/false /dev/null bin +} + +pkg_preinst() { + douser +} + +pkg_setup() { + douser +} + +src_unpack() { + unpack "${A}" + cd "${S}" + + epatch ${FILESDIR}/euid.diff || die 'Applying euid.diff failed' +} + +src_compile() { + cp Makefile Makefile.orig + sed \ + -e "s:-c -g -Wall -O3:${CFLAGS}:" \ + -e "s:cp cmd5checkpw /bin/:cp cmd5checkpw \${D}/bin/:" \ + -e "s:cp cmd5checkpw.8 /usr/man/man8/:cp cmd5checkpw.8 \${D}/usr/share/man/man8/:" \ + < Makefile.orig > Makefile + cd ${S} + echo "$(gcc-getCC) ${CFLAGS}" > conf-cc + echo "$(gcc-getCC) ${LDFLAGS}" > conf-ld + make || die +} + +src_install() { + dodir /etc /bin /usr/share/man/man8 + insinto /etc + doins ${FILESDIR}/poppasswd + make install + fowners cmd5checkpw /etc/poppasswd /bin/cmd5checkpw + fperms 400 /etc/poppasswd + fperms u+s /bin/cmd5checkpw +} + +pkg_postinst() { + chmod 400 ${ROOT}/etc/poppasswd + chown cmd5checkpw ${ROOT}/etc/poppasswd +} |