summaryrefslogtreecommitdiff
path: root/sys-devel/distcc
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-03-23 04:19:44 +0000
committerV3n3RiX <venerix@redcorelinux.org>2018-03-23 04:19:44 +0000
commitc5283d322accc6097afec74eab24550829788bab (patch)
treeb99ce668128d82a026eaa31461643f9173f9b77b /sys-devel/distcc
parent5510d9d7d1c93c2ea71a2bd6f0666168808d5dd6 (diff)
gentoo resync : 23.03.2018
Diffstat (limited to 'sys-devel/distcc')
-rw-r--r--sys-devel/distcc/Manifest2
-rw-r--r--sys-devel/distcc/distcc-3.3.ebuild194
2 files changed, 196 insertions, 0 deletions
diff --git a/sys-devel/distcc/Manifest b/sys-devel/distcc/Manifest
index c22cbdb8d921..62d2a420860b 100644
--- a/sys-devel/distcc/Manifest
+++ b/sys-devel/distcc/Manifest
@@ -20,7 +20,9 @@ AUX distccd.service 244 BLAKE2B db5796f93fe36b2ed09cf84e54bacdb3483917438feb823b
AUX distccd.service.conf 186 BLAKE2B b3776e30ded7777be2610f07acec0f70a3cfb7718be149ad5bebd58538add7efead69368020c30610ec33a87ab4d3b3f0123d347f6d0d4abd74f3c714b039955 SHA512 19bf25757ba724ba4e728797b8c6fccabb8b95d2945f0e3c216303a04a4e7470507dcf8535657954f265ed5f067f32dcb3fb6558e9958a86de76b1e66e2b31b6
DIST distcc-3.1.tar.bz2 588820 BLAKE2B fbd00a9cf8af0b2a0c901a60086901e505d9859827a8249ed7937cb8298fc946f6f72470e40dba17e143dbf1525cb0aef4deec3d083268d608f24f1447301df0 SHA512 0ca7167309badf5d36d2783bab398295b52c43fde0355cf1902032c70b27fc40c21729c98af0ee4c0aeea0c48755e4626308e9385d938b7822de27cdb048e7bd
DIST distcc-3.2rc1.tar.bz2 609904 BLAKE2B e6b928f3b9231524d37bdf86b39cd6a3601b6cdb1e03d913ae562286794240b4dd364d5d01da2176f9bb440809b166b4b877443459751adf8bd3ecf92ceb8476 SHA512 98b2e8423d724bbb6a615d946d170441a8e293310785f867d7a277b318c043a37b0af39ae8ed1f7a0667803de9db1d1925199bad85130cf9bd9cb347635125ee
+DIST distcc-3.3.tar.gz 1171281 BLAKE2B f637cacbfdaaca6efb56e912de55fcfa49e3fffcb8f34649e339f16376250e18a20d30281a46f207992c0b300c726427a3ad5a77bd8976d2993f8f49b9b6b970 SHA512 459c175c8ac905bc70299e77ac11b6d24782bd69c9152126249c9af8fbb4c269e6f7317b02abf50cf6cc0405dd0f887e803320e19dc528a19c4c488640c615dc
EBUILD distcc-3.1-r10.ebuild 4499 BLAKE2B 8cf796bdbc315f8db8b0c52bc8108f0f2785b40e8dc14669a5675e00ee3dd9145b03f6c901137d7b726e78d372ef73206189f280831de11f3daa6f811356ee70 SHA512 22f383d20c3f6a028ad60b77692e680537dc4838aed70f9e17e05ea1aa52b137903a02f855651b5f381708e6ebe19edd201c11ac4269627866232c05752b067d
EBUILD distcc-3.2_rc1-r4.ebuild 5729 BLAKE2B 65c9309335e2479328f34ef428e308d77687306d158ba52cd7946d8128bdc221014845f5035614357b7bba934332bf69e9cb870e01dff2a8c319b66ea8d032e0 SHA512 34eafd30725c82f9f576d383a4a0886296fc992a9bc36c38bf103b42029a06e473515ff62f9ce8236448a89a6bbb4fef77bbb3d72582d1dc5da7da77701c4e8a
EBUILD distcc-3.2_rc1-r5.ebuild 5465 BLAKE2B e51b1b140c00f55c431f5cd157404c379233902add2e6b9fcfd95e4ba2e30ef2f1983461805a692e17afb4e5b2b59b7ff94c4473da367736b2fee7af0c2ccc2f SHA512 1082602afd53213860d13223693f0fd78dfd250a5047eec27263aec2ef3661da69757e8b56b93ffad7ee3629e06c3cb19e8a71e1a511910d2157540a2ea50e91
+EBUILD distcc-3.3.ebuild 5438 BLAKE2B aec6d252ddc60cd83604ddde78219829d2a8472493c44837aad7d26bdcf947c5e549394afcc545b20c97a9625806221e89eb8720d5fe3bdb086ed79ccd0eb3ca SHA512 1ae984a3fb20eba013fad40faec6fa714797d77c4539482fe97d6c0f01a9a8a20cea12e236623c6c9821d55b4f6b034436adf7a8027d44b97f4339ed7f471a4a
MISC metadata.xml 578 BLAKE2B c49d0c85a80028a82eb3e1729709515c9a2161a506a9883f0e50b1cfe27f21b98b5ee9728f297e3e5b5a35d8ae3aad6e55424d9da9ef3018a71299aa1139988b SHA512 a1fd5bdea076ed862339dda2a21f5c0c4c56aa625927f0157889aa5310e9e86df2c957b587d56b276c3d0b3cc2d0eb69f15e40493cc36d44de97917659dba1a2
diff --git a/sys-devel/distcc/distcc-3.3.ebuild b/sys-devel/distcc/distcc-3.3.ebuild
new file mode 100644
index 000000000000..d2216d7fe2d8
--- /dev/null
+++ b/sys-devel/distcc/distcc-3.3.ebuild
@@ -0,0 +1,194 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python3_{5,6} )
+
+inherit flag-o-matic python-single-r1 systemd toolchain-funcs user xdg-utils prefix
+
+MY_P="${P/_}"
+DESCRIPTION="Distribute compilation of C code across several machines on a network"
+HOMEPAGE="http://distcc.org/"
+SRC_URI="https://github.com/${PN}/${PN}/releases/download/v${PV}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="gnome gssapi gtk hardened ipv6 selinux xinetd zeroconf"
+
+RESTRICT="test"
+
+CDEPEND="${PYTHON_DEPS}
+ dev-libs/popt
+ gnome? (
+ >=gnome-base/libgnome-2
+ >=gnome-base/libgnomeui-2
+ x11-libs/gtk+:2
+ x11-libs/pango
+ )
+ gssapi? ( net-libs/libgssglue )
+ gtk? ( x11-libs/gtk+:2 )
+ zeroconf? ( >=net-dns/avahi-0.6[dbus] )
+"
+DEPEND="${CDEPEND}
+ sys-libs/binutils-libs
+ virtual/pkgconfig"
+RDEPEND="${CDEPEND}
+ !net-misc/pump
+ dev-util/shadowman
+ >=sys-devel/gcc-config-1.4.1
+ selinux? ( sec-policy/selinux-distcc )
+ xinetd? ( sys-apps/xinetd )"
+
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ enewuser distcc 240 -1 -1 daemon
+ python-single-r1_pkg_setup
+
+ DCCC_PATH="/usr/$(get_libdir)/distcc/bin"
+ DISTCC_VERBOSE="0"
+}
+
+src_prepare() {
+ eapply "${FILESDIR}/${PN}-3.0-xinetd.patch"
+ # bug #255188
+ eapply "${FILESDIR}/${PN}-3.2_rc1-freedesktop.patch"
+ # SOCKSv5 support needed for Portage, bug #537616
+ eapply "${FILESDIR}/${PN}-3.2_rc1-socks5.patch"
+ eapply_user
+
+ # Bugs #120001, #167844 and probably more. See patch for description.
+ use hardened && eapply "${FILESDIR}/distcc-hardened.patch"
+
+ sed -i \
+ -e "/PATH/s:\$distcc_location:${EPREFIX}${DCCC_PATH}:" \
+ -e "s:@PYTHON@:${EPYTHON}:" \
+ pump.in || die "sed failed"
+
+ sed \
+ -e "s:@EPREFIX@:${EPREFIX:-/}:" \
+ -e "s:@libdir@:/usr/$(get_libdir):" \
+ "${FILESDIR}/3.2/distcc-config" > "${T}/distcc-config" || die
+
+ hprefixify -e "s,/lib/,/$(get_libdir)/," update-distcc-symlinks.py src/{serve,daemon}.c
+}
+
+src_configure() {
+ local myconf="--disable-Werror"
+
+ # --disable-rfc2553 b0rked, bug #254176
+ use ipv6 && myconf="${myconf} --enable-rfc2553"
+
+ econf \
+ $(use_with gtk) \
+ $(use_with gnome) \
+ $(use_with gssapi auth) \
+ $(use_with zeroconf avahi) \
+ ${myconf}
+}
+
+src_install() {
+ default
+ python_optimize
+
+ newinitd "${FILESDIR}/3.2/init" distccd
+ systemd_dounit "${FILESDIR}/distccd.service"
+ systemd_install_serviced "${FILESDIR}/distccd.service.conf"
+
+ cp "${FILESDIR}/3.2/conf" "${T}/distccd" || die
+ if use zeroconf; then
+ cat >> "${T}/distccd" <<-EOF || die
+
+ # Enable zeroconf support in distccd
+ DISTCCD_OPTS="\${DISTCCD_OPTS} --zeroconf"
+ EOF
+
+ sed -i '/ExecStart/ s|$| --zeroconf|' "${D}$(systemd_get_systemunitdir)"/distccd.service || die
+ fi
+ doconfd "${T}/distccd"
+
+ cat > "${T}/02distcc" <<-EOF || die
+ # This file is managed by distcc-config; use it to change these settings.
+ # DISTCC_LOG and DISTCC_DIR should not be set.
+ DISTCC_VERBOSE="${DISTCC_VERBOSE:-0}"
+ DISTCC_FALLBACK="${DISTCC_FALLBACK:-1}"
+ DISTCC_SAVE_TEMPS="${DISTCC_SAVE_TEMPS:-0}"
+ DISTCC_TCP_CORK="${DISTCC_TCP_CORK}"
+ DISTCC_SSH="${DISTCC_SSH}"
+ UNCACHED_ERR_FD="${UNCACHED_ERR_FD}"
+ DISTCC_ENABLE_DISCREPANCY_EMAIL="${DISTCC_ENABLE_DISCREPANCY_EMAIL}"
+ DCC_EMAILLOG_WHOM_TO_BLAME="${DCC_EMAILLOG_WHOM_TO_BLAME}"
+ EOF
+ doenvd "${T}/02distcc"
+
+ keepdir "${DCCC_PATH%bin}"
+
+ dobin "${T}/distcc-config"
+
+ 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 "${ED}/usr/bin/distccmon-gnome" "${ED}/usr/bin/distccmon-gui" || die
+ dosym distccmon-gui /usr/bin/distccmon-gnome
+ fi
+
+ if use xinetd; then
+ insinto /etc/xinetd.d
+ newins "doc/example/xinetd" distcc
+ fi
+
+ insinto /usr/share/shadowman/tools
+ newins - distcc <<<"${EPREFIX}${DCCC_PATH}"
+ newins - distccd <<<"${EPREFIX}${DCCC_PATH%bin}"
+
+ rm -r "${ED}/etc/default" || die
+ rm "${ED}/etc/distcc/clients.allow" || die
+ rm "${ED}/etc/distcc/commands.allow.sh" || die
+}
+
+pkg_postinst() {
+ if [[ ${ROOT} == / ]]; then
+ eselect compiler-shadow update distcc
+ eselect compiler-shadow update distccd
+ fi
+
+ use gnome && xdg_desktop_database_update
+
+ elog
+ elog "Tips on using distcc with Gentoo can be found at"
+ elog "https://wiki.gentoo.org/wiki/Distcc"
+ elog
+ elog "How to use pump mode with Gentoo:"
+ elog "# distcc-config --set-hosts \"foo,cpp,lzo bar,cpp,lzo baz,cpp,lzo\""
+ elog "# echo 'FEATURES=\"\${FEATURES} distcc distcc-pump\"' >> /etc/portage/make.conf"
+ elog "# emerge -u world"
+ elog
+ elog "To use the distccmon programs with Gentoo you should use this command:"
+ elog "# DISTCC_DIR=\"${DISTCC_DIR:-${BUILD_PREFIX}/.distcc}\" distccmon-text 5"
+
+ if use gnome || use gtk; then
+ elog "Or:"
+ elog "# DISTCC_DIR=\"${DISTCC_DIR:-${BUILD_PREFIX}/.distcc}\" distccmon-gnome"
+ fi
+
+ elog
+ elog "***SECURITY NOTICE***"
+ elog "Since distcc-3.3, whitelist is used for what distccd could execute. The whilelist"
+ elog "has been generated by compiler-shadow distccd. To revert to the old behavior, "
+ elog "you need to pass --make-me-a-botnet to distccd in /etc/conf.d/distccd."
+ elog "Cf. https://github.com/distcc/distcc/pull/243."
+}
+
+pkg_prerm() {
+ if [[ -z ${REPLACED_BY_VERSION} && ${ROOT} == / ]]; then
+ eselect compiler-shadow remove distcc
+ fi
+}
+
+pkg_postrm() {
+ use gnome && xdg_desktop_database_update
+}