summaryrefslogtreecommitdiffstats
path: root/gentoo/bcfg2-1.1.2.ebuild
diff options
context:
space:
mode:
authorNarayan Desai <desai@mcs.anl.gov>2011-06-22 17:01:40 -0500
committerNarayan Desai <desai@mcs.anl.gov>2011-06-22 17:01:40 -0500
commit4849378a62ab0dbf72f8ce4e6b2073dc73f2337a (patch)
tree14945dd6045c438f5dbc8e96f023258d31e1adf9 /gentoo/bcfg2-1.1.2.ebuild
parent8d08d5195fa0b6f503752273183948e5d24f33d6 (diff)
parent2db056574f5f55c3c802da63abe7e3de10db5d76 (diff)
downloadbcfg2-4849378a62ab0dbf72f8ce4e6b2073dc73f2337a.tar.gz
bcfg2-4849378a62ab0dbf72f8ce4e6b2073dc73f2337a.tar.bz2
bcfg2-4849378a62ab0dbf72f8ce4e6b2073dc73f2337a.zip
Merge branch 'master' of git.mcs.anl.gov:bcfg2
Diffstat (limited to 'gentoo/bcfg2-1.1.2.ebuild')
-rw-r--r--gentoo/bcfg2-1.1.2.ebuild65
1 files changed, 65 insertions, 0 deletions
diff --git a/gentoo/bcfg2-1.1.2.ebuild b/gentoo/bcfg2-1.1.2.ebuild
new file mode 100644
index 000000000..4da67d865
--- /dev/null
+++ b/gentoo/bcfg2-1.1.2.ebuild
@@ -0,0 +1,65 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="3"
+PYTHON_DEPEND="2:2.6"
+SUPPORT_PYTHON_ABIS="1"
+# ssl module required.
+RESTRICT_PYTHON_ABIS="2.4 2.5 3.*"
+
+inherit distutils
+
+DESCRIPTION="Bcfg2 is a configuration management tool."
+HOMEPAGE="http://bcfg2.org"
+
+# handle the "pre" case
+MY_P="${P/_/}"
+SRC_URI="ftp://ftp.mcs.anl.gov/pub/bcfg/${MY_P}.tar.gz"
+S="${WORKDIR}/${MY_P}"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~x64-solaris"
+IUSE="server"
+
+DEPEND="app-portage/gentoolkit
+ server? (
+ dev-python/lxml
+ app-admin/gam-server )"
+RDEPEND="${DEPEND}"
+
+PYTHON_MODNAME="Bcfg2"
+
+distutils_src_install_post_hook() {
+ if ! use server; then
+ rm -f "$(distutils_get_intermediate_installation_image)${EPREFIX}/usr/sbin/bcfg2-"*
+ fi
+}
+
+src_install() {
+ distutils_src_install --record=PY_SERVER_LIBS --install-scripts "${EPREFIX}/usr/sbin"
+
+ # Remove files only necessary for a server installation
+ if ! use server; then
+ rm -rf "${ED}usr/share/bcfg2"
+ rm -rf "${ED}usr/share/man/man8"
+ fi
+
+ # Install a server init.d script
+ if use server; then
+ newinitd "${FILESDIR}/bcfg2-server.rc" bcfg2-server
+ fi
+
+ insinto /etc
+ doins examples/bcfg2.conf || die "doins failed"
+}
+
+pkg_postinst () {
+ distutils_pkg_postinst
+
+ if use server; then
+ einfo "If this is a new installation, you probably need to run:"
+ einfo " bcfg2-admin init"
+ fi
+}