2023-08-18 21:13:57 +02:00
|
|
|
# Description: A tool to distribute compilations
|
2021-03-08 16:24:44 +11:00
|
|
|
# URL: https://github.com/distcc/distcc
|
2023-08-18 21:13:57 +02:00
|
|
|
# Maintainer: Tim Biermann, tbier at posteo dot de
|
|
|
|
# Optional: avahi gtk3 krb5 popt
|
2007-04-11 05:56:44 +10:00
|
|
|
|
|
|
|
name=distcc
|
2021-05-16 17:17:30 +10:00
|
|
|
version=3.4
|
2023-08-18 21:13:57 +02:00
|
|
|
release=4
|
2019-08-19 23:29:14 +10:00
|
|
|
source=(https://github.com/distcc/distcc/releases/download/v$version/$name-$version.tar.gz
|
2023-08-18 21:13:57 +02:00
|
|
|
python-3.9.patch
|
|
|
|
distccd.service
|
|
|
|
distccd.conf)
|
2007-04-11 05:56:44 +10:00
|
|
|
|
|
|
|
build() {
|
2023-08-18 21:13:57 +02:00
|
|
|
cd $name-$version
|
2016-06-12 16:03:48 +10:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
patch -Np1 -i $SRC/python-3.9.patch
|
2020-07-15 23:29:49 +10:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
prt-get isinst avahi && PKGMK_DISTCC+=' --with-avahi'
|
|
|
|
prt-get isinst gtk3 || PKGMK_DISTCC+=' --without-gtk'
|
|
|
|
prt-get isinst krb5 && PKGMK_DISTCC+=' --with-auth'
|
|
|
|
prt-get isinst popt || PKGMK_DISTCC+=' --with-included-popt'
|
2007-07-31 21:39:17 +10:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
export CFLAGS+=' -fno-strict-aliasing'
|
|
|
|
export CPPFLAGS="$CFLAGS"
|
2022-02-28 15:27:20 +01:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
./autogen.sh
|
2007-04-11 05:56:44 +10:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
./configure ${PKGMK_DISTCC} \
|
|
|
|
--prefix=/usr \
|
|
|
|
--sysconfdir=/etc \
|
|
|
|
--runstatedir=/run \
|
|
|
|
--enable-rfc2553 \
|
|
|
|
--without-gnome \
|
|
|
|
--disable-Werror
|
2009-01-09 19:04:37 +11:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
make INCLUDESERVER_PYTHON=/usr/bin/python3
|
|
|
|
make DESTDIR=$PKG \
|
|
|
|
INCLUDESERVER_PYTHON=/usr/bin/python3 \
|
|
|
|
GZIP_BIN=false \
|
|
|
|
install
|
2009-01-09 19:04:37 +11:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
# distccd should be in sbin
|
|
|
|
mv $PKG/usr/bin/distccd $PKG/usr/sbin/distccd
|
2008-05-16 21:57:46 +10:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
# install service
|
|
|
|
install -m 0755 -D $SRC/distccd.service $PKG/etc/rc.d/distccd
|
2013-04-28 13:17:34 +10:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
# create the masquerade directory
|
|
|
|
install -d $PKG/usr/lib/distcc
|
|
|
|
cd $PKG/usr/lib/distcc
|
|
|
|
for c in cc c++ gcc g++ cpp; do
|
|
|
|
ln -s ../../bin/distcc $c
|
|
|
|
done
|
|
|
|
cd -
|
2021-03-08 16:24:44 +11:00
|
|
|
|
2023-08-18 21:13:57 +02:00
|
|
|
# install config file
|
|
|
|
install -D -m 0644 $SRC/distccd.conf $PKG/etc/distccd.conf
|
|
|
|
|
|
|
|
# cleanup
|
|
|
|
rm -r $PKG/usr/share/doc $PKG/etc/distcc $PKG/etc/default
|
|
|
|
rm $PKG/usr/sbin/update-distcc-symlinks
|
|
|
|
|
|
|
|
/usr/bin/python3 -m compileall -d $SRC/$name-$version $PKG
|
|
|
|
/usr/bin/python3 -O -m compileall -d $SRC/$name-$version $PKG
|
|
|
|
/usr/bin/python3 -OO -m compileall -d $SRC/$name-$version $PKG
|
2007-04-11 05:56:44 +10:00
|
|
|
}
|