-# Copyright 1999-2009 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
LICENSE="BSD"
SLOT="0"
-KEYWORDS="~x86"
+KEYWORDS="~amd64 ~x86"
IUSE=""
src_prepare() {
epatch \
"${FILESDIR}/${P}-ldflags.patch" \
- "${FILESDIR}/${P}-pyc.patch"
+ "${FILESDIR}/${P}-pyc.patch" \
+ "${FILESDIR}/${P}-noshells.patch"
eautoreconf
}
src_install() {
emake DESTDIR="${D}" install || die "emake install failed"
- doinitd "${FILESDIR}/jailkit"
+ doinitd "${FILESDIR}/jailkit" || die "doinit install failed"
}
pkg_postinst() {
- elog "Don't forget to add /usr/sbin/jk_chrootsh to /etc/shells."
-}
-
-pkg_postrm() {
- elog "If you want to keep your system clean, don't forget to remove"
- elog "the line containing /usr/sbin/jk_chrootsh from /etc/shells."
+ ebegin "Updating /etc/shells"
+ { grep -v "^/usr/sbin/jk_chrootsh$" "${ROOT}"etc/shells; echo "/usr/sbin/jk_chrootsh"; } > "${T}"/shells
+ mv -f "${T}"/shells "${ROOT}"etc/shells
+ eend $?
}