diff options
author | jc_gargma <jc_gargma@iserlohn-fortress.net> | 2019-02-07 14:06:35 -0800 |
---|---|---|
committer | jc_gargma <jc_gargma@iserlohn-fortress.net> | 2019-02-07 14:06:35 -0800 |
commit | 45c3c601f40ccde43c904940014c836245a04120 (patch) | |
tree | f1227dd2e823f3b94e428f182140377f4821ac4b | |
download | icecream-45c3c601f40ccde43c904940014c836245a04120.tar.xz |
Initial commit
-rw-r--r-- | PKGBUILD | 58 | ||||
-rw-r--r-- | icecream-scheduler.confd | 7 | ||||
-rw-r--r-- | icecream-scheduler.initd | 12 | ||||
-rw-r--r-- | icecream.confd | 32 | ||||
-rw-r--r-- | icecream.initd | 12 | ||||
-rw-r--r-- | icecream.install | 20 | ||||
-rw-r--r-- | ld-icecream.conf | 1 |
7 files changed, 142 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..c1f8ec5 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,58 @@ +# Maintainer: jc_gargma <jc_gargma@iserlohn-fortress.net> +# Maintainer: Ben Widawsky <ben@bwidawsk.net> +# Contributor: Isaac C. Aronson <isaac@pingas.org> (original PKGBUILD) +# Contributor: Sergio Correia <sergio@correia.cc> (modifications derived from icecream-git package) + +# # I maintain this because: +# AUR version not configured for openRC +# AUR version uses excess scripts + +pkgname=icecream +pkgver=1.2 +pkgrel=9 +pkgdesc="takes compile jobs from your build and distributes it to remote machines allowing a parallel build on several machines." +url="https://en.opensuse.org/Icecream" +license=('GPL2') +makedepends=('') +depends=('bash' 'libcap-ng' 'lzo') +provides=('icecream') +optdepends=('iceberg-git: A Qt based monitor for icecream nodes' + 'ccache: ccache enabled remote builds.') +conflicts=('icecream-git') +backup=("etc/$pkgname.conf") +arch=('x86_64') +install=$pkgname.install +source=($pkgname-$pkgver.tar.gz::https://github.com/icecc/$pkgname/archive/$pkgver.tar.gz + $pkgname.initd + $pkgname.confd + $pkgname-scheduler.initd + $pkgname-scheduler.confd + ld-$pkgname.conf) +sha256sums=('12d4132e5aacf6907877b691a8ac09e3e2f704ca016c49bc5eb566fc9185f544' + '8bacb89c6975b0f7a4411e20822d53fc2850801fb5f6ac43a0650dc245604289' + 'f667651facf89f01df61700f1fb7beef88ff4f330b4c7ca1b9ba9da9cfd2c463' + 'e65b13da1be3b4475ba765fa6dae93e009908b084d9cbc93ae2c8d4f42800ace' + '2bf17cc1310b55270a39179a75a0732986986e8cf271f83e70f5e74ee701ec3c' + '2221f16c3293dfd86e4d0442745b104380a4a1623ca3c9eb6bfe5771552fac65') +build() { + cd "$srcdir/$pkgname-$pkgver" + + ./autogen.sh + ./configure --prefix=/usr/lib/$pkgname --enable-shared --disable-static --without-man + make +} + +package() { + cd "$srcdir/$pkgname-$pkgver" + + make DESTDIR="$pkgdir" install + install -D -m755 "$srcdir"/$pkgname-scheduler.initd "$pkgdir/etc/init.d/$pkgname-scheduler" + install -D -m644 "$srcdir"/$pkgname-scheduler.confd "$pkgdir/etc/conf.d/$pkgname-scheduler" + install -D -m755 "$srcdir"/$pkgname.initd "$pkgdir/etc/init.d/$pkgname" + install -D -m644 "$srcdir"/$pkgname.confd "$pkgdir/etc/conf.d/$pkgname" + install -D -m644 "$srcdir"/ld-$pkgname.conf "${pkgdir}/etc/ld.so.conf.d/$pkgname.conf" + + # moving pkg-config file to its usual place + install -D -m644 "${pkgdir}/usr/lib/$pkgname/lib/pkgconfig/icecc.pc" "${pkgdir}/usr/lib/pkgconfig/icecc.pc" + rm -rf "${pkgdir}/usr/lib/$pkgname/lib/pkgconfig" +} diff --git a/icecream-scheduler.confd b/icecream-scheduler.confd new file mode 100644 index 0000000..3836c9f --- /dev/null +++ b/icecream-scheduler.confd @@ -0,0 +1,7 @@ +# Identification for the network the scheduler and daemon run on. +NETNAME="icecream" + +# icecream scheduler log file +ICECREAM_SCHEDULER_LOG_FILE="/var/log/icecream/scheduler" + +ICECREAM_SCHEDULER_OPTS="-u icecream -n $NETNAME -l $ICECREAM_SCHEDULER_LOG_FILE" diff --git a/icecream-scheduler.initd b/icecream-scheduler.initd new file mode 100644 index 0000000..e71776a --- /dev/null +++ b/icecream-scheduler.initd @@ -0,0 +1,12 @@ +#!/usr/bin/openrc-run +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +command="/usr/lib/icecream/sbin/icecc-scheduler" +command_args="${ICECREAM_SCHEDULER_OPTS}" +pidfile="/run/${RC_SVCNAME}.pid" +start_stop_daemon_args="--background --make-pidfile" + +depend() { + use logger net +} diff --git a/icecream.confd b/icecream.confd new file mode 100644 index 0000000..16f79d9 --- /dev/null +++ b/icecream.confd @@ -0,0 +1,32 @@ +# Identification for the network the scheduler and daemon run on. +NETNAME="icecream" + +# icecream daemon log file +ICECREAM_LOG_FILE="/var/log/icecream/iceccd" + +# Nice level of running compilers +NICE="5" + +# If the daemon can't find the scheduler by broadcast (e.g. because +# of a firewall) you can specify it. +#SCHEDULER="" + +# This is the directory where the icecream daemon stores the environments +# it compiles in. In a big network this can grow quite a bit, so use some +# path if your /tmp is small - but the user icecream has to write to it. +ICECREAM_BASEDIR="/var/cache/icecream" + +# You can overwrite here the number of jobs to run in parallel. Per +# default this depends on the number of (virtual) CPUs installed. +# +# Note: a value of "0" is actually interpreted as "1", however it +# also sets ICECREAM_ALLOW_REMOTE="no". +#MAXJOBS="" + +# Specifies whether jobs submitted by other nodes are allowed to run on +# this one. +#NOREMOTE="--no-remote" + +#ICECREAM_OPTS="-u icecream -n $NETNAME -l $ICECREAM_LOG_FILE --nice $NICE -s $SCHEDULER -b ${ICECREAM_BASEDIR} ${MAXJOBS} ${NOREMOTE}" +#ICECREAM_OPTS="-u icecream -n $NETNAME -l $ICECREAM_LOG_FILE --nice $NICE -s $SCHEDULER -b ${ICECREAM_BASEDIR}" +ICECREAM_OPTS="-u icecream -n $NETNAME -l $ICECREAM_LOG_FILE --nice $NICE -b ${ICECREAM_BASEDIR}" diff --git a/icecream.initd b/icecream.initd new file mode 100644 index 0000000..1ff49e9 --- /dev/null +++ b/icecream.initd @@ -0,0 +1,12 @@ +#!/usr/bin/openrc-run +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +command="/usr/lib/icecream/sbin/iceccd" +command_args="${ICECREAM_OPTS}" +pidfile="/run/${RC_SVCNAME}.pid" +start_stop_daemon_args="--background --make-pidfile" + +depend() { + use logger net +} diff --git a/icecream.install b/icecream.install new file mode 100644 index 0000000..41da5a2 --- /dev/null +++ b/icecream.install @@ -0,0 +1,20 @@ +post_install() { + getent group icecream &>/dev/null || groupadd -r icecream >/dev/null + getent passwd icecream &>/dev/null || useradd -r -g icecream -s /bin/false \ + -c "Icecream Daemon" -d /var/cache/icecream icecream 2>/dev/null + mkdir -p /var/cache/icecream + mkdir -p /var/log/icecream + touch /var/log/icecream/scheduler + touch /var/log/icecream/iceccd + chown -R icecream:icecream /var/cache/icecream /var/log/icecream/scheduler /var/log/icecream/iceccd +} + +post_upgrade() { + post_install +} + +post_remove() { + getent passwd icecream &>/dev/null && userdel icecream >/dev/null + getent group icecream &>/dev/null && groupdel icecream >/dev/null + true +} diff --git a/ld-icecream.conf b/ld-icecream.conf new file mode 100644 index 0000000..e720df3 --- /dev/null +++ b/ld-icecream.conf @@ -0,0 +1 @@ +/usr/lib/icecream/lib |