Compare commits

...
Sign in to create a new pull request.

5 commits

Author SHA1 Message Date
Fedora Release Engineering
d264479995 dist-git conversion 2010-07-28 13:03:45 +00:00
Bill Nottingham
c065160676 Fix typo that causes a failure to update the common directory. (releng
#2781)
2009-11-26 01:23:13 +00:00
Denis Leroy
83f226522c Avahi patch initial checkin 2008-03-10 09:43:07 +00:00
Denis Leroy
dd8addea78 Initial import 2008-03-10 09:38:48 +00:00
Kevin Fenzi
c8c698a694 Initialize branch F-8 for distcc 2008-03-07 21:44:23 +00:00
8 changed files with 12353 additions and 21 deletions

View file

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
distcc-2.18.3.tar.bz2

View file

@ -1,21 +0,0 @@
# Makefile for source rpm: distcc
# $Id$
NAME := distcc
SPECFILE = $(firstword $(wildcard *.spec))
define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef
MAKEFILE_COMMON := $(shell $(find-makefile-common))
ifeq ($(MAKEFILE_COMMON),)
# attept a checkout
define checkout-makefile-common
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
endif
include $(MAKEFILE_COMMON)

12103
distcc-2.18.3-avahi.patch Normal file

File diff suppressed because it is too large Load diff

126
distcc.spec Normal file
View file

@ -0,0 +1,126 @@
Name: distcc
Version: 2.18.3
Release: 4%{?dist}
Summary: Distributed C/C++ compilation
Group: Development/Tools
License: GPLv2+
URL: http://distcc.samba.org/
Source0: http://distcc.samba.org/ftp/distcc/distcc-%{version}.tar.bz2
Source1: hosts.sample
Source2: distccd.init
Patch0: distcc-2.18.3-avahi.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: popt-devel
BuildRequires: libgnomeui-devel
BuildRequires: pango-devel
BuildRequires: python
BuildRequires: desktop-file-utils
BuildRequires: avahi-devel
%description
distcc is a program to distribute compilation of C or C++ code across
several machines on a network. distcc should always generate the same
results as a local compile, is simple to install and use, and is often
two or more times faster than a local compile.
%package server
Summary: Server for distributed C/C++ compilation
Group: Development/Tools
License: GPLv2+
Requires(post): /sbin/chkconfig
Requires(preun): /sbin/chkconfig
%description server
This package contains the compilation server needed to use %{name}.
%prep
%setup -q
%patch0 -p1 -b .avahi
%build
%configure --with-gnome --with-docdir=%{_datadir}/doc/%{name}-%{version}
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
# Move desktop file to right directory
mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications
mv $RPM_BUILD_ROOT%{_datadir}/%{name}/*.desktop $RPM_BUILD_ROOT%{_datadir}/applications/
sed -i 's@Icon=@Icon=%{_datadir}/%{name}/@' $RPM_BUILD_ROOT%{_datadir}/applications/*.desktop
# Install sample hosts file
install -Dm 0644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/hosts
# Install sample distccd config file
install -Dm 0644 contrib/redhat/sysconfig $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/distccd
# Install distccd init file
install -Dm 0755 %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/distccd
%post
update-desktop-database &> /dev/null ||:
%post server
[ $1 -lt 2 ] && /sbin/chkconfig --add distccd ||:
%preun server
[ $1 -eq 0 ] && /sbin/chkconfig --del distccd ||:
%postun
update-desktop-database &> /dev/null ||:
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc %{_datadir}/doc/%{name}-%{version}
%{_bindir}/distcc
%{_bindir}/distccmon*
%{_mandir}/man1/distcc.*
%{_mandir}/man1/distccmon*
%{_datadir}/%{name}
%{_datadir}/applications/*.desktop
%dir %{_sysconfdir}/%{name}
%config(noreplace) %{_sysconfdir}/%{name}/hosts
%files server
%defattr(-,root,root,-)
%doc COPYING README
%{_bindir}/distccd
%{_sysconfdir}/init.d/*
%{_mandir}/man1/distccd*
%config(noreplace) %{_sysconfdir}/sysconfig/distccd
%changelog
* Fri Feb 22 2008 Denis Leroy <denis@poolshark.org> - 2.18.3-4
- Added Avahi support patch from Lennart
* Tue Feb 19 2008 Denis Leroy <denis@poolshark.org> - 2.18.3-3
- LSB header for init script
* Mon Feb 18 2008 Denis Leroy <denis@poolshark.org> - 2.18.3-2
- Fixed Source0 URL, fixed init script
* Mon Feb 4 2008 Denis Leroy <denis@poolshark.org> - 2.18.3-1
- First version

111
distccd.init Normal file
View file

@ -0,0 +1,111 @@
#!/bin/sh
#
# distccd - A distributed compilation server.
#
#
# chkconfig: - 80 20
# description: distccd - distcc distributed compilation server
#
### BEGIN INIT INFO
# Provides: distccd
# Required-Start: $network $syslog $local_fs
# Required-Stop: $network $syslog $local_fs
# Default-Stop: 0 1 2 6
# Short-Description: Distributed C/C++ Compilation Server
# Description: distcc is a program to distribute compilation of C or C++
# code across several machines on a network. distcc should
# always generate the same results as a local compile, is
# simple to install and use, and is often two or more times
# faster than a local compile.
### END INIT INFO
# Source function library.
. /etc/rc.d/init.d/functions
exec="/usr/bin/distccd"
prog="distccd"
# Default variables
SYSCONFIG="/etc/sysconfig/distccd"
OPTIONS=""
USER="nobody"
DISTCCPATH="$PATH"
[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
lockfile=/var/lock/subsys/$prog
start() {
[ -x $exec ] || exit 5
[ -z "$OPTIONS" ] && exit 6
echo -n $"Starting $prog: "
DISTCCD_PATH="$DISTCCPATH" $prog --daemon --user "$USER" $OPTIONS && success || failure
retval=$?
echo
[ $retval -eq 0 ] && touch $lockfile
return $retval
}
stop() {
echo -n $"Stopping $prog: "
killproc $prog
retval=$?
echo
[ $retval -eq 0 ] && rm -f $lockfile
return $retval
}
restart() {
stop
start
}
reload() {
restart
}
force_reload() {
restart
}
rh_status() {
# run checks to determine if the service is running or use generic status
status $prog
}
rh_status_q() {
rh_status >/dev/null 2>&1
}
case "$1" in
start)
rh_status_q && exit 0
$1
;;
stop)
rh_status_q || exit 0
$1
;;
restart)
$1
;;
reload)
rh_status_q || exit 7
$1
;;
force-reload)
force_reload
;;
status)
rh_status
;;
condrestart|try-restart)
rh_status_q || exit 0
restart
;;
*)
echo $"Usage: $0 {start|stop|status|restart|try-restart|reload|force-reload}"
exit 2
esac
exit $?

11
hosts.sample Normal file
View file

@ -0,0 +1,11 @@
# The grammar of the host file is, informally:
#
# DISTCC_HOSTS = HOSTSPEC ...
# HOSTSPEC = LOCAL_HOST | SSH_HOST | TCP_HOST | OLDSTYLE_TCP_HOST
# LOCAL_HOST = localhost[/LIMIT]
# SSH_HOST = [USER]@HOSTID[/LIMIT][:COMMAND][OPTIONS]
# TCP_HOST = HOSTID[:PORT][/LIMIT][OPTIONS]
# OLDSTYLE_TCP_HOST = HOSTID[/LIMIT][:PORT][OPTIONS]
# HOSTID = HOSTNAME | IPV4
# OPTIONS = ,OPTION[OPTIONS]
# OPTION = lzo

View file

@ -0,0 +1 @@
0d6b80a1efc3a3d816c4f4175f63eaa2 distcc-2.18.3.tar.bz2