]> git.pld-linux.org Git - packages/distcc.git/blob - distcc.spec
080ae3085e6bd2aa4817bbde3dff924d5963fe2f
[packages/distcc.git] / distcc.spec
1 #
2 # Conditional build:
3 %bcond_without  gnome   # build without gnome(monitor) support
4 #
5 Summary:        Program to distribute compilation of C or C++
6 Summary(pl):    Program do rozdzielania kompilacji programów w C lub C++
7 Name:           distcc
8 Group:          Development/Languages
9 Version:        2.14
10 Release:        0.3
11 License:        GPL
12 Source0:        http://distcc.samba.org/ftp/distcc/%{name}-%{version}.tar.bz2
13 # Source0-md5:  612ee81b3e04fc6000dfbc4078ec9d8b
14 Source1:        %{name}.inetd
15 Source2:        %{name}.init
16 Source3:        %{name}.sh
17 Source4:        %{name}.csh
18 Source5:        %{name}.config
19 Source6:        %{name}.logrotate
20 Patch0:         %{name}-user.patch
21 Patch1:         %{name}-waal.patch
22 Patch2:         %{name}-line3.diff
23 URL:            http://distcc.samba.org/
24 BuildRequires:  autoconf >= 2.53
25 BuildRequires:  automake
26 %{?with_gnome:BuildRequires:    libgnomeui-devel >= 2.0}
27 BuildRequires:  pkgconfig
28 BuildRequires:  popt-devel
29 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31 %description
32 distcc is a program to distribute compilation of C or C++ code across
33 several machines on a network. distcc should always generate the same
34 results as a local compile, is simple to install and use, and is often
35 two or more times faster than a local compile.
36
37 %description -l pl
38 distcc jest programem pozwalaj±cym na dystrybucjê kompilacji C lub C++
39 na kilka maszyn w sieci. distcc powinien zawsze generowaæ takie same
40 rezultaty jak lokalna kompilacja, jest prosty w instalacji i u¿yciu
41 oraz bardzo czêsto dwa lub wiêcej razy szybszy ni¿ lokalna kompilacja.
42
43 %package common
44 Summary:        Common files for inetd and standalone versions of distcc
45 Summary(pl):    Pliki wspólne dla wersji inetd i standalone distcc
46 Group:          Daemons
47 Requires:       gcc
48 Requires:       gcc-c++
49 Obsoletes:      distcc < 2.1-2
50
51 %description common
52 distcc is a program to distribute compilation of C or C++ code across
53 several machines on a network. distcc should always generate the same
54 results as a local compile, is simple to install and use, and is often
55 two or more times faster than a local compile.
56
57 %description common -l pl
58 distcc jest programem pozwalaj±cym na dystrybucjê kompilacji C lub C++
59 na kilka maszyn w sieci. distcc powinien zawsze generowaæ takie same
60 rezultaty jak lokalna kompilacja, jest prosty w instalacji i u¿yciu
61 oraz bardzo czêsto dwa lub wiêcej razy szybszy ni¿ lokalna kompilacja.
62
63 %package inetd
64 Summary:        inetd configs for distcc
65 Summary(pl):    Pliki konfiguracyjne do u¿ycia distcc poprzez inetd
66 Group:          Daemons
67 PreReq:         %{name}-common = %{version}-%{release}
68 PreReq:         rc-inetd
69 Obsoletes:      distcc < 2.1-2
70
71 %description inetd
72 distcc configs for running from inetd.
73
74 %description inetd -l pl
75 Pliki konfiguracyjna distcc do startowania demona poprzez inetd.
76
77 %package standalone
78 Summary:        Standalone daemon configs for distcc
79 Summary(pl):    Pliki konfiguracyjne do startowania distcc w trybie standalone
80 Group:          Daemons
81 PreReq:         %{name}-common = %{version}-%{release}
82 PreReq:         rc-scripts
83 Requires(post,preun):   /sbin/chkconfig
84 Obsoletes:      distcc < 2.1-2
85
86 %description standalone
87 distcc configs for running as a standalone daemon.
88
89 %description standalone -l pl
90 Pliki konfiguracyjne distcc do startowania demona w trybie
91 standalone.
92
93 %package monitor
94 Summary:        Monitor for distcc
95 Summary(pl):    Monitor dla distcc
96 Group:          Applications
97
98 %description monitor
99 Monitor for distcc.
100
101 %description monitor -l pl
102 Monitor dla distcc.
103
104 %package monitor-gnome
105 Summary:        gtk monitor for distcc
106 Summary(pl):    Monitor gtk dla distcc
107 Group:          X11/Applications
108
109 %description monitor-gnome
110 gtk monitor for distcc.
111
112 %description monitor-gnome -l pl
113 Monitor gtk dla distcc.
114
115 %prep
116 %setup -q
117 %patch0 -p1
118 #%patch1 -p1
119 %patch2 -p1
120
121 sed -i -e 's#PKGDATADIR#"%{_pixmapsdir}"#g' src/mon-gnome.c
122
123 %build
124 cp -f /usr/share/automake/config.* .
125 %{__autoconf}
126 %{__autoheader}
127 %configure \
128         --enable-rfc2553 \
129         %{?with_gnome:--with-gnome} 
130
131 %{__make}
132
133 %install
134 rm -rf $RPM_BUILD_ROOT
135 install -d $RPM_BUILD_ROOT/etc/{sysconfig/rc-inetd,rc.d/init.d,profile.d,logrotate.d} \
136         $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},%{_var}/log}
137
138 %{__make} install \
139         DESTDIR=$RPM_BUILD_ROOT
140
141 install %{SOURCE1} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/distccd
142 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/distcc
143 install %{SOURCE3} %{SOURCE4} $RPM_BUILD_ROOT/etc/profile.d
144 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/distccd
145 install %{SOURCE6} $RPM_BUILD_ROOT/etc/logrotate.d/distccd
146
147 %if %{with gnome}
148 mv $RPM_BUILD_ROOT%{_datadir}/%{name}/distccmon-gnome.desktop \
149         $RPM_BUILD_ROOT%{_desktopdir}
150 mv $RPM_BUILD_ROOT%{_datadir}/%{name}/distccmon-gnome-icon.png \
151         $RPM_BUILD_ROOT%{_pixmapsdir}
152 %endif
153
154 touch $RPM_BUILD_ROOT%{_var}/log/distcc
155
156 %clean
157 rm -rf $RPM_BUILD_ROOT
158
159 %post inetd
160 if [ -f /var/lock/subsys/rc-inetd ]; then
161         /etc/rc.d/init.d/rc-inetd reload 1>&2
162 else
163         echo "Type \"/etc/rc.d/init.d/rc-inetd start\" to start inet server" 1>&2
164 fi
165
166 %postun inetd
167 if [ -f /var/lock/subsys/rc-inetd ]; then
168         /etc/rc.d/init.d/rc-inetd reload
169 fi
170
171 %post standalone
172 /sbin/chkconfig --add distcc
173 if [ -f /var/lock/subsys/distccd ]; then
174         /etc/rc.d/init.d/distcc restart 1>&2
175 else
176         echo "Run \"/etc/rc.d/init.d/distcc start\" to start distcc daemon."
177 fi
178
179 %preun standalone
180 if [ "$1" = "0" ]; then
181         if [ -f /var/lock/subsys/distccd ]; then
182                 /etc/rc.d/init.d/distcc stop 1>&2
183         fi
184         /sbin/chkconfig --del distcc
185 fi
186
187 %files
188 %defattr(644,root,root,755)
189 %doc AUTHORS NEWS README *.txt
190 %attr(755,root,root) %{_bindir}/%{name}
191 %{_mandir}/man?/%{name}.*
192 /etc/profile.d/*sh
193
194 %files common
195 %defattr(644,root,root,755)
196 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/distccd
197 %attr(640,root,root) /etc/logrotate.d/distccd
198 %attr(755,root,root) %{_bindir}/%{name}d
199 %{_mandir}/man?/%{name}d.*
200 %attr(640,nobody,root) %ghost %{_var}/log/distcc
201
202 %files inetd
203 %defattr(644,root,root,755)
204 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/rc-inetd/distccd
205
206 %files standalone
207 %defattr(644,root,root,755)
208 %attr(754,root,root) /etc/rc.d/init.d/distcc
209
210 %files monitor
211 %defattr(644,root,root,755)
212 %attr(755,root,root) %{_bindir}/distccmon-text
213 %{_mandir}/man1/distccmon-text.*
214
215 %if %{with gnome}
216 %files monitor-gnome
217 %defattr(644,root,root,755)
218 %attr(755,root,root) %{_bindir}/distccmon-gnome
219 %{_desktopdir}/*.desktop
220 %{_pixmapsdir}/*.png
221 %endif
This page took 0.038815 seconds and 2 git commands to generate.