# Copyright 1999-2004 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: $ DESCRIPTION="Jailkit is a tool for automatic chrooting of daemons and creation of restricted and chrooted user shells" HOMEPAGE="http://olivier.sessink.nl/jailkit/" SRC_URI="http://olivier.sessink.nl/jailkit/${P}.tar.bz2" LICENSE="BSD" SLOT="0" KEYWORDS="~x86" IUSE="" DEPEND="" RDEPEND="sys-libs/glibc >=dev-lang/python-2.0" src_compile() { # prevent write access to /etc/shells (sandbox violation). patch -i ${FILESDIR}/jailkit-1.3-Makefile.diff Makefile.in # wrong python path provided by sandbox patch -i ${FILESDIR}/jailkit-1.3-py-Makefile.gentoo.diff py/Makefile.in econf --prefix=${D}/usr || die "econf failed" emake || die "emake failed" } src_install() { make install DESTDIR=${D} iniprefix=${D}/etc/jailkit/ || die # update /etc/shells to include jk_chrootsh cp /etc/shells ${D}/etc/shells if ! grep /usr/sbin/jk_chrootsh ${D}/etc/shells ; then echo /usr/sbin/jk_chrootsh >> ${D}/etc/shells fi # insert own initscript (needed for baselayout >= 1.11.x) exeinto /etc/init.d; doexe ${FILESDIR}/jailkit }