summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatsuu Takuto <matsuu@gentoo.org>2010-01-23 06:49:05 +0000
committerMatsuu Takuto <matsuu@gentoo.org>2010-01-23 06:49:05 +0000
commitfe8833c144ec92cff75b4f9380c743c6e14f97bd (patch)
tree67b950da3491a9e82f370ab0a2e1e962f085c372 /sys-apps/ccs-tools/ccs-tools-1.6.8_p20100115.ebuild
parentuse.unmask sys-apps/groff-1.20.1-r2 linguas_ja, bug #290103. (diff)
downloadhistorical-fe8833c144ec92cff75b4f9380c743c6e14f97bd.tar.gz
historical-fe8833c144ec92cff75b4f9380c743c6e14f97bd.tar.bz2
historical-fe8833c144ec92cff75b4f9380c743c6e14f97bd.zip
Version bumped. ccs-tools-1.7* was moved to sys-apps/tomoyo-tools.
Package-Manager: portage-2.1.7.16/cvs/Linux x86_64
Diffstat (limited to 'sys-apps/ccs-tools/ccs-tools-1.6.8_p20100115.ebuild')
-rw-r--r--sys-apps/ccs-tools/ccs-tools-1.6.8_p20100115.ebuild78
1 files changed, 78 insertions, 0 deletions
diff --git a/sys-apps/ccs-tools/ccs-tools-1.6.8_p20100115.ebuild b/sys-apps/ccs-tools/ccs-tools-1.6.8_p20100115.ebuild
new file mode 100644
index 000000000000..e07c8548fa23
--- /dev/null
+++ b/sys-apps/ccs-tools/ccs-tools-1.6.8_p20100115.ebuild
@@ -0,0 +1,78 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/ccs-tools/ccs-tools-1.6.8_p20100115.ebuild,v 1.1 2010/01/23 06:49:05 matsuu Exp $
+
+EAPI="2"
+inherit eutils multilib toolchain-funcs
+
+MY_P="${P/_p/-}"
+DESCRIPTION="TOMOYO Linux tools"
+HOMEPAGE="http://tomoyo.sourceforge.jp/"
+SRC_URI="mirror://sourceforge.jp/tomoyo/30298/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RESTRICT="test"
+
+DEPEND="sys-libs/ncurses
+ sys-libs/readline"
+RDEPEND="${DEPEND}
+ sys-apps/which"
+
+S="${WORKDIR}/ccstools"
+
+src_prepare() {
+ epatch "${FILESDIR}/${PN}-1.6.8_p20090623-gentoo.patch"
+
+ sed -i \
+ -e "/^CC=/s:gcc:$(tc-getCC):" \
+ -e "/^CFLAGS=/s:-O2:${CFLAGS}:" \
+ -e "s:/usr/lib/:/usr/$(get_libdir)/:g" \
+ Makefile || die
+
+ sed -i \
+ -e "s:/usr/lib/ccs:/usr/$(get_libdir)/ccs:g" \
+ init_policy.sh tomoyo_init_policy.sh || die
+
+ echo "CONFIG_PROTECT=\"/usr/$(get_libdir)/ccs/conf\"" > "${T}/50${PN}" || die
+}
+
+src_test() {
+ cd "${S}/kernel_test"
+ emake || die
+ ./testall.sh || die
+}
+
+src_install() {
+ emake INSTALLDIR="${D}" install || die
+
+ rm "${D}"/usr/$(get_libdir)/ccs/{COPYING.ccs,README.ccs,ccstools.conf} || die
+ insinto /usr/$(get_libdir)/ccs/conf
+ doins ccstools.conf || die
+ dosym conf/ccstools.conf /usr/$(get_libdir)/ccs/ccstools.conf || die
+
+ doenvd "${T}/50${PN}" || die
+
+ dodoc README.ccs
+}
+
+pkg_postinst() {
+ elog "Execute the following command to setup the initial policy configuration:"
+ elog
+ elog "emerge --config =${CATEGORY}/${PF}"
+ elog
+ elog "For more information, please visit the following."
+ elog
+ elog "For >=kernel-2.6.30:"
+ elog "http://tomoyo.sourceforge.jp/en/2.2.x/"
+ elog
+ elog "For <kernel-2.6.30 + ccs-patch:"
+ elog "http://tomoyo.sourceforge.jp/en/1.6.x/"
+}
+
+pkg_config() {
+ /usr/$(get_libdir)/ccs/tomoyo_init_policy.sh
+}