summaryrefslogtreecommitdiff
path: root/sys-devel/icecream
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /sys-devel/icecream
reinit the tree, so we can have metadata
Diffstat (limited to 'sys-devel/icecream')
-rw-r--r--sys-devel/icecream/Manifest19
-rw-r--r--sys-devel/icecream/files/0.9.6-crosscompile.patch12
-rw-r--r--sys-devel/icecream/files/0.9.6-symlinks.patch19
-rw-r--r--sys-devel/icecream/files/0.9.7-automake.patch32
-rw-r--r--sys-devel/icecream/files/0.9.7-glibc2.16.patch16
-rw-r--r--sys-devel/icecream/files/icecream43
-rw-r--r--sys-devel/icecream/files/icecream-1.0.0-libcap-ng.patch8
-rw-r--r--sys-devel/icecream/files/icecream-conf.d-verbosity.patch18
-rw-r--r--sys-devel/icecream/files/icecream-config69
-rw-r--r--sys-devel/icecream/files/icecream-create-env82
-rw-r--r--sys-devel/icecream/files/icecream-gentoo-multilib.patch59
-rw-r--r--sys-devel/icecream/files/icecream-r244
-rw-r--r--sys-devel/icecream/icecream-0.9.7-r1.ebuild86
-rw-r--r--sys-devel/icecream/icecream-1.0.0-r1.ebuild51
-rw-r--r--sys-devel/icecream/icecream-1.0.0-r2.ebuild69
-rw-r--r--sys-devel/icecream/metadata.xml15
16 files changed, 642 insertions, 0 deletions
diff --git a/sys-devel/icecream/Manifest b/sys-devel/icecream/Manifest
new file mode 100644
index 000000000000..8fe85f3bb198
--- /dev/null
+++ b/sys-devel/icecream/Manifest
@@ -0,0 +1,19 @@
+AUX 0.9.6-crosscompile.patch 471 SHA256 b0d4f69301cac95f5e3a7a3a91b5470769144e0deb33cb1504b70ad29b8cb783 SHA512 5c33cd6a1aae9b628e6308a4438355298ee0b4217d8561aaee9960c816aa336aa62eb2e5844f8cf756bbf3731fda4c07ac4c1bf30b2ef93c45205dcfbe8a7ae4 WHIRLPOOL e3bcf73125e91ca9d5d0e1a8b314d042734ae89cf4d2f77bd44821ea6fa665dd344af9049eb88a3c0f593e71f22ebef6a5ccc8a42fda08a25d8e15c82799993f
+AUX 0.9.6-symlinks.patch 614 SHA256 4100330fb48453abe7facecff4eb199e5285093df49d082e14050a4c30cb2dfb SHA512 739a683cb9142fb2ee52ec73194de03dac8815103fbd7a102cebabefd649c8ddfe6121649727de2785a525493a5f244352aa5a18796361014e6fe6fcbfe92321 WHIRLPOOL aab994500630cfe1b498ab3f870c45ae1a9745e3472c9d0ee9b50f42cb08312754768a62ee035d913853e0cfe7ce05c9c90772df238e68b6a91a2d4ab1e67ed6
+AUX 0.9.7-automake.patch 1085 SHA256 6f3281250708ec2ea5a1dd188104bdfa66e5f7b388c58a0b4827d3cc9f108da5 SHA512 2a2b8a03d10783a56484ec7b97cec0bf8f6853fc9c1e8d558297f7d1d0060d3e53410d9b6c77bd00359e249817fd6f0d854773850a1983b19417cee140ec17e3 WHIRLPOOL cbb5a0dcc9c5ec97458a38e91dace3474f7edd80d8190193295b22f427adb9aa9aa7ddabea29f078d93ada521610ae3fc479e6d3b42faa345d4dbd67a982da9b
+AUX 0.9.7-glibc2.16.patch 342 SHA256 7beb8999615edc5926c731c4f9f40c1cdf899f0a13aa0663847c415d23b4faba SHA512 3c3f0cbc15637d6f46ea4b7a7036a74a8ad46ab42f2ccfdda1638e0fa5cfc16e382ebefeb5294f937a34285c63d205f86b91ef0650a2ccaa8c5253f35ee1cecd WHIRLPOOL dd587412c5ad7956ffc59b9b0ec420e9702955b8aa27453f7c3e07826191a127ab2df68f7830bd360c109f2130025aa176d8e6d2e7a6411db1418564e1c40829
+AUX icecream 1614 SHA256 239aeadc35c4fa183a8ef4088fdfee709000e3c048a6bf2b9268ec7c287ede87 SHA512 670367aeab3a3e30c3f9c136b8965955db77e9b8555cffb3aba8872966553e955172bf2e47593ef661e8f7b8f2caa0db71750d978c2764fd72d458d6524f7fda WHIRLPOOL e5b1de90d12201e359a4b14b6520096b0e2d58a78878ce077770520de3d20f58010af1703aaed98622a4c594fd1de4e87de2daddcb19257a789faa833ed2ea00
+AUX icecream-1.0.0-libcap-ng.patch 195 SHA256 e6f54ce79c0da6c8f9b1379e21dc6ed528b2734dbaa7a9653b275a08073771e2 SHA512 31f69f07ad55465103587239249d2fd173dc3b920a026c7754635a3ada39696c1ccccbe636ced0ca2a2283b4adb8f23083a32586c2e803c1f18ad4afd3cc8746 WHIRLPOOL c0ef52dccf5aff25e7a93b949342a5ea1fe1e770c035c73d35a2e0a958016e5370c0fd3f7b15da899cc134ec13ac59c2b6666a8ae81be06fba837f1aff22bdad
+AUX icecream-conf.d-verbosity.patch 364 SHA256 d1191d31f84f2b1f1bcab67cecd0f77bc80db32d07766e7e3b6bc4cf886147cc SHA512 607b8eb2e50bf77fcf5f31757dd44fda9bc2c98241239d1e23bf17228e68e32a391e22d0b859ad725c176f21580a0a92931644c5b3ecfd23d844719f035d38eb WHIRLPOOL fc0283058fed7deca2b8917289838c84e9821436e7a4c648ebd32edabf1180ee321db75e736b805a6695f313977ab63857dc9cfb80119905182f2f701928da88
+AUX icecream-config 1692 SHA256 24acbd8e5b0218ce966e78f451985f72530865f86e5a1ee2b6c92d8bf50ff66b SHA512 9bba4e6ebabfc5c2b6d205fdf53e08ce1c29801da6a69534d5c3c221ce1ff7d8575d56bd451254ee9d30d27b6a95d00fd64e3a5cb1129c72583193a27a7fef70 WHIRLPOOL bd23a6f38ecf907363fb15d6968be688c58c053e116575de68ad9a656fd3b4f3b880e82a5da70ec250bd5a8f926a665a88a45144d57052a57187cd66241a40a2
+AUX icecream-create-env 2137 SHA256 edcafb128d8bb833aeb0c2544c5ecdd2336f0ed60015e5a33096a972b1856c0f SHA512 0de4ca5a865eea62fe6aaa70982bb75c0c78490491f6a713fab1c5be6fe0a67492efcb836f6e97914a8252665d9c5e7a9c7d01f8805af0bd4108dbaabbc0eb32 WHIRLPOOL e369d8b9bd77992a756f480a5bddfa640d9630b3da75cca68ff173909ba4b12bd44124ee0a1c7d8e12c8b1890333a53a17d66818625eb1ebedf7d96b8272e1e4
+AUX icecream-gentoo-multilib.patch 1579 SHA256 0efa29f5cb350aa8118cb9c4ba8d62cf675b6af5692ee18e25021f463465fc8a SHA512 24a9de13691e39e96c32db5722e7a6979a7a233335bf37fc42f5cf8d8b67d111d26fcf68d5fc20acc4aacee0d1e7cc88ff04ee36a127efc45f3bffe269e7c253 WHIRLPOOL 58f94a649e807fd8c90e384cf84111cf32fb994c45233d2ef6225e97f2d0ae88e3192e42d0d89e0e89e841fea3b54cff6c164e31866a628ba77960a08c182921
+AUX icecream-r2 1733 SHA256 ba0ed1cc54acfac9d72679c95fd031130623a35304ae1e9a80ba55751da69355 SHA512 033ce0d49445db3afcbdd6724863651d4951b8f36f6253a13854abe9ee976419687579089aa1c5c808eed08aad357e34bb9f1e70570857cc39f2515ac2f211b0 WHIRLPOOL de58aaf7ede01afa034175bd4c0de0decb5b218d750e55118f9874ddfdf7ee755bd5a5c0e87380dd7092c76b34dd2685c42e67f09956b97390e1f6db83e210bd
+DIST icecc-0.9.7.tar.bz2 379527 SHA256 ba01c19e946d5a142ad9f912c24086ee12e7ca4927d64860787eb4bcd100657f SHA512 023a77d6df33af9837a87218272dc61d68f3782ad59dc8783ec3ca47cbb38619dbcaa25ac7e6654c6cacbd79477c3403b0a73aca595c6fe20aa9a39268f4f2e2 WHIRLPOOL cf822cc6667ceda286b41c4fd172092f51d75cb2c5d1ca3db0dd32796580128808881f09053f209d7f9165ccecf9e97093925fca1ae54597b2a775485d82004f
+DIST icecc-1.0.0.tar.bz2 485534 SHA256 c2897fac52711b8442ec40403c874bc50a10184131bb7006529087dfe469c85c SHA512 4292ecef6232112c3f4531cb2290a55f70c5c24095fef0865af2526d49fc10a043ffb06d22552e161f671c18ff1ab62795c3a63e2c8cb26f869cf65d0938af2a WHIRLPOOL 3c6e79756bd290e03fbfcd5fd5e38dbb700e0a7b1206c2a608914123a9f317f1d9896332c79909754fda6fc9c515a29dba6b4c485a505d1ca0fde315c35cd3ce
+EBUILD icecream-0.9.7-r1.ebuild 2713 SHA256 8a3d42a1c60ea147c993b9da37e914597ee4c34494e00682df47118b7519a3cb SHA512 5b79e2c5722f1632bb1ccff1341168534d78cb41c1c779825758f5e3f3f6f2bcaca58018d2915b54efb3fabe65b3cd3f8007c1a4601be240457105f8143b3ba9 WHIRLPOOL a4c0fa996239d50a730a0b70282be9298f41bf074f809b5b80935a58bb271feff125ad9df22c6b93dd69d88c1ee77d8fd2244b950c9099879c84820ce344ee08
+EBUILD icecream-1.0.0-r1.ebuild 1022 SHA256 166b77ab3fc3e7090b1556513a813f07511170c17ba638d66cfe9c046dfdea6d SHA512 bdc885463b426c96dc64e668f8e3b753d7645149286910a705102931b3c81df56e855caf4e6231a85962ab9cdfb2ad9920224c359aeee49193f1b6d7a8ee0803 WHIRLPOOL ad8fde83c96ef980b6caeba4b86f2bd769a9b13dc5200774f0aa3fe83e966ea7e56cc672db6daa0cf6c018c4ea9ee6d193112a3db409fb86dae5ef562337b9de
+EBUILD icecream-1.0.0-r2.ebuild 1314 SHA256 2d7b7c4952d26d37f525359361effac34d0d58aa2075ed2a6139211a56b4bfff SHA512 f5cb905b24d48c97a44f6e7ec5a064854913b1a686f8a8f163d8bcb73ef5e9c8ba42ca89bef4c19d75492d8fe1363c78dd3187ad8f0a82d30c83454fe58bef37 WHIRLPOOL 7b2f4be58f1f9190dee40df99218188d1160a36e9dc78399af692d7cf322a9157bc617e3adc9f30e0f6d758a9d2ee837d8d037c2d31d532212338e42ffc42480
+MISC ChangeLog 2983 SHA256 39bd929a0f5ec955342bc5daaf80b8a71a38d7db72005eb6f99d2e8378831372 SHA512 addd20a494c258d9f797ec10c4e9190091f8eb75bd038e765423ecde79a8e70320c316002c12a2f0dcfb88824bc8352167a1ae4c6c4a83ff55bd78b3a0fa1cb1 WHIRLPOOL b492d02689ecda539a6051c04b87a3cfc30e1608f7dcdf0f3738628754f157162c23b2f4415ae9b8bf7e9d58022d73f15ebc31b8d06a4fb48297b9c67cd48e2a
+MISC ChangeLog-2015 9891 SHA256 1dba523aa0d2853a582f1619aee32dbd7d5444093f2716c43567dc3d67eacb40 SHA512 6bb513845fb4f0d54361925c370c7f555bda3664d6d879d3ece49c1d2f8dc10fbc7e833b0f216de42b08a8152a8462563fb03c48c16e5656e8b692a75bf7cff8 WHIRLPOOL 91305ba08daf7571c5ffd2e45b87f0beaa8568c238fc4381c0e12675b91bb75f288940e4264722eb8a3f4f2703b16fd98c21b5eaa07f9943c85189261d241eb6
+MISC metadata.xml 433 SHA256 e594c52176dd96d82fabe0b801c41291eb0be19d7a47c7b0be94522d8435216c SHA512 df66083874796cbeaa39519bb61c871aab7581c777321eba2b37de89968fcdce685b023729d785dff99e33ce81f64345d2cf7757deffa5d2dd563d0de1b92c9a WHIRLPOOL 6c7603a70323b6b9536ac9d1faf413d78ee265f6f9c044b080e40f5d81f176d5b0f334514c55e1c5169a3bd1f38979807f1bcafd155f14c1f7898dd22fb5d4ef
diff --git a/sys-devel/icecream/files/0.9.6-crosscompile.patch b/sys-devel/icecream/files/0.9.6-crosscompile.patch
new file mode 100644
index 000000000000..990072bbb8fd
--- /dev/null
+++ b/sys-devel/icecream/files/0.9.6-crosscompile.patch
@@ -0,0 +1,12 @@
+diff -urN icecc-0.9.6.old//client/icecc-create-env icecc-0.9.6//client/icecc-create-env
+--- icecc-0.9.6.old//client/icecc-create-env 2010-09-18 12:10:08.143391700 +0200
++++ icecc-0.9.6//client/icecc-create-env 2010-09-18 12:10:46.574391700 +0200
+@@ -97,7 +97,7 @@
+
+ add_file $added_gcc /usr/bin/gcc
+ add_file $added_gxx /usr/bin/g++
+-add_file /usr/bin/as
++add_file `$added_gcc -print-prog-name=as` /usr/bin/as
+
+ if test "$is_darwin" = 1; then
+ # add dynamic linker
diff --git a/sys-devel/icecream/files/0.9.6-symlinks.patch b/sys-devel/icecream/files/0.9.6-symlinks.patch
new file mode 100644
index 000000000000..279ee0cc0f99
--- /dev/null
+++ b/sys-devel/icecream/files/0.9.6-symlinks.patch
@@ -0,0 +1,19 @@
+diff -urN icecc-0.9.6//client/Makefile.am icecc-0.9.6.new//client/Makefile.am
+--- icecc-0.9.6//client/Makefile.am 2010-09-11 13:43:53.922000148 +0200
++++ icecc-0.9.6.new//client/Makefile.am 2010-09-11 13:44:39.950000148 +0200
+@@ -7,15 +7,3 @@
+ noinst_HEADERS = client.h md5.h util.h
+
+ EXTRA_DIST = icecc-create-env
+-
+-install-exec-local:
+- $(mkinstalldirs) $(DESTDIR)$(bindir)
+- for link in g++ gcc c++ cc icerun; do \
+- rm -f $(DESTDIR)$(bindir)/$$link ;\
+- $(LN_S) icecc $(DESTDIR)$(bindir)/$$link ;\
+- done
+-
+-uninstall-local:
+- for link in g++ gcc c++ cc; do \
+- rm $(DESTDIR)$(bindir)/$$link ;\
+- done
diff --git a/sys-devel/icecream/files/0.9.7-automake.patch b/sys-devel/icecream/files/0.9.7-automake.patch
new file mode 100644
index 000000000000..6905a2a34158
--- /dev/null
+++ b/sys-devel/icecream/files/0.9.7-automake.patch
@@ -0,0 +1,32 @@
+Backport upstream patch to fix automake-1.12 issues
+
+https://bugs.gentoo.org/show_bug.cgi?id=397715
+https://bugs.gentoo.org/show_bug.cgi?id=399259
+--- client/Makefile.am
++++ client/Makefile.am
+@@ -1,10 +1,11 @@
+ INCLUDES = -I$(srcdir)/../services
+
+ bin_PROGRAMS = icecc
+-pkglib_SCRIPTS = icecc-create-env
++pkglibexec_SCRIPTS = icecc-create-env
+ icecc_SOURCES = main.cpp arg.cpp cpp.cpp local.cpp remote.cpp util.cpp md5.c safeguard.cpp
+ icecc_LDADD = ../services/libicecc.la $(LIBRSYNC)
+ noinst_HEADERS = client.h md5.h util.h
++AM_CPPFLAGS = -DPLIBDIR=\"$(pkglibexecdir)\"
+
+ EXTRA_DIST = icecc-create-env
+
+--- configure.in
++++ configure.in
+@@ -246,10 +246,6 @@
+ KDE_EXPAND_MAKEVAR(mybindir, bindir)
+ AC_DEFINE_UNQUOTED(BINDIR, "$mybindir", [Where to look for icecc])
+
+-myopkglibdir='${libdir}/'"$PACKAGE"
+-KDE_EXPAND_MAKEVAR(mypkglibdir, myopkglibdir)
+-AC_DEFINE_UNQUOTED(PLIBDIR, "$mypkglibdir", [Where to look for icecc-create-env])
+-
+ myorundir='${localstatedir}/run'
+ KDE_EXPAND_MAKEVAR(myrundir, myorundir)
+ AC_DEFINE_UNQUOTED(RUNDIR, "$myrundir", [Where to place pid files])
diff --git a/sys-devel/icecream/files/0.9.7-glibc2.16.patch b/sys-devel/icecream/files/0.9.7-glibc2.16.patch
new file mode 100644
index 000000000000..7ccbd735a46f
--- /dev/null
+++ b/sys-devel/icecream/files/0.9.7-glibc2.16.patch
@@ -0,0 +1,16 @@
+Fix building with glibc-2.16
+
+https://bugs.gentoo.org/show_bug.cgi?id=425248
+
+Patch written by Kacper Kowalik <xarthisius@gentoo.org>
+--- a/daemon/workit.cpp
++++ b/daemon/workit.cpp
+@@ -26,6 +26,7 @@
+ #include "exitcode.h"
+ #include "logging.h"
+ #include <sys/select.h>
++#include <sys/resource.h>
+ #include <algorithm>
+
+ #ifdef __FreeBSD__
+
diff --git a/sys-devel/icecream/files/icecream b/sys-devel/icecream/files/icecream
new file mode 100644
index 000000000000..db24c4046c7b
--- /dev/null
+++ b/sys-devel/icecream/files/icecream
@@ -0,0 +1,43 @@
+#!/sbin/openrc-run
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+depend() {
+ need net
+}
+
+start() {
+ local basedir=${ICECREAM_BASEDIR:-"/var/cache/icecream"}
+ local netname=${ICECREAM_NETNAME:+"-n ${ICECREAM_NETNAME}"}
+ local logfile=${ICECREAM_LOG_FILE:+"-l ${ICECREAM_LOG_FILE}"}
+ local nice=${ICECREAM_NICE_LEVEL:+"--nice ${ICECREAM_NICE_LEVEL}"}
+ local scheduler=${ICECREAM_SCHEDULER_HOST:+"-s ${ICECREAM_SCHEDULER_HOST}"}
+ local maxjobs=${ICECREAM_MAX_JOBS:+"-m ${ICECREAM_MAX_JOBS}"}
+ local verbosity=${ICECREAM_VERBOSITY:-"-v"}
+
+ if [[ "${ICECREAM_RUN_SCHEDULER}" == "yes" ]]; then
+ local slogfile=${ICECREAM_SCHEDULER_LOG_FILE:-"/var/log/icecc_scheduler"}
+ touch ${slogfile} && chown icecream:icecream ${slogfile}
+ slogfile=${slogfile:+"-l ${slogfile}"}
+ ebegin "Starting Distributed Compiler Scheduler"
+ start-stop-daemon -u icecream --start --quiet --exec /usr/sbin/scheduler -- -d ${slogfile} ${netname} ${verbosity}
+ eend ${?}
+ fi
+
+ [[ ! -d ${basedir} ]] && mkdir -p ${basedir} && chown icecream:icecream ${basedir}
+ ebegin "Starting Distributed Compiler Daemon"
+ start-stop-daemon --start --quiet --exec /usr/sbin/iceccd -- -d ${logfile} ${nice} ${scheduler} ${netname} -u icecream -b "${basedir}" ${maxjobs} ${verbosity}
+ eend ${?}
+}
+
+stop() {
+ ebegin "Stopping Distributed Compiler Daemon"
+ start-stop-daemon --stop --quiet --name iceccd
+ eend ${?}
+
+ if [[ "${ICECREAM_RUN_SCHEDULER}" == "yes" ]]; then
+ ebegin "Stopping Distributed Compiler Scheduler"
+ start-stop-daemon --stop --quiet --name scheduler
+ eend ${?}
+ fi
+}
diff --git a/sys-devel/icecream/files/icecream-1.0.0-libcap-ng.patch b/sys-devel/icecream/files/icecream-1.0.0-libcap-ng.patch
new file mode 100644
index 000000000000..3dc0e3713b0a
--- /dev/null
+++ b/sys-devel/icecream/files/icecream-1.0.0-libcap-ng.patch
@@ -0,0 +1,8 @@
+--- a/services/icecc.pc.in
++++ b/services/icecc.pc.in
+@@ -11,4 +11,5 @@ Version: @VERSION@
+ Requires:
+ Conflicts:
+ Libs: -L${libdir} -licecc
++Libs.private: @CAPNG_LDADD@
+ Cflags: -I${includedir}
diff --git a/sys-devel/icecream/files/icecream-conf.d-verbosity.patch b/sys-devel/icecream/files/icecream-conf.d-verbosity.patch
new file mode 100644
index 000000000000..1ee93c5741a2
--- /dev/null
+++ b/sys-devel/icecream/files/icecream-conf.d-verbosity.patch
@@ -0,0 +1,18 @@
+--- a/suse/sysconfig.icecream
++++ b/suse/sysconfig.icecream
+@@ -39,6 +39,15 @@
+ #
+ ## Type: string
+ ## Path: Applications/icecream
++## Default: -v
++#
++# icecream's level of verbosity ([-v[v[v]]])
++#
++ICECREAM_VERBOSITY="-v"
++
++#
++## Type: string
++## Path: Applications/icecream
+ ## Defaut: ""
+ #
+ # Identification for the network the scheduler and daemon run on.
diff --git a/sys-devel/icecream/files/icecream-config b/sys-devel/icecream/files/icecream-config
new file mode 100644
index 000000000000..6ed24c743772
--- /dev/null
+++ b/sys-devel/icecream/files/icecream-config
@@ -0,0 +1,69 @@
+#!/bin/sh
+#
+# icecream-config - helper script for icecream and its ebuild
+#
+# Copyright 2003-2010 Superlucidity Services, LLC
+# This program licensed under the GNU GPL version 2.
+#
+# This script developed by Zachary T Welch at Superlucidity Services, LLC
+# it was cloned from the distcc-config script to make ccache-config
+# and then modified by Marcus Furlong to configure icecream too.
+#
+# Additional features to come; this provides a starting point
+
+# this should be getopt'd someday (override with ICEC_QUIET=1)
+ICECC_VERBOSE=1
+
+icecc_echo() {
+ [ -z "${ICECC_QUIET}" -a -n "${ICECC_VERBOSE}" ] && echo "$*"
+}
+
+###
+# the following functions manage the icecream symlinks
+# they allow the user or other scripts (namely gcc-config) to
+# automatically update icecream's links when upgrading toolchains
+#
+icecc_remove_link() {
+ local t="/usr/lib/icecc/bin/${1}"
+ if [ -L ${t} ]; then
+ icecc_echo "Removing ${t}..."
+ rm -f "${t}"
+ fi
+}
+icecc_install_link() {
+ # Search the PATH for the specified compiler
+ # then create shadow link in /usr/lib/icecc/bin to icecc
+
+ if [ -n "$(type -p ${1})" ]; then
+ # first be sure any old link is removed
+ ICECC_QUIET=1 icecc_remove_link "${1}"
+
+ # then create the new link
+ local t="/usr/lib/icecc/bin/${1}"
+ icecc_echo "Creating icecream shadow link: ${t}..."
+ ln -s /usr/bin/icecc "${t}"
+ fi
+}
+icecc_links() {
+ local a
+ for a in gcc cc c++ g++ ; do
+ [ -n "${2}" ] && a="${2}-${a}"
+ eval "icecc_${1}_link" "${a}"
+ done
+}
+
+###
+# main routine
+
+case "${1}" in
+ --install-links )
+ icecc_links install "${2}"
+ ;;
+ --remove-links )
+ icecc_links remove "${2}"
+ ;;
+ * )
+ echo "usage: ${0} {--install-links|--remove-links} [ CHOST ]"
+ ;;
+esac
+
diff --git a/sys-devel/icecream/files/icecream-create-env b/sys-devel/icecream/files/icecream-create-env
new file mode 100644
index 000000000000..dafdc13b4331
--- /dev/null
+++ b/sys-devel/icecream/files/icecream-create-env
@@ -0,0 +1,82 @@
+#!/bin/sh
+#
+# icecream-create-env - helper script to create icecc environments(mostly for cross-compiling)
+#
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+#
+# Please note, this script has been designed to work with Gentoo's crossdev, it may or may
+# not work with cross-toolchains that were build differently.
+#
+#
+# Usage: "./icecream-create-env" creates a native environment(similar to icecc --build-native)
+# "./icecream-create-env prefix" creates a cross-compile environment using the cross-toolchain created by crossdev
+# Example:
+# "emerge crossdev && crossdev -t sparc-unknown-linux-gnu && icecream-create-env sparc-unknown-linux"
+
+if [ `id -u` -ne 0 ]
+then
+ echo "Only the superuser can execute this script."
+ exit 1
+fi
+
+# param 1 = CHOST
+prefix="${1}"
+
+if [ -z "${prefix}" ]
+then
+ prefix="`gcc -dumpmachine`"
+fi
+
+gccbin=`which ${prefix}-gcc 2>/dev/null`
+if [ ! -e "${gccbin}" ]
+then
+ echo "Can't find ${prefix}-gcc!"
+ exit 1
+fi
+
+gxxbin=`which ${prefix}-g++ 2>/dev/null`
+if [ ! -e "${gxxbin}" ]
+then
+ echo "Can't find ${prefix}-g++!"
+ exit 2
+fi
+
+version="`${prefix}-gcc -dumpversion`"
+
+tmpdir=`mktemp -d`
+tmpfile=`mktemp`
+
+target=`gcc -dumpmachine`
+if [ "x${target}" = "x${prefix}" ]
+then
+ /usr/libexec/icecc/icecc-create-env \
+ /usr/${prefix}/gcc-bin/${version}/gcc \
+ /usr/${prefix}/gcc-bin/${version}/g++ \
+ | tee ${tmpfile}
+else
+ /usr/libexec/icecc/icecc-create-env \
+ /usr/${target}/${prefix}/gcc-bin/${version}/${prefix}-gcc \
+ /usr/${target}/${prefix}/gcc-bin/${version}/${prefix}-g++ \
+ | tee ${tmpfile}
+fi
+
+# figure out the name of the archive
+icecc_envname=`grep "creating" ${tmpfile} | awk '{print $2}'`
+
+echo "Testing icecc environment..."
+tar -x -z -f ${icecc_envname} -C ${tmpdir}
+touch ${tmpdir}/empty.c
+chroot ${tmpdir}/ /usr/bin/gcc -c /empty.c
+tested=${?}
+rm ${tmpdir}/empty.c
+
+if [ "${tested}" -ne 0 ]
+then
+ echo ""
+ echo "Creating icecc environment failed. Please see error message(s) above! The temporary directory is: ${tmpdir}/"
+else
+ echo ""
+ echo "Icecc environment has been created. It has been saved as ${icecc_envname}!"
+fi
+
diff --git a/sys-devel/icecream/files/icecream-gentoo-multilib.patch b/sys-devel/icecream/files/icecream-gentoo-multilib.patch
new file mode 100644
index 000000000000..94c6a41b3af6
--- /dev/null
+++ b/sys-devel/icecream/files/icecream-gentoo-multilib.patch
@@ -0,0 +1,59 @@
+Index: services/job.h
+===================================================================
+--- services/job.h (revision 843731)
++++ services/job.h (working copy)
+@@ -57,6 +57,10 @@
+
+ unsigned int argumentFlags() const;
+
++ const ArgumentsList getFlags() {
++ return m_flags;
++ }
++
+ void setFlags( const ArgumentsList &flags ) {
+ m_flags = flags;
+ }
+Index: client/main.cpp
+===================================================================
+--- client/main.cpp (revision 843731)
++++ client/main.cpp (working copy)
+@@ -218,6 +218,39 @@
+
+ local |= analyse_argv( argv, job );
+
++ /* honour Gentoo's ${CFLAGS_${ABI}} environment variable */
++ if (getenv("ABI") != NULL) {
++ char* envar = (char*) malloc(sizeof(char) *
++ (strlen("CFLAGS_") + strlen(getenv("ABI")) + 1));
++
++ if (!envar)
++ return 1;
++
++ /* We use CFLAGS_${ABI} for gcc, g++, g77, etc as they are
++ * the same no matter which compiler we are using.
++ */
++ sprintf(envar, "CFLAGS_%s", getenv("ABI"));
++
++ if (getenv(envar)) {
++ ArgumentsList args = job.getFlags();
++
++ char* pch = strtok(getenv(envar)," \t");
++ while (pch != NULL) {
++ #if CLIENT_DEBUG
++ log_info() << "adding CFLAG '" << pch << "' as specified in environment variable ${CFLAGS_${ABI}}" << endl;
++ #endif
++ args.append(pch, Arg_Remote);
++ pch = strtok(NULL, " \t");
++ }
++
++ job.setFlags(args);
++
++ free(pch);
++ }
++
++ free(envar);
++ }
++
+ /* if ICECC is set to no, then run job locally */
+ char* icecc = getenv("ICECC");
+ if ( icecc && !strcasecmp(icecc, "no") )
diff --git a/sys-devel/icecream/files/icecream-r2 b/sys-devel/icecream/files/icecream-r2
new file mode 100644
index 000000000000..21cfddeda8c3
--- /dev/null
+++ b/sys-devel/icecream/files/icecream-r2
@@ -0,0 +1,44 @@
+#!/sbin/openrc-run
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+depend() {
+ need net
+}
+
+start() {
+ local basedir=${ICECREAM_BASEDIR:-"/var/cache/icecream"}
+ local netname=${ICECREAM_NETNAME:+"-n ${ICECREAM_NETNAME}"}
+ local logfile=${ICECREAM_LOG_FILE:+"-l ${ICECREAM_LOG_FILE}"}
+ local nice=${ICECREAM_NICE_LEVEL:+"--nice ${ICECREAM_NICE_LEVEL}"}
+ local scheduler=${ICECREAM_SCHEDULER_HOST:+"-s ${ICECREAM_SCHEDULER_HOST}"}
+ local maxjobs=${ICECREAM_MAX_JOBS:+"-m ${ICECREAM_MAX_JOBS}"}
+ local verbosity=${ICECREAM_VERBOSITY:-"-v"}
+
+ [[ ! -d /var/log/icecream/ ]] && mkdir -p /var/log/icecream/ && chown icecream:icecream /var/log/icecream/
+ if [[ "${ICECREAM_RUN_SCHEDULER}" == "yes" ]]; then
+ local slogfile=${ICECREAM_SCHEDULER_LOG_FILE:-"/var/log/icecc_scheduler"}
+ touch ${slogfile} && chown icecream:icecream ${slogfile}
+ slogfile=${slogfile:+"-l ${slogfile}"}
+ ebegin "Starting Distributed Compiler Scheduler"
+ start-stop-daemon -u icecream --start --quiet --exec /usr/sbin/icecc-scheduler -- -d ${slogfile} ${netname} ${verbosity}
+ eend ${?}
+ fi
+
+ [[ ! -d ${basedir} ]] && mkdir -p ${basedir} && chown icecream:icecream ${basedir}
+ ebegin "Starting Distributed Compiler Daemon"
+ start-stop-daemon --start --quiet --exec /usr/sbin/iceccd -- -d ${logfile} ${nice} ${scheduler} ${netname} -u icecream -b "${basedir}" ${maxjobs} ${verbosity}
+ eend ${?}
+}
+
+stop() {
+ ebegin "Stopping Distributed Compiler Daemon"
+ start-stop-daemon --stop --quiet --name iceccd
+ eend ${?}
+
+ if [[ "${ICECREAM_RUN_SCHEDULER}" == "yes" ]]; then
+ ebegin "Stopping Distributed Compiler Scheduler"
+ start-stop-daemon --stop --quiet --name icecc-scheduler
+ eend ${?}
+ fi
+}
diff --git a/sys-devel/icecream/icecream-0.9.7-r1.ebuild b/sys-devel/icecream/icecream-0.9.7-r1.ebuild
new file mode 100644
index 000000000000..03105d9b5c31
--- /dev/null
+++ b/sys-devel/icecream/icecream-0.9.7-r1.ebuild
@@ -0,0 +1,86 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=4
+
+inherit autotools base user
+
+MY_P=icecc-${PV}
+
+DESCRIPTION="icecc is a program for distributed compiling of C(++) code across several machines; based on distcc"
+HOMEPAGE="http://en.opensuse.org/Icecream"
+SRC_URI="ftp://ftp.suse.com/pub/projects/${PN}/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~hppa ~ppc ~sparc ~x86"
+IUSE=""
+
+S=${WORKDIR}/${MY_P}
+
+PATCHES=(
+ "${FILESDIR}/0.9.6-symlinks.patch"
+ "${FILESDIR}/0.9.6-crosscompile.patch"
+ "${FILESDIR}/${PV}-automake.patch"
+ "${FILESDIR}/${PV}-glibc2.16.patch"
+ "${FILESDIR}/${PN}-conf.d-verbosity.patch"
+ "${FILESDIR}/${PN}-gentoo-multilib.patch"
+)
+
+pkg_setup() {
+ enewgroup icecream
+ enewuser icecream -1 -1 /var/cache/icecream icecream
+}
+
+src_prepare() {
+ base_src_prepare
+ sed -i -e "s/Defaut/Default/g" suse/sysconfig.icecream || die #275761
+ eautoreconf
+}
+
+src_install() {
+ default
+
+ dosbin "${FILESDIR}"/icecream-config
+ dosbin "${FILESDIR}"/icecream-create-env
+
+ newconfd suse/sysconfig.icecream icecream
+ doinitd "${FILESDIR}"/icecream
+
+ diropts -m0755
+ keepdir /usr/lib/icecc/bin
+}
+
+pkg_postinst() {
+ ebegin "Scanning for compiler front-ends..."
+ /usr/sbin/icecream-config --install-links
+ /usr/sbin/icecream-config --install-links "${CHOST}"
+ eend ${?}
+
+ elog
+ elog "If you have compiled binutils/gcc/glibc with processor-specific flags"
+ elog "(as normal using Gentoo), there is a greater chance that your compiler"
+ elog "won't work on other machines. The best would be to build gcc, glibc and"
+ elog "binutils without those flags and then copy the needed files into your"
+ elog "tarball for distribution to other machines. This tarball can be created"
+ elog "by running /usr/bin/icecc --build-native, and used by setting"
+ elog "ICECC_VERSION in /etc/conf.d/icecream"
+ elog ' ICECC_VERSION=<filename_of_archive_containing_your_environment>'
+ elog
+ elog "To use icecream with portage add the following line to /etc/portage/make.conf"
+ elog ' PREROOTPATH=/usr/lib/icecc/bin'
+ elog
+ elog "To use icecream with normal make use (e.g. in /etc/profile)"
+ elog ' PATH=/usr/lib/icecc/bin:$PATH'
+ elog
+ elog "N.B. To use icecream with ccache, the ccache PATH should come first:"
+ elog ' PATH=/usr/lib/ccache/bin:/usr/lib/icecc/bin:$PATH'
+ elog
+ elog "Don't forget to open the following ports in your firewall(s):"
+ elog " TCP/10245 on the daemon computers (required)"
+ elog " TCP/8765 for the the scheduler computer (required)"
+ elog " TCP/8766 for the telnet interface to the scheduler (optional)"
+ elog " UDP/8765 for broadcast to find the scheduler (optional)"
+ elog
+ elog "Further usage instructions: ${HOMEPAGE}"
+}
diff --git a/sys-devel/icecream/icecream-1.0.0-r1.ebuild b/sys-devel/icecream/icecream-1.0.0-r1.ebuild
new file mode 100644
index 000000000000..e43d004caa23
--- /dev/null
+++ b/sys-devel/icecream/icecream-1.0.0-r1.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+MY_P="${P/icecream/icecc}"
+
+inherit base eutils user
+
+DESCRIPTION="icecc is a program for distributed compiling of C(++) code across several machines; based on distcc"
+HOMEPAGE="https://github.com/icecc/icecream"
+SRC_URI="ftp://ftp.suse.com/pub/projects/${PN}/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~hppa ~ppc ~sparc ~x86"
+IUSE=""
+
+RDEPEND="
+ sys-libs/libcap-ng
+"
+DEPEND="${RDEPEND}"
+
+S="${WORKDIR}/${MY_P}"
+
+PATCHES=(
+ "${FILESDIR}/${P}-libcap-ng.patch"
+)
+
+pkg_setup() {
+ enewgroup icecream
+ enewuser icecream -1 -1 /var/cache/icecream icecream
+}
+
+src_configure() {
+ econf \
+ --enable-shared --disable-static \
+ --enable-clang-wrappers \
+ --enable-clang-rewrite-includes
+}
+
+src_install() {
+ default
+ prune_libtool_files --all
+
+ newconfd suse/sysconfig.icecream icecream
+ newinitd "${FILESDIR}"/icecream-r2 icecream
+
+ insinto /etc/logrotate.d
+ newins suse/logrotate icecream
+}
diff --git a/sys-devel/icecream/icecream-1.0.0-r2.ebuild b/sys-devel/icecream/icecream-1.0.0-r2.ebuild
new file mode 100644
index 000000000000..ead3cbfcfa51
--- /dev/null
+++ b/sys-devel/icecream/icecream-1.0.0-r2.ebuild
@@ -0,0 +1,69 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+MY_P="${P/icecream/icecc}"
+
+inherit user
+
+DESCRIPTION="icecc is a program for distributed compiling of C(++) code across several machines; based on distcc"
+HOMEPAGE="https://github.com/icecc/icecream"
+SRC_URI="ftp://ftp.suse.com/pub/projects/${PN}/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND="
+ sys-libs/libcap-ng
+"
+RDEPEND="
+ ${DEPEND}
+ dev-util/shadowman
+"
+
+S="${WORKDIR}/${MY_P}"
+
+PATCHES=(
+ "${FILESDIR}/${P}-libcap-ng.patch"
+)
+
+pkg_setup() {
+ enewgroup icecream
+ enewuser icecream -1 -1 /var/cache/icecream icecream
+}
+
+src_configure() {
+ econf \
+ --enable-shared --disable-static \
+ --enable-clang-wrappers \
+ --enable-clang-rewrite-includes
+}
+
+src_install() {
+ default
+ find "${D}" -name '*.la' -delete || die
+
+ newconfd suse/sysconfig.icecream icecream
+ newinitd "${FILESDIR}"/icecream-r2 icecream
+
+ insinto /etc/logrotate.d
+ newins suse/logrotate icecream
+
+ insinto /usr/share/shadowman/tools
+ newins - icecc <<<'/usr/libexec/icecc/bin'
+}
+
+pkg_prerm() {
+ if [[ -z ${REPLACED_BY_VERSION} && ${ROOT} == / ]]; then
+ eselect compiler-shadow remove icecc
+ fi
+}
+
+pkg_postinst() {
+ if [[ ${ROOT} == / ]]; then
+ eselect compiler-shadow update icecc
+ fi
+}
diff --git a/sys-devel/icecream/metadata.xml b/sys-devel/icecream/metadata.xml
new file mode 100644
index 000000000000..55acc851705c
--- /dev/null
+++ b/sys-devel/icecream/metadata.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>cluster@gentoo.org</email>
+ <name>Gentoo Cluster Project</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>suse@gentoo.org</email>
+ <name>SUSE</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">icecc/icecream</remote-id>
+ </upstream>
+</pkgmetadata>