]> git.pld-linux.org Git - packages/subversion.git/blob - subversion.spec
- fix swig requirements
[packages/subversion.git] / subversion.spec
1 #
2 # TODO:
3 # - separate subpackage with svnserve + init.d script + sysconfig file
4 #
5 # Conditional build:
6 %bcond_with     internal_neon           # build with internal neon
7 %bcond_with     net_client_only         # build only net client
8 #       
9 %include        /usr/lib/rpm/macros.python
10 %{!?with_net_client_only:%include       /usr/lib/rpm/macros.perl}
11 Summary:        A Concurrent Versioning system similar to but better than CVS
12 Summary(pl):    System kontroli wersji podobny, ale lepszy, ni¿ CVS
13 Summary(pt_BR): Sistema de versionamento concorrente
14 Name:           subversion
15 Version:        0.37.0
16 Release:        1
17 License:        Apache/BSD Style
18 Group:          Development/Version Control
19 Source0:        http://svn.collab.net/tarballs/%{name}-%{version}.tar.gz
20 # Source0-md5:  048c4d17d5880dc8f3699020eac56224
21 Source1:        %{name}-dav_svn.conf
22 Source2:        %{name}-authz_svn.conf
23 Source3:        %{name}-svnserve.init
24 Source4:        %{name}-svnserve.sysconfig
25 Patch0:         %{name}-svnlook.patch
26 URL:            http://subversion.tigris.org/
27 %if %{with net_client_only}
28 %global apache_modules_api 0
29 %else
30 BuildRequires:  automake
31 BuildRequires:  apache-devel >= 2.0.47-0.6
32 BuildRequires:  db-devel >= 4.1.25
33 BuildRequires:  rpmbuild(macros) >= 1.120
34 BuildRequires:  swig >= 1.3.19
35 BuildRequires:  swig-python >= 1.3.19
36 BuildRequires:  swig-perl >= 1.3.19
37 BuildRequires:  perl-devel >= 5.8.0
38 BuildRequires:  rpm-perlprov
39 %endif
40 BuildRequires:  apr-devel >= 1:0.9.5
41 BuildRequires:  apr-util-devel >= 1:0.9.5
42 BuildRequires:  autoconf >= 2.59
43 BuildRequires:  bison
44 BuildRequires:  docbook-style-xsl >= 1.56
45 BuildRequires:  expat-devel
46 BuildRequires:  libtool >= 1.4-9
47 BuildRequires:  libxslt-progs
48 %{!?with_internal_neon:BuildRequires:   neon-devel >= 0.24.1}
49 BuildRequires:  python >= 2.2
50 BuildRequires:  rpm-pythonprov >= 4.0.2-50
51 BuildRequires:  texinfo
52 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
53
54 %define         _apachelibdir   /usr/%{_lib}/apache
55 %define         _libexecdir     %{_libdir}/svn
56
57 %description
58 The goal of the Subversion project is to build a version control
59 system that is a compelling replacement for CVS in the open source
60 community.
61
62 Our goals are:
63 - All current CVS features.
64 - Directories, renames, and file meta-data are versioned.
65 - Symbolic links, etc, are supported
66 - Commits are truly atomic.
67 - Branching and tagging are cheap (constant time) operations
68 - Repeated merges are handled gracefully
69 - Support for plug-in client side diff programs
70 - Natively client/server
71 - Client/server protocol sends diffs in both directions
72 - Costs are proportional to change size, not project size
73 - Internationalization
74 - Progressive multi-lingual support
75
76 %description -l pl
77 Celem projektu Subversion jest stworzenie systemu kontroli wersji jako
78 zamiennika dla CVS.
79
80 Cele projektu to:
81 - Wszystkie aktualne mo¿liwo¶ci CVS.
82 - Katalogi, zmiany nazw oraz meta-dane plików s± wersjonowane.
83 - Wsparcie dla linków symbolicznych itp.
84 - Commity s± w pe³ni atomowe.
85 - Branchowanie oraz tagowanie s± tanimi (sta³ymi w czasie) operacjami.
86 - Powtarzaj±ce merge.
87 - Wsparcie dla pluginów diff'a po stronie klienta.
88 - Natywny klient/serwer.
89 - Klient/Serwer przesy³aj± diffy w obu kierunkach.
90 - Koszty proporcjonalne do rozmiaru zmiany, a nie rozmiaru projektu.
91 - Internacjonalizacja.
92 - Postêpuj±ce wsparcie dla wielu jêzyków.
93
94 %description -l pt_BR
95 O objetivo do projeto Subversion é construir um sistema de controle de
96 versões que seja um substituto para o CVS (Concurrent Versioning
97 System) na comunidade opensource, fornecendo grandes melhorias.
98
99 %package libs
100 Summary:        Subversion libraries and modules
101 Summary(pl):    Biblioteka subversion oraz ³adowalne modu³y
102 Group:          Libraries
103 Obsoletes:      libsubversion0
104
105 %description libs
106 Subversion libraries and modules.
107
108 %description libs -l pl
109 Biblioteka subversion oraz ³adowalne modu³y.
110
111 %package devel
112 Summary:        Header files and develpment documentation for subversion
113 Summary(pl):    Pliki nag³ówkowe i dokumetacja do subversion
114 Summary(pt_BR): Arquivos de desenvolvimento para o Subversion
115 Group:          Development/Libraries
116 Requires:       %{name}-libs = %{version}
117 Obsoletes:      libsubversion0-devel
118
119 %description devel
120 Header files and develpment documentation for subversion.
121
122 %description devel -l pl
123 Pliki nag³ówkowe i dokumetacja do subversion.
124
125 %description devel -l pt_BR
126 Este pacote provê os arquivos necessários para desenvolvedores
127 interagirem com o Subversion.
128
129 %package static
130 Summary:        Static subversion library
131 Summary(pl):    Biblioteka statyczna subversion
132 Summary(pt_BR): Sistema de versionamento concorrente
133 Group:          Development/Libraries
134 Requires:       %{name}-devel = %{version}
135 Obsoletes:      libsubversion0-static-devel
136
137 %description static
138 Static subversion library.
139
140 %description static -l pl
141 Biblioteka statyczna subversion.
142
143 %description static -l pt_BR
144 Este pacote provê um cliente estático do subversion.
145
146 %package svnserve
147 Summary:        Subversion svnserve
148 Summary(pl):    Subversion svnserve
149 Group:          Networking/Daemons
150 PreReq:         rc-scripts
151 Requires(post,preun):   /sbin/chkconfig
152
153 %description svnserve
154 Subversion svnserve server.
155
156 %description svnserve -l pl
157 Serwer subversion svnserve.
158
159 %package tools
160 Summary:        Subversion tools and scripts
161 Summary(pl):    Narzêdzia oraz skrypty dla subversion
162 Summary(pt_BR): Módulos python para acessar os recursos do Subversion
163 Group:          Applications
164 %pyrequires_eq  python
165 Requires:       python-rcsparse >= 0.1-0.20031026.0
166 Requires:       python-subversion = %{version}
167
168 %description tools
169 Subversion tools and scripts.
170
171 %description tools -l pl
172 Narzêdzia oraz skrypty dla subversion.
173
174 %package -n python-subversion
175 Summary:        Subversion python bindings
176 Summary(pl):    Dowi±zania do subversion dla pythona
177 Summary(pt_BR): Módulos python para acessar os recursos do Subversion
178 Group:          Development/Languages/Python
179 %pyrequires_eq  python
180 Obsoletes:      subversion-python
181
182 %description -n python-subversion
183 Subversion python bindings.
184
185 %description -n python-subversion -l pl
186 Dowi±zania do subversion dla pythona.
187
188 %description -n python-subversion -l pt_BR
189 Módulos python para acessar os recursos do Subversion.
190
191 %package -n perl-subversion
192 Summary:        Subversion perl bindings
193 Summary(pl):    Dowi±zania do subversion dla perla
194 Summary(pt_BR): Módulos perl para acessar os recursos do Subversion
195 Group:          Development/Languages/Perl
196 Obsoletes:      subversion-perl
197
198 %description -n perl-subversion
199 Subversion perl bindings.
200
201 %description -n perl-subversion -l pl
202 Dowi±zania do subversion dla perl.
203
204 %description -n perl-subversion -l pt_BR
205 Módulos perl para acessar os recursos do Subversion.
206
207 %package -n apache-mod_dav_svn
208 Summary:        Apache module: Subversion Server
209 Summary(pl):    Modu³ apache: Serwer Subversion
210 Group:          Networking/Daemons
211 Requires:       apache >= 2.0.47
212 Requires:       apache(modules-api) = %{apache_modules_api}
213 Requires:       apache-mod_dav
214
215 %description -n apache-mod_dav_svn
216 Apache module: Subversion Server.
217
218 %description -n apache-mod_dav_svn -l pl
219 Modu³ apache: Serwer Subversion.
220
221 %package -n apache-mod_authz_svn
222 Summary:        Apache module: Subversion Server - path-based authorization
223 Summary(pl):    Modu³ apache: autoryzacja na podstawie ¶cie¿ki dla serwera Subversion
224 Group:          Networking/Daemons
225 Requires:       apache-mod_dav_svn = %{version}
226 Requires:       apache >= 2.0.47
227 Requires:       apache(modules-api) = %{apache_modules_api}
228
229 %description -n apache-mod_authz_svn
230 Apache module: Subversion Server - path-based authorization.
231
232 %description -n apache-mod_authz_svn -l pl
233 Modu³ apache: autoryzacja na podstawie ¶cie¿ki dla serwera Subversion.
234
235 %prep
236 %setup -q
237 %patch0 -p0
238
239 %build
240 cp -f /usr/share/automake/config.sub ac-helpers
241 chmod +x ./autogen.sh && ./autogen.sh
242
243 # don't enable dso - currently it's broken
244 %configure \
245 %if %{with net_client_only}
246         --without-apache \
247         --without-swig \
248         --without-apxs \
249         --without-berkeley-db \
250 %else
251         --disable-dso \
252         --disable-mod-activation \
253         --with-apxs=%{_sbindir}/apxs \
254         --with-berkeley-db=%{_includedir}/db4:%{_libdir} \
255 %endif
256         %{!?with_internal_neon:--with-neon=%{_prefix}} \
257         --with-apr=%{_bindir}/apr-config \
258         --with-apr-util=%{_bindir}/apu-config
259
260 %{__make}
261
262 %if ! %{with net_client_only}
263 # python
264 %{__make} swig-py \
265         swig_pydir=%{py_sitedir}/libsvn \
266         swig_pydir_extra=%{py_sitedir}/svn
267 # perl
268 bdir=$(pwd)
269 %{__make} install-swig-pl-lib \
270         LC_ALL=C \
271         DESTDIR=${bdir}/swig-pl-lib-buildroot
272 %{__make}
273 cd subversion/bindings/swig/perl
274 env APR_CONFIG=%{_bindir}/apr-config \
275     APU_CONFIG=%{_bindir}/apu-config \
276         %{__perl} Makefile.PL \
277         INSTALLDIRS=vendor
278 env LIBRARY_PATH=${bdir}/swig-pl-lib-buildroot%{_libdir} %{__make}
279 cd ../../../../
280 %endif
281
282 # build documentation; build process for documentation is severely
283 # braindamaged -- authors suggests to untar docbook distribution in
284 # build directory, hence the hack here
285 ln -s /usr/share/sgml/docbook/xsl-stylesheets doc/book/tools/xsl
286 %{__make} -C doc/book all-html
287
288 # prepare for %%doc below
289 mv -f doc/book/book/html-chunk svn-handbook
290 mkdir svn-handbook/images/
291 cp -f doc/book/book/images/*.png svn-handbook/images/
292
293 %install
294 rm -rf $RPM_BUILD_ROOT
295 install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig}
296 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/httpd/httpd.conf,%{_apachelibdir},%{_infodir}}
297
298 %{__make} install \
299         LC_ALL=C \
300         %{!?with_net_client_only:install-swig-py} \
301         DESTDIR=$RPM_BUILD_ROOT \
302         swig_pydir=%{py_sitedir}/libsvn \
303         swig_pydir_extra=%{py_sitedir}/svn
304
305 %if ! %{with net_client_only}
306 %{__make} install-swig-pl-lib \
307         LC_ALL=C \
308         DESTDIR=$RPM_BUILD_ROOT
309 %{__make} -C subversion/bindings/swig/perl install \
310         DESTDIR=$RPM_BUILD_ROOT
311 %endif
312
313 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/httpd.conf/65_mod_dav_svn.conf
314 install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/httpd.conf/66_mod_authz_svn.conf
315 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/svnserve
316 install %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/svnserve
317 install doc/programmer/design/*.info* $RPM_BUILD_ROOT%{_infodir}/
318
319 %if ! %{with net_client_only}
320 install tools/cvs2svn/cvs2svn.py        $RPM_BUILD_ROOT%{_bindir}/cvs2svn
321 install tools/cvs2svn/cvs2svn.1         $RPM_BUILD_ROOT%{_mandir}/man1
322 cp tools/cvs2svn/README tools/cvs2svn/README.cvs2svn
323
324 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
325 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
326 %endif
327
328 %clean
329 rm -rf $RPM_BUILD_ROOT
330
331 %post devel
332 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
333
334 %postun devel
335 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
336
337 %post   libs -p /sbin/ldconfig
338 %postun libs -p /sbin/ldconfig
339
340 %post svnserve
341 if [ -f /var/lock/subsys/svnserve ]; then
342         /etc/rc.d/init.d/svnserve restart 1>&2
343 else
344         echo "Run \"/etc/rc.d/init.d/svnserve start\" to start subversion svnserve daemon."
345 fi
346
347 %preun svnserve
348 if [ "$1" = "0" ]; then
349         if [ -f /var/lock/subsys/svnserve ]; then
350                 /etc/rc.d/init.d/svnserve restart 1>&2
351         fi
352 fi
353
354 %post -n apache-mod_dav_svn
355 if [ -f /var/lock/subsys/httpd ]; then
356         /etc/rc.d/init.d/httpd restart 1>&2
357 else
358         echo "Run \"/etc/rc.d/init.d/httpd start\" to start apache http daemon."
359 fi
360
361 %preun -n apache-mod_dav_svn
362 if [ "$1" = "0" ]; then
363         if [ -f /var/lock/subsys/httpd ]; then
364                 /etc/rc.d/init.d/httpd restart 1>&2
365         fi
366 fi
367
368 %files
369 %defattr(644,root,root,755)
370 %doc BUGS CHANGES COPYING INSTALL README
371 %doc svn-handbook doc/book/misc-docs/misc-docs.html
372 %doc tools/hook-scripts/*.{pl,py,example}
373 %doc tools/hook-scripts/mailer/*.{py,example}
374 %attr(755,root,root) %{_bindir}/svn*
375 %exclude %{_bindir}/svnserve
376 %{_mandir}/man1/*
377 %{_mandir}/man5/*
378 %{_mandir}/man8/*
379 %exclude %{_mandir}/man?/svnserve*
380 %{?with_internal_neon:%exclude %{_mandir}/man1/neon*}
381
382 %files libs
383 %defattr(644,root,root,755)
384 %attr(755,root,root) %{_libdir}/lib*.so.*
385
386 %files devel
387 %defattr(644,root,root,755)
388 %{_includedir}/%{name}*
389 %attr(755,root,root) %{_libdir}/lib*.so
390 %{_libdir}/lib*.la
391 %{_infodir}/svn*
392
393 %files static
394 %defattr(644,root,root,755)
395 %{_libdir}/lib*.a
396
397 %if ! %{with net_client_only}
398 %files svnserve
399 %defattr(644,root,root,755)
400 %attr(755,root,root) %{_bindir}/svnserve
401 %{_mandir}/man?/svnserve*
402 %attr(754,root,root) /etc/rc.d/init.d/svnserve
403 %attr(640,root,root) %config(noreplace) %verify(not mtime md5 size) /etc/sysconfig/svnserve
404
405 %files tools
406 %defattr(644,root,root,755)
407 %doc tools/cvs2svn/README*
408 %attr(755,root,root) %{_bindir}/cvs*
409 %{_mandir}/man1/cvs*
410
411 %files -n python-subversion
412 %defattr(644,root,root,755)
413 %doc tools/backup/*.py tools/examples/*.py
414 %dir %{py_sitedir}/svn
415 %dir %{py_sitedir}/libsvn
416 %{py_sitedir}/svn/*.py[co]
417 %{py_sitedir}/libsvn/*.py[co]
418 %attr(755,root,root) %{py_sitedir}/libsvn/*.so
419
420 %files -n perl-subversion
421 %defattr(644,root,root,755)
422 %{perl_vendorarch}/SVN
423 %dir %{perl_vendorarch}/auto/SVN
424 %dir %{perl_vendorarch}/auto/SVN/*
425 %attr(755,root,root) %{perl_vendorarch}/auto/SVN/*/*.so
426 %{perl_vendorarch}/auto/SVN/*/*.bs
427 %{_mandir}/man3/*.3pm*
428
429 %files -n apache-mod_dav_svn
430 %defattr(644,root,root,755)
431 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/httpd/httpd.conf/*_mod_dav_svn.conf
432 %attr(755,root,root) %{_apachelibdir}/mod_dav_svn.so
433
434 %files -n apache-mod_authz_svn
435 %defattr(644,root,root,755)
436 %doc subversion/mod_authz_svn/INSTALL
437 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/httpd/httpd.conf/*_mod_authz_svn.conf
438 %attr(755,root,root) %{_apachelibdir}/mod_authz_svn.so
439 %endif
This page took 0.081766 seconds and 4 git commands to generate.