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