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