]> git.pld-linux.org Git - packages/distcc.git/blame - distcc.spec
- build gtk based distccmon-gnome
[packages/distcc.git] / distcc.spec
CommitLineData
984594b6
ER
1# TODO
2# - unpackaged files:
984594b6
ER
3# /etc/distcc/clients.allow
4# /etc/distcc/commands.allow.sh
5# /etc/distcc/hosts
ac9e77da 6#
7# Conditional build:
216adac7
JB
8%bcond_without gtk # distccmon-gnome tool (monitor-gnome package)
9%bcond_with gnome # GNOME libraries support in distccmon-gnome (not ported to GNOME 3)
10f20dfc 10
6aad4547 11Summary: Program to distribute compilation of C or C++
363c8ff8 12Summary(pl.UTF-8): Program do rozdzielania kompilacji programów w C lub C++
6aad4547 13Name: distcc
51d7669c 14Version: 3.4
10f20dfc 15Release: 1
6aad4547 16License: GPL
e6318e62 17Group: Development/Languages
51d7669c
JR
18Source0: https://github.com/distcc/distcc/archive/v%{version}/%{name}-%{version}.tar.gz
19# Source0-md5: 00523fd05f4cd9dd968e4e0ec09d774d
6aad4547 20Source1: %{name}.inetd
953fcc0d 21Source2: %{name}.init
22Source3: %{name}.sh
23Source4: %{name}.csh
fc307e5b 24Source5: %{name}.config
9d35c6e8 25Source6: %{name}.logrotate
454bf4cb 26Patch0: %{name}-user.patch
216adac7 27Patch1: %{name}-python.patch
9c952e41 28URL: http://www.distcc.org/
216adac7 29BuildRequires: autoconf >= 2.69
6e659ed6 30BuildRequires: automake
216adac7
JB
31# libiberty
32BuildRequires: binutils-devel
33%{?with_gtk:BuildRequires: gtk+3-devel}
34%{?with_gnome:BuildRequires: libgnome-devel >= 3.0}
35%{?with_gnome:BuildRequires: libgnomeui-devel >= 3.0}
36%{?with_gnome:BuildRequires: pango-devel}
54448e74 37BuildRequires: pkgconfig
cf3c1b61 38BuildRequires: popt-devel
216adac7
JB
39BuildRequires: python3-devel >= 1:3.1
40BuildRequires: python3-devel-tools >= 1:3.1
476c7f2e 41BuildRequires: rpm-pythonprov
e6318e62 42BuildRequires: rpmbuild(macros) >= 1.268
29c8cd62 43BuildRequires: sed >= 4.0
6aad4547
AM
44BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45
46%description
47distcc is a program to distribute compilation of C or C++ code across
48several machines on a network. distcc should always generate the same
49results as a local compile, is simple to install and use, and is often
50two or more times faster than a local compile.
51
06d40241
JR
52%description -l pl.UTF-8
53distcc jest programem pozwalającym na dystrybucję kompilacji C lub C++
54na kilka maszyn w sieci. distcc powinien zawsze generować takie same
55rezultaty jak lokalna kompilacja, jest prosty w instalacji i użyciu
56oraz bardzo często dwa lub więcej razy szybszy niż lokalna kompilacja.
6aad4547 57
953fcc0d 58%package common
725fa96f 59Summary: Common files for inetd and standalone versions of distcc
363c8ff8 60Summary(pl.UTF-8): Pliki wspólne dla wersji inetd i standalone distcc
0e630aaf 61Group: Daemons
e6318e62
ER
62Requires(postun): /usr/sbin/groupdel
63Requires(postun): /usr/sbin/userdel
1f47eaf4 64Requires(pre): /bin/id
65Requires(pre): /usr/bin/getgid
66Requires(pre): /usr/sbin/groupadd
47a5d923 67Requires(pre): /usr/sbin/useradd
c1cecbca 68Suggests: gcc
69Suggests: gcc-c++
1f47eaf4 70Provides: group(distcc)
71Provides: user(distcc)
55a0572b 72Obsoletes: distcc < 2.1-2
953fcc0d 73
953fcc0d 74%description common
75distcc is a program to distribute compilation of C or C++ code across
76several machines on a network. distcc should always generate the same
77results as a local compile, is simple to install and use, and is often
78two or more times faster than a local compile.
79
06d40241
JR
80%description common -l pl.UTF-8
81distcc jest programem pozwalającym na dystrybucję kompilacji C lub C++
82na kilka maszyn w sieci. distcc powinien zawsze generować takie same
83rezultaty jak lokalna kompilacja, jest prosty w instalacji i użyciu
84oraz bardzo często dwa lub więcej razy szybszy niż lokalna kompilacja.
953fcc0d 85
9c952e41 86%package include_server
9677354d
JB
87Summary: Conservative approximation of include dependencies for C/C++
88Summary(pl.UTF-8): Konserwatywna aproksymacja zależności nagłówków dla C/C++
9c952e41
AG
89Group: Daemons
90
91%description include_server
984594b6 92include_server.py starts an include server process. This process
9c952e41
AG
93answers queries from distcc(1) clients about what files to include in
94C/C++ compilations. The include_server.py command itself terminates as
95soon as the include server has been spawned.
96
97%description include_server -l pl.UTF-8
984594b6
ER
98include_server.py wywołuje proces serwera include. Proces ten
99odpowiada na zapytania klientów distcc(1) dotyczące plików, które
100należy dołączyć na etapie kompilacji C/C++. Polecenie
101incluse_server.py kończy działanie jak tylko wywołany zostanie proces
102serwera.
9c952e41 103
953fcc0d 104%package inetd
105Summary: inetd configs for distcc
363c8ff8 106Summary(pl.UTF-8): Pliki konfiguracyjne do użycia distcc poprzez inetd
0e630aaf 107Group: Daemons
e6318e62
ER
108Requires: %{name}-common = %{version}-%{release}
109Requires: rc-inetd
55a0572b 110Obsoletes: distcc < 2.1-2
953fcc0d 111
112%description inetd
113distcc configs for running from inetd.
114
06d40241 115%description inetd -l pl.UTF-8
953fcc0d 116Pliki konfiguracyjna distcc do startowania demona poprzez inetd.
117
118%package standalone
8a419537 119Summary: Standalone daemon configs for distcc
363c8ff8 120Summary(pl.UTF-8): Pliki konfiguracyjne do startowania distcc w trybie standalone
953fcc0d 121Group: Daemons
cf89e5cf 122Requires(post,preun): /sbin/chkconfig
e6318e62
ER
123Requires: %{name}-common = %{version}-%{release}
124Requires: rc-scripts
55a0572b 125Obsoletes: distcc < 2.1-2
953fcc0d 126
127%description standalone
128distcc configs for running as a standalone daemon.
129
06d40241 130%description standalone -l pl.UTF-8
47a5d923 131Pliki konfiguracyjne distcc do startowania demona w trybie standalone.
953fcc0d 132
51fb516c 133%package monitor
1f47eaf4 134Summary: Monitor for distcc
363c8ff8 135Summary(pl.UTF-8): Monitor dla distcc
1f47eaf4 136Group: Applications
51fb516c
AM
137
138%description monitor
139Monitor for distcc.
140
06d40241 141%description monitor -l pl.UTF-8
51fb516c
AM
142Monitor dla distcc.
143
144%package monitor-gnome
1f47eaf4 145Summary: GTK+ monitor for distcc
363c8ff8 146Summary(pl.UTF-8): Monitor GTK+ dla distcc
1f47eaf4 147Group: X11/Applications
51fb516c
AM
148
149%description monitor-gnome
c8eab2f6 150GTK+ monitor for distcc.
51fb516c 151
06d40241 152%description monitor-gnome -l pl.UTF-8
c8eab2f6 153Monitor GTK+ dla distcc.
51fb516c 154
6aad4547
AM
155%prep
156%setup -q
fc00bbf7 157%patch0 -p1
216adac7 158%patch1 -p1
454bf4cb 159
10f20dfc 160%{__sed} -i -e 's#PKGDATADIR#"%{_pixmapsdir}"#g' src/mon-gnome.c
6e659ed6 161
51d7669c
JR
162%{__sed} -E -i -e '1s,#!\s*/usr/bin/env\s+python3(\s|$),#!%{__python3}\1,' \
163 update-distcc-symlinks.py
164
6e659ed6 165%build
9c952e41 166%{__aclocal}
e3949423 167%{__autoconf}
168%{__autoheader}
ac9e77da 169%configure \
c5869176 170 --enable-rfc2553 \
216adac7
JB
171 %{?with_gnome:--with-gnome} \
172 %{?with_gtk:--with-gtk}
ac9e77da 173
9c952e41 174%{__make} \
216adac7
JB
175 WERROR_CFLAGS=""
176# CC="%{__cc}"
6aad4547
AM
177
178%install
179rm -rf $RPM_BUILD_ROOT
9d35c6e8 180install -d $RPM_BUILD_ROOT/etc/{sysconfig/rc-inetd,rc.d/init.d,profile.d,logrotate.d} \
6e659ed6 181 $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},%{_var}/log}
6aad4547 182
87073c74
PG
183%{__make} install \
184 DESTDIR=$RPM_BUILD_ROOT
953fcc0d 185
10f20dfc
ER
186install -p %{SOURCE1} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/distccd
187install -p %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/distcc
188cp -p %{SOURCE3} %{SOURCE4} $RPM_BUILD_ROOT/etc/profile.d
189%{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/default/distcc
190cp -p %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/distccd
191cp -p %{SOURCE6} $RPM_BUILD_ROOT/etc/logrotate.d/distccd
6aad4547 192
5fac6119 193touch $RPM_BUILD_ROOT%{_var}/log/distcc
10f20dfc 194%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
e3949423 195
725fa96f
JB
196%clean
197rm -rf $RPM_BUILD_ROOT
198
9536ab6c 199%pre common
6e7561ad
ER
200%groupadd -P %{name}-common -g 137 distcc
201%useradd -P %{name}-common -u 137 -d /tmp -s /bin/false -c "distcc user" -g distcc distcc
607bc1af 202
9536ab6c
AM
203%postun common
204if [ "$1" = "0" ]; then
1f47eaf4 205 %userremove distcc
206 %groupremove distcc
9536ab6c
AM
207fi
208
953fcc0d 209%post inetd
e6318e62 210%service -q rc-inetd reload
6aad4547 211
953fcc0d 212%postun inetd
48f922ca
ER
213if [ "$1" = 0 ]; then
214 %service -q rc-inetd reload
215fi
6aad4547 216
953fcc0d 217%post standalone
218/sbin/chkconfig --add distcc
e6318e62 219%service distcc restart "distcc daemon"
953fcc0d 220
221%preun standalone
222if [ "$1" = "0" ]; then
e6318e62 223 %service distcc stop
a6d80f15 224 /sbin/chkconfig --del distcc
953fcc0d 225fi
226
51fb516c 227%files
6aad4547 228%defattr(644,root,root,755)
e35de25d 229%doc AUTHORS NEWS README *.txt
216adac7 230%attr(755,root,root) %{_bindir}/distcc
9c952e41
AG
231%attr(755,root,root) %{_bindir}/lsdistcc
232%attr(755,root,root) %{_bindir}/pump
51d7669c 233%attr(755,root,root) %{_sbindir}/update-distcc-symlinks
216adac7 234%{_mandir}/man1/distcc.1*
9c952e41 235%{_mandir}/man1/pump.1*
51d7669c 236%{_mandir}/man1/lsdistcc.1*
216adac7
JB
237%attr(755,root,root) /etc/profile.d/distcc.csh
238%attr(755,root,root) /etc/profile.d/distcc.sh
953fcc0d 239
51fb516c
AM
240%files common
241%defattr(644,root,root,755)
51d7669c
JR
242%dir /etc/distcc
243/etc/distcc/clients.allow
244/etc/distcc/commands.allow.sh
245/etc/distcc/hosts
47a5d923
ER
246%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/distccd
247%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/distccd
216adac7
JB
248%attr(755,root,root) %{_bindir}/distccd
249%{_mandir}/man1/distccd.1*
607bc1af 250%attr(640,distcc,root) %ghost %{_var}/log/distcc
51fb516c 251
9c952e41
AG
252%files include_server
253%defattr(644,root,root,755)
51d7669c 254%{py3_sitedir}/include_server
216adac7 255%{py3_sitedir}/include_server-%{version}-py*.egg-info
9c952e41
AG
256%{_mandir}/man1/include_server.1*
257
953fcc0d 258%files inetd
5fac6119 259%defattr(644,root,root,755)
47a5d923 260%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/distccd
953fcc0d 261
262%files standalone
5fac6119 263%defattr(644,root,root,755)
6a436b6c 264%attr(754,root,root) /etc/rc.d/init.d/distcc
51fb516c
AM
265
266%files monitor
64cd2051 267%defattr(644,root,root,755)
51fb516c 268%attr(755,root,root) %{_bindir}/distccmon-text
216adac7 269%{_mandir}/man1/distccmon-text.1*
8ec2d073 270
216adac7 271%if %{with gtk}
8ec2d073 272%files monitor-gnome
55a0572b 273%defattr(644,root,root,755)
e3949423 274%attr(755,root,root) %{_bindir}/distccmon-gnome
216adac7
JB
275%{_desktopdir}/distccmon-gnome.desktop
276%{_pixmapsdir}/distccmon-gnome.png
e3949423 277%endif
This page took 0.163093 seconds and 4 git commands to generate.