contrib/distcc/Pkgfile
2016-06-12 16:03:48 +10:00

60 lines
1.4 KiB
Plaintext

# Description: A tool to distribute compilations.
# URL: http://distcc.org/
# Maintainer: Danny Rawlins, crux at romster dot me
# Packager: Johannes Winkelmann, jw at tks6 dot net
# Optional: python
name=distcc
version=3.1
release=6
source=(https://github.com/distcc/distcc/archive/$name-$version.tar.gz
distccd
distcc-3.1-freedesktop.patch
distcc-3.1-python.patch
distcc-3.1-argc-fix.patch)
build() {
#cd $name-$version
cd distcc-distcc-3.1
./autogen.sh
patch -p 1 -i $SRC/distcc-3.1-freedesktop.patch
patch -p 1 -i $SRC/distcc-3.1-python.patch
patch -p 2 -i $SRC/distcc-3.1-argc-fix.patch
./configure \
--prefix=/usr \
--mandir=/usr/share/man \
--without-gnome \
--without-gtk \
--disable-Werror \
--with-included-popt
make
make DESTDIR=$PKG install
# distccd should be in sbin
install -d $PKG/usr/sbin
mv $PKG/usr/bin/distccd $PKG/usr/sbin/distccd
# install service
install -m 0755 -D $SRC/distccd $PKG/etc/rc.d/distccd
# 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 -
rm -rf $PKG/usr/share/doc $PKG/usr/etc/default $PKG/usr/etc/distcc
rmdir $PKG/usr/etc
# python is required for pump mode
if [ "$(prt-get isinst python)" = 'package python is not installed' ]; then
rm $PKG/usr/share/man/man1/{pump,include_server}.1
fi
}