summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatsuu Takuto <matsuu@gentoo.org>2008-10-27 21:29:45 +0000
committerMatsuu Takuto <matsuu@gentoo.org>2008-10-27 21:29:45 +0000
commitdabae9e42f66e24c3fd062e6d7917e0732c2b607 (patch)
tree86cedfa0fb7ca2ba74d0603a800951384bb59202 /sys-devel/distcc
parentAdded horde-imp-4.3. (diff)
downloadgentoo-2-dabae9e42f66e24c3fd062e6d7917e0732c2b607.tar.gz
gentoo-2-dabae9e42f66e24c3fd062e6d7917e0732c2b607.tar.bz2
gentoo-2-dabae9e42f66e24c3fd062e6d7917e0732c2b607.zip
Fixed xinetd issue and typo. Clean up distcc-config. Removed old revisions.
(Portage version: 2.2_rc12/cvs/Linux 2.6.27-gentoo x86_64)
Diffstat (limited to 'sys-devel/distcc')
-rw-r--r--sys-devel/distcc/ChangeLog9
-rw-r--r--sys-devel/distcc/distcc-2.18.3-r11.ebuild183
-rw-r--r--sys-devel/distcc/distcc-2.18.3-r12.ebuild186
-rw-r--r--sys-devel/distcc/distcc-3.0-r2.ebuild147
-rw-r--r--sys-devel/distcc/distcc-3.0-r3.ebuild16
-rw-r--r--sys-devel/distcc/files/3.0/distcc-config17
-rw-r--r--sys-devel/distcc/files/3.0/xinetd28
-rw-r--r--sys-devel/distcc/files/distcc-3.0-xinetd.patch15
8 files changed, 42 insertions, 559 deletions
diff --git a/sys-devel/distcc/ChangeLog b/sys-devel/distcc/ChangeLog
index 484a5eb86d29..808f577b5517 100644
--- a/sys-devel/distcc/ChangeLog
+++ b/sys-devel/distcc/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for sys-devel/distcc
# Copyright 2000-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/ChangeLog,v 1.178 2008/10/26 06:44:04 matsuu Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/ChangeLog,v 1.179 2008/10/27 21:29:44 matsuu Exp $
+
+ 27 Oct 2008; MATSUU Takuto <matsuu@gentoo.org>
+ +files/distcc-3.0-xinetd.patch, files/3.0/distcc-config,
+ -files/3.0/xinetd, -distcc-2.18.3-r11.ebuild, -distcc-2.18.3-r12.ebuild,
+ -distcc-3.0-r2.ebuild, distcc-3.0-r3.ebuild:
+ Fixed xinetd issue and typo. Clean up distcc-config. Removed old
+ revisions.
*distcc-3.0-r3 (26 Oct 2008)
diff --git a/sys-devel/distcc/distcc-2.18.3-r11.ebuild b/sys-devel/distcc/distcc-2.18.3-r11.ebuild
deleted file mode 100644
index b79454cedc11..000000000000
--- a/sys-devel/distcc/distcc-2.18.3-r11.ebuild
+++ /dev/null
@@ -1,183 +0,0 @@
-# Copyright 1999-2008 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/distcc-2.18.3-r11.ebuild,v 1.2 2008/08/17 03:24:18 mr_bones_ Exp $
-
-# If you change this in any way please email lisa@gentoo.org and make an
-# entry in the ChangeLog (this means you spanky :P). (2004-04-11) Lisa Seelye
-
-inherit autotools eutils flag-o-matic toolchain-funcs
-
-PATCHLEVEL="2.18-r1"
-
-DESCRIPTION="a program to distribute compilation of C code across several machines on a network"
-HOMEPAGE="http://distcc.samba.org/"
-SRC_URI="http://distcc.samba.org/ftp/distcc/distcc-${PV}.tar.bz2
- mirror://gentoo/${PN}-2.18-avahi.patch.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
-IUSE="avahi gnome gtk selinux ipv6"
-
-COMMON_DEP="dev-libs/popt
- avahi? ( >=net-dns/avahi-0.6.5 )"
-DEPEND=">=sys-devel/gcc-config-1.3.1
- userland_GNU? ( sys-apps/shadow )
- dev-util/pkgconfig
- dev-util/unifdef
- ${COMMON_DEP}"
-RDEPEND="
- gnome? (
- >=x11-libs/gtk+-2.0.0
- >=gnome-base/libgnome-2.0.0
- >=gnome-base/libgnomeui-2.0.0.0
- >=gnome-base/libglade-2.0.0
- x11-libs/pango
- >=gnome-base/gconf-2.0.0
- )
- gtk? (
- >=x11-libs/gtk+-2.0.0
- x11-libs/pango
- )
- selinux? ( sec-policy/selinux-distcc )
- ${COMMON_DEP}"
-
-pkg_setup() {
- if use avahi && ! built_with_use net-dns/avahi dbus; then
- eerror "${CATEGORY}/${PN} needs net-dns/avahi built with the dbus use"
- eerror "flag for avahi support."
- die "net-dns/avahi not built with dbus support"
- fi
-}
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
-
- # -Wl,--as-needed to close bug #128605
- epatch "${FILESDIR}/distcc-as-needed.patch"
-
- # See bug #75420 for more multilib stuff
- epatch "${FILESDIR}/distcc-gentoo-multilib-r1.patch"
- einfo "Please report to bug #75420 success or failure of this patch."
-
- rm -v popt/*.c || die
- if use avahi; then
- epatch "${DISTDIR}/${PN}-2.18-avahi.patch.bz2"
- epatch "${FILESDIR}/${PN}-avahi-configure.patch"
- eautoreconf
- fi
-}
-
-src_compile() {
- local myconf="--without-included-popt "
-
- #not taking any chances here, guessing which takes precedence in the
- #configure script, so we'll just make the distinction here:
- #gnome takes precedence over gtk if both are specified (gnome pulls
- #in gtk anyways...)
- use gtk && ! use gnome && myconf="${myconf} --with-gtk"
- use gtk && use gnome && myconf="${myconf} --with-gnome"
-
- #More legacy stuff?
- [ `gcc-major-version` -eq 2 ] && filter-lfs-flags
-
- if use ipv6; then
- ewarn "To use IPV6 you must have IPV6 compiled into your kernel"
- ewarn "either via a module or compiled code"
- ewarn "You can recompile without ipv6 with: USE='-ipv6' emerge distcc"
- myconf=" ${myconf} --enable-rfc2553 "
- epause 5
- fi
- econf ${myconf} $(use_enable avahi) || die "econf ${myconf} failed"
- emake || die "emake failed"
-}
-
-handle_avahi() {
- local avahi="-UAVAHI"
- use avahi && avahi="-DAVAHI"
- unifdef ${avahi} "${1}" > "${2}"
-}
-
-src_install() {
- make DESTDIR="${D%/}" install
-
- insinto /usr/share/doc/${PN}
- doins "${S}/survey.txt"
-
- exeinto /usr/bin
- doexe "${FILESDIR}/distcc-config"
-
- handle_avahi "${FILESDIR}/${PATCHLEVEL}/init" "${T}/init"
- newinitd "${T}/init" distccd || die
-
- handle_avahi "${FILESDIR}/${PATCHLEVEL}/conf" "${T}/conf"
- newconfd "${T}/conf" distccd || die
-
- # create and keep the symlink dir
- dodir /usr/lib/distcc/bin
- keepdir /usr/lib/distcc/bin
-
- # create the distccd pid directory
- dodir /var/run/distccd
- keepdir /var/run/distccd
-
- if use gnome || use gtk; then
- einfo "Renaming /usr/bin/distccmon-gnome to /usr/bin/distccmon-gui"
- einfo "This is to have a little sensability in naming schemes between distccmon programs"
- mv "${D}/usr/bin/distccmon-gnome" "${D}/usr/bin/distccmon-gui" || die
- dosym /usr/bin/distccmon-gui /usr/bin/distccmon-gnome
- fi
-
-}
-
-pkg_preinst() {
- # non-/ installs don't require us to do anything here
- [ "${ROOT}" != "/" ] && return 0
-
- # stop daemon since script is being updated
- [ -n "$(pidof distccd)" -a -x /etc/init.d/distccd ] && \
- /etc/init.d/distccd stop
-}
-
-pkg_postinst() {
- #are we doing bootstrap with has no useradd?
- if [[ ${CHOST} != *-*-gnu && ${CHOST} != *-linux* ]] || [ -x /usr/sbin/useradd ]; then
- enewuser distcc 240
- else
- ewarn "You do not have useradd (bootstrap) from shadow so I didn't"
- ewarn "install the distcc user. Note that attempting to start the daemon"
- ewarn "will fail. Please install shadow and re-emerge distcc."
- ebeep 2
- fi
-
- # By now everyone should be using the right envfile
-
- if [ "${ROOT}" = "/" ]; then
- einfo "Installing links to native compilers..."
- /usr/bin/distcc-config --install
- else
- # distcc-config can *almost* handle ROOT installs itself
- # but for now, but user must finsh things off
- ewarn "*** Installation is not complete ***"
- ewarn "You must run the following as root:"
- ewarn " /usr/bin/distcc-config --install"
- ewarn "after booting or chrooting into ${ROOT}"
- fi
- einfo "Setting permissions on ${ROOT}var/run/distccd"
- chown -R distcc:daemon "${ROOT}var/run/distccd"
- echo ""
-
- einfo "Tips on using distcc with Gentoo can be found at"
- einfo "http://www.gentoo.org/doc/en/distcc.xml"
- echo ""
- einfo "To use the distccmon programs with Gentoo you should use this command:"
- einfo " DISTCC_DIR=/var/tmp/portage/.distcc distccmon-text N"
- use gnome || use gtk && einfo "Or: DISTCC_DIR=/var/tmp/portage/.distcc distccmon-gnome"
-
- ewarn "***SECURITY NOTICE***"
- ewarn "If you are upgrading distcc please make sure to run etc-update to"
- ewarn "update your /etc/conf.d/distccd and /etc/init.d/distccd files with"
- ewarn "added security precautions (the --listen and --allow directives)"
- ebeep 5
-}
diff --git a/sys-devel/distcc/distcc-2.18.3-r12.ebuild b/sys-devel/distcc/distcc-2.18.3-r12.ebuild
deleted file mode 100644
index c4a2fad531f1..000000000000
--- a/sys-devel/distcc/distcc-2.18.3-r12.ebuild
+++ /dev/null
@@ -1,186 +0,0 @@
-# Copyright 1999-2008 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/distcc-2.18.3-r12.ebuild,v 1.5 2008/08/17 03:24:18 mr_bones_ Exp $
-
-# If you change this in any way please email lisa@gentoo.org and make an
-# entry in the ChangeLog (this means you spanky :P). (2004-04-11) Lisa Seelye
-
-inherit autotools eutils flag-o-matic toolchain-funcs fdo-mime
-
-PATCHLEVEL="2.18-r1"
-
-DESCRIPTION="a program to distribute compilation of C code across several machines on a network"
-HOMEPAGE="http://distcc.samba.org/"
-SRC_URI="http://distcc.samba.org/ftp/distcc/distcc-${PV}.tar.bz2
- mirror://gentoo/${PN}-2.18-avahi.patch.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
-IUSE="avahi gnome gtk selinux ipv6"
-
-COMMON_DEP="dev-libs/popt
- avahi? ( >=net-dns/avahi-0.6.5 )"
-DEPEND=">=sys-devel/gcc-config-1.3.1
- userland_GNU? ( sys-apps/shadow )
- dev-util/pkgconfig
- || ( dev-util/unifdef sys-freebsd/freebsd-ubin )
- >=sys-devel/autoconf-2.60
- ${COMMON_DEP}"
-RDEPEND="
- gnome? (
- >=x11-libs/gtk+-2.0.0
- >=gnome-base/libgnome-2.0.0
- >=gnome-base/libgnomeui-2.0.0.0
- >=gnome-base/libglade-2.0.0
- x11-libs/pango
- >=gnome-base/gconf-2.0.0
- )
- gtk? (
- >=x11-libs/gtk+-2.0.0
- x11-libs/pango
- )
- selinux? ( sec-policy/selinux-distcc )
- ${COMMON_DEP}"
-
-pkg_setup() {
- if use avahi && ! built_with_use net-dns/avahi dbus; then
- eerror "${CATEGORY}/${PN} needs net-dns/avahi built with the dbus use"
- eerror "flag for avahi support."
- die "net-dns/avahi not built with dbus support"
- fi
-}
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
-
- # -Wl,--as-needed to close bug #128605
- epatch "${FILESDIR}/distcc-as-needed.patch"
-
- # See bug #75420 for more multilib stuff
- epatch "${FILESDIR}/distcc-gentoo-multilib-r1.patch"
- einfo "Please report to bug #75420 success or failure of this patch."
-
- epatch "${FILESDIR}/distcc-freedesktop.patch"
- epatch "${FILESDIR}/distcc-create-dir.patch"
-
- rm -v popt/*.c || die
- if use avahi; then
- epatch "${DISTDIR}/${PN}-2.18-avahi.patch.bz2"
- epatch "${FILESDIR}/${PN}-avahi-configure.patch"
- fi
-
- eautoreconf
-}
-
-src_compile() {
- local myconf="--without-included-popt --docdir=/usr/share/doc/${PF}"
-
- #More legacy stuff?
- [ `gcc-major-version` -eq 2 ] && filter-lfs-flags
-
- if use ipv6; then
- ewarn "To use IPV6 you must have IPV6 compiled into your kernel"
- ewarn "either via a module or compiled code"
- ewarn "You can recompile without ipv6 with: USE='-ipv6' emerge distcc"
- myconf=" ${myconf} --enable-rfc2553 "
- epause 5
- fi
- econf ${myconf} $(use_enable avahi) $(use_with gnome) $(use_with gtk) || die "econf ${myconf} failed"
- emake || die "emake failed"
-}
-
-handle_avahi() {
- local avahi="-UAVAHI"
- use avahi && avahi="-DAVAHI"
- unifdef ${avahi} "${1}" > "${2}"
-}
-
-src_install() {
- make DESTDIR="${D%/}" install
-
- dodoc "${S}/survey.txt"
-
- exeinto /usr/bin
- doexe "${FILESDIR}/distcc-config"
-
- handle_avahi "${FILESDIR}/${PATCHLEVEL}/init" "${T}/init"
- newinitd "${T}/init" distccd || die
-
- handle_avahi "${FILESDIR}/${PATCHLEVEL}/conf" "${T}/conf"
- newconfd "${T}/conf" distccd || die
-
- # create and keep the symlink dir
- dodir /usr/lib/distcc/bin
- keepdir /usr/lib/distcc/bin
-
- # create the distccd pid directory
- dodir /var/run/distccd
- keepdir /var/run/distccd
-
- if use gnome || use gtk; then
- einfo "Renaming /usr/bin/distccmon-gnome to /usr/bin/distccmon-gui"
- einfo "This is to have a little sensability in naming schemes between distccmon programs"
- mv "${D}/usr/bin/distccmon-gnome" "${D}/usr/bin/distccmon-gui" || die
- dosym /usr/bin/distccmon-gui /usr/bin/distccmon-gnome
- fi
-
-}
-
-pkg_preinst() {
- # non-/ installs don't require us to do anything here
- [ "${ROOT}" != "/" ] && return 0
-
- # stop daemon since script is being updated
- [ -n "$(pidof distccd)" -a -x /etc/init.d/distccd ] && \
- /etc/init.d/distccd stop
-}
-
-pkg_postinst() {
- fdo-mime_desktop_database_update
-
- #are we doing bootstrap with has no useradd?
- if [[ ${CHOST} != *-*-gnu && ${CHOST} != *-linux* ]] || [ -x /usr/sbin/useradd ]; then
- enewuser distcc 240
- else
- ewarn "You do not have useradd (bootstrap) from shadow so I didn't"
- ewarn "install the distcc user. Note that attempting to start the daemon"
- ewarn "will fail. Please install shadow and re-emerge distcc."
- ebeep 2
- fi
-
- # By now everyone should be using the right envfile
-
- if [ "${ROOT}" = "/" ]; then
- einfo "Installing links to native compilers..."
- /usr/bin/distcc-config --install
- else
- # distcc-config can *almost* handle ROOT installs itself
- # but for now, but user must finsh things off
- ewarn "*** Installation is not complete ***"
- ewarn "You must run the following as root:"
- ewarn " /usr/bin/distcc-config --install"
- ewarn "after booting or chrooting into ${ROOT}"
- fi
- einfo "Setting permissions on ${ROOT}var/run/distccd"
- chown -R distcc:daemon "${ROOT}var/run/distccd"
- echo ""
-
- einfo "Tips on using distcc with Gentoo can be found at"
- einfo "http://www.gentoo.org/doc/en/distcc.xml"
- echo ""
- einfo "To use the distccmon programs with Gentoo you should use this command:"
- einfo " DISTCC_DIR=/var/tmp/portage/.distcc distccmon-text N"
- use gnome || use gtk && einfo "Or: DISTCC_DIR=/var/tmp/portage/.distcc distccmon-gnome"
-
- ewarn "***SECURITY NOTICE***"
- ewarn "If you are upgrading distcc please make sure to run etc-update to"
- ewarn "update your /etc/conf.d/distccd and /etc/init.d/distccd files with"
- ewarn "added security precautions (the --listen and --allow directives)"
- ebeep 5
-}
-
-pkg_postrm() {
- fdo-mime_desktop_database_update
-}
diff --git a/sys-devel/distcc/distcc-3.0-r2.ebuild b/sys-devel/distcc/distcc-3.0-r2.ebuild
deleted file mode 100644
index 36a8ba20e320..000000000000
--- a/sys-devel/distcc/distcc-3.0-r2.ebuild
+++ /dev/null
@@ -1,147 +0,0 @@
-# Copyright 1999-2008 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/distcc-3.0-r2.ebuild,v 1.1 2008/10/25 06:39:17 matsuu Exp $
-
-inherit eutils fdo-mime flag-o-matic multilib toolchain-funcs
-
-DESCRIPTION="a program to distribute compilation of C code across several machines on a network"
-HOMEPAGE="http://distcc.org/"
-SRC_URI="http://distcc.googlecode.com/files/${P}.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
-IUSE="avahi gnome gtk ipv6 selinux xinetd"
-
-RESTRICT="test"
-
-RDEPEND=">=dev-lang/python-2.4
- dev-libs/popt
- avahi? ( >=net-dns/avahi-0.6 )
- gnome? (
- >=gnome-base/libgnome-2
- >=gnome-base/libgnomeui-2
- >=x11-libs/gtk+-2
- x11-libs/pango
- )
- gtk? (
- >=x11-libs/gtk+-2
- )"
-DEPEND="${RDEPEND}
- dev-util/pkgconfig"
-RDEPEND="${RDEPEND}
- !net-misc/pump
- >=sys-devel/gcc-config-1.3.1
- selinux? ( sec-policy/selinux-distcc )
- xinetd? ( sys-apps/xinetd )"
-
-pkg_setup() {
- enewuser distcc 240 -1 -1 daemon
-}
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
- epatch "${FILESDIR}/${P}-gentoo.patch"
- epatch "${FILESDIR}/${P}-svn617.patch"
-}
-
-src_compile() {
- # More legacy stuff?
- [ "$(gcc-major-version)" = "2" ] && filter-lfs-flags
-
- # -O? is required
- [ "${CFLAGS/-O}" = "${CFLAGS}" ] && CFLAGS="${CFLAGS} -O2"
-
- econf \
- $(use_with avahi) \
- $(use_with gtk) \
- $(use_with gnome) \
- $(use_enable ipv6 rfc2553) \
- --with-docdir="/usr/share/doc/${PF}" || die "econf failed"
- emake || die "emake failed"
-}
-
-src_install() {
- emake DESTDIR="${D}" install || die
-
- dobin "${FILESDIR}/${PV}/distcc-config"
-
- newinitd "${FILESDIR}/${PV}/init" distccd
-
- cp "${FILESDIR}/${PV}/conf" "${T}/distccd"
- if use avahi; then
- cat >> "${T}/distccd" <<-EOF
-
- # Enable zeroconf support in distccd
- DISTCCD_OPTS="\${DISTCCD_OPTS} --zeroconf"
- EOF
- fi
- doconfd "${T}/distccd"
-
- cat > "${T}/02distcc" <<-EOF
- # This file is managed by distcc-config; use it to change these settings.'
- DISTCC_LOG=""
- DCCC_PATH="/usr/$(get_libdir)/distcc/bin"
- DISTCC_VERBOSE="0"
- EOF
- doenvd "${T}/02distcc"
-
- # create the masquerade directory
- local DCCC_PATH="/usr/$(get_libdir)/distcc/bin/"
- dodir "${DCCC_PATH}"
- for f in cc c++ gcc g++; do
- dosym /usr/bin/distcc "${DCCC_PATH}${f}"
- if [ "${f}" != "cc" ]; then
- dosym /usr/bin/distcc "${DCCC_PATH}${CTARGET:-${CHOST}}-${f}"
- fi
- done
-
- # create the distccd pid directory
- keepdir /var/run/distccd
- fowners distcc:daemon /var/run/distccd
-
- if use gnome || use gtk; then
- einfo "Renaming /usr/bin/distccmon-gnome to /usr/bin/distccmon-gui"
- einfo "This is to have a little sensability in naming schemes between distccmon programs"
- mv "${D}/usr/bin/distccmon-gnome" "${D}/usr/bin/distccmon-gui" || die
- dosym distccmon-gui /usr/bin/distccmon-gnome
- fi
-
- if use xinetd; then
- insinto /etc/xinetd.d
- newins "${FILEDIR}/${PV}/xinetd"
- fi
-
- rm -rf "${D}/etc/default"
- rm -f "${D}/etc/distcc/clients.allow"
- rm -f "${D}/etc/distcc/commands.allow.sh"
- prepalldocs
-}
-
-pkg_postinst() {
- use gnome && fdo-mime_desktop_database_update
-
- elog
- elog "Tips on using distcc with Gentoo can be found at"
- elog "http://www.gentoo.org/doc/en/distcc.xml"
- elog
- elog "To use the distccmon programs with Gentoo you should use this command:"
- elog "# DISTCC_DIR=\"${DISTCC_DIR}\" distccmon-text 5"
-
- if use gnome || use gtk; then
- elog "Or:"
- elog "# DISTCC_DIR=\"${DISTCC_DIR}\" distccmon-gnome"
- fi
-
- elog
- elog "***SECURITY NOTICE***"
- elog "If you are upgrading distcc please make sure to run etc-update to"
- elog "update your /etc/conf.d/distccd and /etc/init.d/distccd files with"
- elog "added security precautions (the --listen and --allow directives)"
- elog
-}
-
-pkg_postrm() {
- use gnome && fdo-mime_desktop_database_update
-}
diff --git a/sys-devel/distcc/distcc-3.0-r3.ebuild b/sys-devel/distcc/distcc-3.0-r3.ebuild
index 45069c5d1d08..bc798c9fedbc 100644
--- a/sys-devel/distcc/distcc-3.0-r3.ebuild
+++ b/sys-devel/distcc/distcc-3.0-r3.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/distcc-3.0-r3.ebuild,v 1.1 2008/10/26 06:44:04 matsuu Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/distcc-3.0-r3.ebuild,v 1.2 2008/10/27 21:29:44 matsuu Exp $
inherit eutils fdo-mime flag-o-matic multilib toolchain-funcs
@@ -35,7 +35,10 @@ RDEPEND="${RDEPEND}
selinux? ( sec-policy/selinux-distcc )
xinetd? ( sys-apps/xinetd )"
+DISTCC_POTENTIAL_HOSTS=""
+DISTCC_LOG=""
DCCC_PATH="/usr/$(get_libdir)/distcc/bin"
+DISTCC_VERBOSE="0"
pkg_setup() {
enewuser distcc 240 -1 -1 daemon
@@ -46,6 +49,7 @@ src_unpack() {
cd "${S}"
epatch "${FILESDIR}/${P}-gentoo.patch"
epatch "${FILESDIR}/${P}-svn617.patch"
+ epatch "${FILESDIR}/${P}-xinetd.patch"
sed -i -e "/PATH/s:\$distcc_location:${DCCC_PATH}:" pump.in || die
}
@@ -83,10 +87,10 @@ src_install() {
doconfd "${T}/distccd"
cat > "${T}/02distcc" <<-EOF
- # This file is managed by distcc-config; use it to change these settings.'
- DISTCC_LOG=""
+ # This file is managed by distcc-config; use it to change these settings.
+ DISTCC_LOG="${DISTCC_LOG}"
DCCC_PATH="${DCCC_PATH}"
- DISTCC_VERBOSE="0"
+ DISTCC_VERBOSE="${DISTCC_VERBOSE}"
EOF
doenvd "${T}/02distcc"
@@ -112,7 +116,7 @@ src_install() {
if use xinetd; then
insinto /etc/xinetd.d
- newins "${FILEDIR}/${PV}/xinetd"
+ newins "doc/example/xinetd" distcc
fi
rm -rf "${D}/etc/default"
@@ -129,7 +133,7 @@ pkg_postinst() {
elog "http://www.gentoo.org/doc/en/distcc.xml"
elog
elog "How to use pump mode with Gentoo:"
- elog "# distcc-config --set-host \"foo,cpp,lzo bar,cpp,lzo baz,cpp,lzo\""
+ elog "# distcc-config --set-hosts \"foo,cpp,lzo bar,cpp,lzo baz,cpp,lzo\""
elog "# pump emerge -u world"
elog
elog "To use the distccmon programs with Gentoo you should use this command:"
diff --git a/sys-devel/distcc/files/3.0/distcc-config b/sys-devel/distcc/files/3.0/distcc-config
index c763c2169339..11676e56993b 100644
--- a/sys-devel/distcc/files/3.0/distcc-config
+++ b/sys-devel/distcc/files/3.0/distcc-config
@@ -1,10 +1,11 @@
#!/usr/bin/env python
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/files/3.0/distcc-config,v 1.2 2008/10/25 06:39:17 matsuu Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/distcc/files/3.0/distcc-config,v 1.3 2008/10/27 21:29:44 matsuu Exp $
-import os, re, signal, sys, commands, pwd
+import os, re, signal, sys
from string import rstrip
+from subprocess import Popen
options=[
'--get-hosts',
@@ -49,7 +50,7 @@ def writeenv(var,value):
distcc_env[i] = var+'="'+value+'"\n'
distcc_env_new.write(distcc_env[i])
#print 'Set',var,'to:',value
- os.system('/usr/sbin/env-update')
+ Popen('/usr/sbin/env-update', shell=True)
print 'If you want to use these new settings in an existing shell,'
print 'you need to "source /etc/profile" to get the changes.'
@@ -82,7 +83,7 @@ if '--get-hosts' in tmpcmdline:
if HOSTS_ENV:
print HOSTS_ENV
elif os.path.isfile(HOSTS_HOME) and os.path.getsize(HOSTS_HOME) != 0:
- print HOSTS_HOME
+ print rstrip(open(HOSTS_HOME, 'r').read())
elif os.path.exists('/etc/distcc/hosts'):
print rstrip(open('/etc/distcc/hosts', 'r').read())
else:
@@ -116,7 +117,7 @@ elif '--set-env' in tmpcmdline:
else:
print '!!! Error: Awaiting two parameters.'
else:
- print 'Usage: /usr/bin/distcc-config --set-hosts DISTCC_HOSTS | --get-hosts'
- print ' /usr/bin/distcc-config --set-verbose { 0 | 1 } | --get-verbose'
- print ' /usr/bin/distcc-config --set-log FILE | --get-log'
- print ' /usr/bin/distcc-config --set-env VARIABLE VALUE | --get-env [VARIABLE]'
+ print 'Usage: %s --set-hosts DISTCC_HOSTS | --get-hosts' % sys.argv[0]
+ print ' %s --set-verbose { 0 | 1 } | --get-verbose' % sys.argv[0]
+ print ' %s --set-log FILE | --get-log' % sys.argv[0]
+ print ' %s --set-env VARIABLE VALUE | --get-env [VARIABLE]' % sys.argv[0]
diff --git a/sys-devel/distcc/files/3.0/xinetd b/sys-devel/distcc/files/3.0/xinetd
deleted file mode 100644
index 6554d7e59488..000000000000
--- a/sys-devel/distcc/files/3.0/xinetd
+++ /dev/null
@@ -1,28 +0,0 @@
-# default: off
-# description: distccd serves C/C++ compilation requests from distcc clients.
-# WARNING: This service should ONLY be used on trusted networks.
-
-# xinetd service description for distcc, contributed by akpm, updated
-# by mbp.
-
-# To use this, just check the parameters below and copy this file into
-# /etc/xinet.d/distcc, or the appropriate location for your system,
-# and then restart xinetd. You should also create a 'distcc' user.
-
-# ===> Note that running from inetd is generally NOT recommended for
-# distcc. distccd should give better performance when it can run as a
-# standalone daemon and regulate its own load.
-
-service distcc
-{
- disable = yes
- socket_type = stream
- wait = no
- user = distcc
- server = /usr/bin/distccd
- server_args = --inetd
-
- # This makes xinetd cope if there is no service listed in
- # /etc/services
- type = UNLISTED
-}
diff --git a/sys-devel/distcc/files/distcc-3.0-xinetd.patch b/sys-devel/distcc/files/distcc-3.0-xinetd.patch
new file mode 100644
index 000000000000..47877ad45b42
--- /dev/null
+++ b/sys-devel/distcc/files/distcc-3.0-xinetd.patch
@@ -0,0 +1,15 @@
+diff -Naur distcc-3.0.orig/doc/example/xinetd distcc-3.0/doc/example/xinetd
+--- distcc-3.0.orig/doc/example/xinetd 2008-08-07 05:52:13.000000000 +0900
++++ distcc-3.0/doc/example/xinetd 2008-10-27 15:32:14.000000000 +0900
+@@ -19,10 +19,6 @@
+ socket_type = stream
+ wait = no
+ user = distcc
+- server = /usr/local/bin/distccd
++ server = /usr/bin/distccd
+ server_args = --inetd
+-
+- # This makes xinetd cope if there is no service listed in
+- # /etc/services
+- type = UNLISTED
+ }