]> git.pld-linux.org Git - packages/subversion.git/blob - subversion.spec
2a2aa004cc5959356848fdf782734e24958d8dc7
[packages/subversion.git] / subversion.spec
1 # TODO:
2 # - serf as default: https://subversion.apache.org/docs/release-notes/1.7.html#serf
3 #
4 # Conditional build:
5 %bcond_with     net_client_only         # build only net client
6 %bcond_without  neon                    # use serf instead of neon
7 %bcond_without  swig                    # disable bindings generation with Swig
8 %bcond_without  python                  # build without Python bindings (broken)
9 %bcond_without  csvn                    # build Python csvn bindings
10 %bcond_without  perl                    # build without Perl bindings
11 %bcond_with     ruby                    # build with Ruby bindings (only 1.8.x is supported)
12 %bcond_without  apache                  # build without Apache support (webdav, etc)
13 %bcond_without  javahl                  # build without javahl support (Java high-level bindings)
14 %bcond_without  tests                   # don't perform "make check"
15 %bcond_without  kwallet                 # build without kde4 wallet support
16 %bcond_without  kde                     # build without kde4 support (alias for kwallet)
17 %bcond_without  gnome                   # build without gnome keyring support
18 %bcond_without  db                      # disable Subversion Berkeley DB based filesystem library
19
20 # for AC: --without csvn,gnome,javahl,kde,ruby
21
22 %if %{with net_client_only}
23 %undefine       with_apache
24 %undefine       with_db
25 %undefine       with_swig
26 %undefine       with_javahl
27 %endif
28
29 %if %{without swig}
30 %undefine       with_perl
31 %undefine       with_python
32 %undefine       with_ruby
33 %endif
34
35 %if %{without kde}
36 %undefine       with_kwallet
37 %endif
38
39 %if %{without python} && %{without perl} && %{without ruby}
40 %undefine       with_swig
41 %endif
42
43 %define apxs    /usr/sbin/apxs
44 %define pdir    SVN
45 %define pnam    _Core
46
47 %if %{with neon}
48 %define webdavlib       neon
49 %else
50 %define webdavlib       serf
51 %endif
52 %{?with_perl:%include   /usr/lib/rpm/macros.perl}
53 Summary:        A Concurrent Versioning system similar to but better than CVS
54 Summary(pl.UTF-8):      System kontroli wersji podobny, ale lepszy, niż CVS
55 Summary(pt_BR.UTF-8):   Sistema de versionamento concorrente
56 Name:           subversion
57 Version:        1.7.6
58 Release:        2
59 License:        Apache v2.0
60 Group:          Development/Version Control
61 Source0:        http://www.idg.pl/mirrors/apache/subversion/%{name}-%{version}.tar.bz2
62 # Source0-md5:  4baa434db7709bb059b05d02a2547663
63 Source1:        %{name}-dav_svn.conf
64 Source2:        %{name}-authz_svn.conf
65 Source3:        %{name}-svnserve.init
66 Source4:        %{name}-svnserve.sysconfig
67 # current subversion tarball has correct *.swg files
68 # but after regeneration these are broken again, so
69 # we still need this script
70 Source5:        %{name}-convert-typemaps-to-ifdef.py
71 Patch0:         %{name}-home_etc.patch
72 Patch1:         %{name}-DESTDIR.patch
73 Patch2:         %{name}-ruby-datadir-path.patch
74 Patch3:         %{name}-tests.patch
75 Patch4:         subversion-1.7.5-kwallet-gcc47.patch
76 URL:            http://subversion.apache.org/
77 %{?with_apache:BuildRequires:   apache-devel >= 2.2.0-8}
78 BuildRequires:  apr-devel >= 1:1.0.0
79 BuildRequires:  apr-util-devel >= 1:1.2.8-3
80 BuildRequires:  autoconf >= 2.59
81 BuildRequires:  automake
82 BuildRequires:  bison
83 BuildRequires:  cyrus-sasl-devel
84 %if %{with kwallet} || %{with gnome}
85 BuildRequires:  dbus-devel
86 %endif
87 BuildRequires:  db-devel >= 4.1.25
88 BuildRequires:  expat-devel
89 BuildRequires:  gettext-devel
90 %{?with_kwallet:BuildRequires:  kde4-kdelibs-devel}
91 %{?with_gnome:BuildRequires:    libgnome-keyring-devel}
92 BuildRequires:  libmagic-devel
93 BuildRequires:  libtool >= 1.4-9
94 BuildRequires:  pkgconfig
95 %{?with_csvn:BuildRequires:     python-ctypesgen}
96 BuildRequires:  rpm-pythonprov
97 BuildRequires:  rpmbuild(macros) >= 1.583
98 BuildRequires:  sed >= 4.0
99 BuildRequires:  sqlite3-devel >= 3.6.18
100 BuildRequires:  texinfo
101 BuildRequires:  which
102 %if %{with neon}
103 BuildRequires:  neon-devel >= 0.26.0
104 %else
105 BuildRequires:  serf-devel >= 0.7.1
106 %endif
107 %if %{with javahl}
108 BuildRequires:  jdk >= 1.5
109 BuildRequires:  libstdc++-devel
110 %endif
111 %if %{with perl}
112 BuildRequires:  perl-devel >= 1:5.8.0
113 BuildRequires:  rpm-perlprov >= 4.1-13
114 BuildRequires:  swig-perl >= 1.3.24
115 %endif
116 %if %{with python}
117 BuildRequires:  python-devel >= 1:2.4
118 BuildRequires:  swig-python >= 1.3.24
119 %endif
120 %if %{with ruby}
121 BuildRequires:  ruby-devel < 1:1.9
122 BuildRequires:  ruby-devel >= 1:1.8.2
123 BuildRequires:  ruby-rubygems
124 BuildRequires:  swig-ruby >= 1.3.24
125 %endif
126 Requires:       %{name}-libs = %{version}-%{release}
127 %requires_ge    sqlite3
128 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
129
130 %define         _libexecdir             %{_libdir}/svn
131 %define         apacheconfdir   %(%{apxs} -q SYSCONFDIR 2>/dev/null)/conf.d
132 %define         apachelibdir    %(%{apxs} -q LIBEXECDIR 2>/dev/null)
133
134 %define         skip_post_check_so      libsvn_swig_py-1.so.* libsvn_swig_perl-1.so.*
135
136 %description
137 The goal of the Subversion project is to build a version control
138 system that is a compelling replacement for CVS in the open source
139 community.
140
141 Our goals are:
142 - All current CVS features.
143 - Directories, renames, and file meta-data are versioned.
144 - Symbolic links, etc, are supported
145 - Commits are truly atomic.
146 - Branching and tagging are cheap (constant time) operations
147 - Repeated merges are handled gracefully
148 - Support for plug-in client side diff programs
149 - Natively client/server
150 - Client/server protocol sends diffs in both directions
151 - Costs are proportional to change size, not project size
152 - Internationalization
153 - Progressive multi-lingual support
154
155 %description -l pl.UTF-8
156 Celem projektu Subversion jest stworzenie systemu kontroli wersji jako
157 zamiennika dla CVS.
158
159 Cele projektu to:
160 - Wszystkie aktualne możliwości CVS.
161 - Katalogi, zmiany nazw oraz metadane plików są wersjonowane.
162 - Obsługa dowiązań symbolicznych itp.
163 - Commity są w pełni atomowe.
164 - Branchowanie oraz tagowanie są tanimi (stałymi w czasie) operacjami.
165 - Dobra obsługa powtarzanego łączenia (merge).
166 - Obsługa wtyczek diff po stronie klienta.
167 - Natywny klient/serwer.
168 - Klient/Serwer przesyłają diffy w obu kierunkach.
169 - Koszty proporcjonalne do rozmiaru zmiany, a nie rozmiaru projektu.
170 - Internacjonalizacja.
171 - Postępujące wsparcie dla wielu języków.
172
173 %description -l pt_BR.UTF-8
174 O objetivo do projeto Subversion é construir um sistema de controle de
175 versões que seja um substituto para o CVS (Concurrent Versioning
176 System) na comunidade opensource, fornecendo grandes melhorias.
177
178 %package libs
179 Summary:        Subversion libraries and modules
180 Summary(pl.UTF-8):      Biblioteka subversion oraz ładowalne moduły
181 Group:          Libraries
182 %if %{with neon}
183 Requires:       neon >= 0.26.0
184 %else
185 Requires:       serf >= 0.7.1
186 %endif
187 Obsoletes:      libsubversion0
188
189 %description libs
190 Subversion libraries and modules.
191
192 %description libs -l pl.UTF-8
193 Biblioteka subversion oraz ładowalne moduły.
194
195 %package devel
196 Summary:        Header files and develpment documentation for subversion
197 Summary(pl.UTF-8):      Pliki nagłówkowe i dokumetacja do subversion
198 Summary(pt_BR.UTF-8):   Arquivos de desenvolvimento para o Subversion
199 Group:          Development/Libraries
200 Requires:       %{name}-libs = %{version}-%{release}
201 Requires:       apr-util-devel >= 1:1.0.0
202 %{?with_neon:Requires:  neon-devel >= 0.26.0}
203 Obsoletes:      libsubversion0-devel
204
205 %description devel
206 Header files and develpment documentation for subversion.
207
208 %description devel -l pl.UTF-8
209 Pliki nagłówkowe i dokumetacja do subversion.
210
211 %description devel -l pt_BR.UTF-8
212 Este pacote provê os arquivos necessários para desenvolvedores
213 interagirem com o Subversion.
214
215 %package static
216 Summary:        Static subversion library
217 Summary(pl.UTF-8):      Biblioteka statyczna subversion
218 Summary(pt_BR.UTF-8):   Sistema de versionamento concorrente
219 Group:          Development/Libraries
220 Requires:       %{name}-devel = %{version}
221 Obsoletes:      libsubversion0-static-devel
222
223 %description static
224 Static subversion library.
225
226 %description static -l pl.UTF-8
227 Biblioteka statyczna subversion.
228
229 %description static -l pt_BR.UTF-8
230 Este pacote provê um cliente estático do subversion.
231
232 %package svnserve
233 Summary:        Subversion svnserve
234 Summary(pl.UTF-8):      Subversion svnserve
235 Group:          Networking/Daemons
236 Requires(post,preun):   /sbin/chkconfig
237 Requires(postun):       /usr/sbin/groupdel
238 Requires(postun):       /usr/sbin/userdel
239 Requires(pre):  /bin/id
240 Requires(pre):  /usr/bin/getgid
241 Requires(pre):  /usr/lib/rpm/user_group.sh
242 Requires(pre):  /usr/sbin/groupadd
243 Requires(pre):  /usr/sbin/useradd
244 Requires(pre):  /usr/sbin/usermod
245 Requires:       %{name} = %{version}-%{release}
246 Requires:       rc-scripts
247 Provides:       group(svn)
248 Provides:       user(svn)
249
250 %description svnserve
251 Subversion svnserve server.
252
253 %description svnserve -l pl.UTF-8
254 Serwer subversion svnserve.
255
256 %package tools
257 Summary:        Subversion tools and scripts
258 Summary(pl.UTF-8):      Narzędzia oraz skrypty dla subversion
259 Summary(pt_BR.UTF-8):   Módulos python para acessar os recursos do Subversion
260 Group:          Applications
261 %pyrequires_eq  python
262 Requires:       %{name} = %{version}-%{release}
263 Requires:       python-subversion = %{version}
264
265 %description tools
266 Subversion tools and scripts.
267
268 %description tools -l pl.UTF-8
269 Narzędzia oraz skrypty dla subversion.
270
271 %package -n bash-completion-subversion
272 Summary:        bash completion for subversion
273 Summary(pl.UTF-8):      Dopełnienia basha dla subversion
274 Group:          Applications/Shells
275 Requires:       %{name} = %{version}-%{release}
276 Requires:       bash-completion
277 Conflicts:      %{name}-tools <= 1.1.0-0.rc6.1
278
279 %description -n bash-completion-subversion
280 Bash completion for subversion.
281
282 %description -n bash-completion-subversion -l pl.UTF-8
283 Dopełnienia basha dla subversion.
284
285 %package -n java-subversion
286 Summary:        Subversion Java bindings
287 Summary(pl.UTF-8):      Dowiązania do Subversion dla Javy
288 Group:          Development/Languages/Java
289 Requires:       %{name}-libs = %{version}-%{release}
290
291 %description -n java-subversion
292 This is a set of Java classes which provide the functionality of
293 subversion-libs, the Subversion libraries. It is useful if you want
294 to, for example, write a Java class that manipulates a Subversion
295 repository or working copy. See the 'subversion' package for more
296 information.
297
298 %description -n java-subversion -l pl.UTF-8
299 Ten pakiet zawiera zestaw klas Javy udostępniających funkcjonalność
300 subversion-libs, czyli bibliotek Subversion. Jest przydatny przy
301 pisaniu klas Javy np. modyfikujących repozytorium Subversion lub kopię
302 roboczą. Więcej informacji w pakiecie subversion.
303
304 %package -n python-subversion
305 Summary:        Subversion Python bindings
306 Summary(pl.UTF-8):      Dowiązania do Subversion dla Pythona
307 Summary(pt_BR.UTF-8):   Módulos Python para acessar os recursos do Subversion
308 Group:          Development/Languages/Python
309 %pyrequires_eq  python
310 Requires:       %{name}-libs = %{version}-%{release}
311 Obsoletes:      subversion-python
312
313 %description -n python-subversion
314 Subversion Python bindings.
315
316 %description -n python-subversion -l pl.UTF-8
317 Dowiązania do Subversion dla Pythona.
318
319 %description -n python-subversion -l pt_BR.UTF-8
320 Módulos Python para acessar os recursos do Subversion.
321
322 %package -n python-csvn
323 Summary:        CTypes Subversion Python bindings
324 Summary(pl.UTF-8):      Dowiązania do Subversion dla Pythona
325 Summary(pt_BR.UTF-8):   Módulos Python para acessar os recursos do Subversion
326 Group:          Development/Languages/Python
327 %pyrequires_eq  python
328 Requires:       %{name}-libs = %{version}-%{release}
329
330 %description -n python-csvn
331 Subversion CTypes Python bindings.
332
333 %description -n python-csvn -l pl.UTF-8
334 Dowiązania do Subversion dla Pythona używające CTypes.
335
336 %description -n python-csvn -l pt_BR.UTF-8
337 Módulos Python para acessar os recursos do Subversion.
338
339 %package -n perl-subversion
340 Summary:        Subversion Perl bindings
341 Summary(pl.UTF-8):      Dowiązania do Subversion dla Perla
342 Summary(pt_BR.UTF-8):   Módulos Perl para acessar os recursos do Subversion
343 Group:          Development/Languages/Perl
344 Requires:       %{name}-libs = %{version}-%{release}
345 Obsoletes:      subversion-perl
346
347 %description -n perl-subversion
348 Subversion Perl bindings.
349
350 %description -n perl-subversion -l pl.UTF-8
351 Dowiązania do Subversion dla Perla.
352
353 %description -n perl-subversion -l pt_BR.UTF-8
354 Módulos Perl para acessar os recursos do Subversion.
355
356 %package -n ruby-subversion
357 Summary:        Subversion Ruby bindings
358 Summary(pl.UTF-8):      Dowiązania do Subversion dla języka Ruby
359 Summary(pt_BR.UTF-8):   Módulos Ruby para acessar os recursos do Subversion
360 Group:          Development/Languages
361 Requires:       %{name}-libs = %{version}-%{release}
362 Obsoletes:      subversion-ruby
363
364 %description -n ruby-subversion
365 Subversion Ruby bindings.
366
367 %description -n ruby-subversion -l pl.UTF-8
368 Dowiązania do Subversion dla języka Ruby.
369
370 %description -n ruby-subversion -l pt_BR.UTF-8
371 Módulos Ruby para acessar os recursos do Subversion.
372
373 %package -n apache-mod_dav_svn
374 Summary:        Apache module: Subversion Server
375 Summary(pl.UTF-8):      Moduł Apache'a: serwer Subversion
376 Group:          Networking/Daemons
377 Requires:       %{name} = %{version}-%{release}
378 Requires:       apache(modules-api) = %apache_modules_api
379 Requires:       apache-mod_dav
380
381 %description -n apache-mod_dav_svn
382 Apache module: Subversion Server.
383
384 %description -n apache-mod_dav_svn -l pl.UTF-8
385 Moduł Apache'a: serwer Subversion.
386
387 %package -n apache-mod_authz_svn
388 Summary:        Apache module: Subversion Server - path-based authorization
389 Summary(pl.UTF-8):      Moduł Apache'a: autoryzacja na podstawie ścieżki dla serwera Subversion
390 Group:          Networking/Daemons
391 Requires:       %{name}-libs = %{version}-%{release}
392 Requires:       apache(modules-api) = %apache_modules_api
393 Requires:       apache-mod_dav_svn = %{version}-%{release}
394
395 %description -n apache-mod_authz_svn
396 Apache module: Subversion Server - path-based authorization.
397
398 %description -n apache-mod_authz_svn -l pl.UTF-8
399 Moduł Apache'a: autoryzacja na podstawie ścieżki dla serwera
400 Subversion.
401
402 %package -n apache-mod_dontdothat_svn
403 Summary:        Apache module: Allows you to block specific svn requests
404 Summary(pl.UTF-8):      Moduł Apache'a pozwalający na blokowanie pewnych zapytań svn
405 Group:          Networking/Daemons
406 Requires:       %{name}-libs = %{version}-%{release}
407 Requires:       apache(modules-api) = %apache_modules_api
408 Requires:       apache-mod_dav_svn = %{version}-%{release}
409
410 %description -n apache-mod_dontdothat_svn
411 Apache module: Allows you to block specific svn requests.
412
413 %description -n apache-mod_dontdothat_svn -l pl.UTF-8
414 Moduł Apache'a pozwalający na blokowanie pewnych zapytań svn.
415
416 %package -n gnome-keyring-subversion
417 Summary:        GNOME Keyring authentication provider for Subversion
418 Summary(pl.UTF-8):      Moduł uwierzytelniający GNOME Keyring dla Subversion
419 Group:          X11/Applications
420 Requires:       %{name}-libs = %{version}-%{release}
421
422 %description -n gnome-keyring-subversion
423 Authentication provider module for Subversion which allows SVN client
424 to authenticate using GNOME Keyring.
425
426 %description -n gnome-keyring-subversion -l pl.UTF-8
427 Moduł uwierzytelniający dla Subversion pozwalający klientom SVN
428 uwierzytelniać się przy użyciu mechanizmu GNOME Keyring.
429
430 %package -n kde4-kwallet-subversion
431 Summary:        KDE Wallet authentication provider for Subversion
432 Summary(pl.UTF-8):      Moduł uwierzytelniający dla Subversion wykorzystujący Portfel KDE
433 Group:          X11/Applications
434 Requires:       %{name}-libs = %{version}-%{release}
435
436 %description -n kde4-kwallet-subversion
437 Authentication provider module for Subversion which allows SVN client
438 to authenticate using KDE Wallet.
439
440 %description -n kde4-kwallet-subversion -l pl.UTF-8
441 Moduł uwierzytelniający dla Subversion pozwalający klientom SVN
442 uwierzytelniać się przy użyciu Portfela KDE.
443
444 %prep
445 %setup -q
446 %patch0 -p0
447 %patch1 -p1
448 %patch2 -p0
449 %patch3 -p1
450 %patch4 -p2
451
452 sed -i -e 's#serf_prefix/lib#serf_prefix/%{_lib}#g' build/ac-macros/serf.m4
453
454 # serf.m4 macro is broken and ignores --without serf
455 %{?with_neon:sed -i -e 's#serf_found="yes"#serf_found="no"#g' build/ac-macros/serf.m4}
456
457 %build
458 # disabled regeneration - subversion 1.6.13 is not ready for swig 2.0.x
459 #%{__rm} subversion/bindings/swig/proxy/*.swg
460 #cd subversion/bindings/swig && python "%{SOURCE5}" && cd ../../..
461 chmod +x ./autogen.sh && ./autogen.sh
462 %{__libtoolize}
463 %configure \
464         --with-editor=vi \
465         --with-zlib=%{_libdir} \
466         --disable-runtime-module-search \
467         --disable-mod-activation \
468 %if %{with db}
469         --with-berkeley-db="db.h:%{_includedir}:%{_libdir}:db" \
470 %else
471         --without-berkeley-db \
472 %endif
473 %if %{with apache}
474         --with-apxs=%{_sbindir}/apxs \
475 %else
476         --without-apxs \
477 %endif
478 %if %{without swig}
479         --without-swig \
480 %endif
481 %if %{without ruby}
482         ac_cv_path_RUBY=none \
483 %endif
484 %if %{with csvn}
485         --with-ctypesgen=%{_bindir}/ctypesgen.py \
486 %endif
487 %if %{with javahl}
488         --enable-javahl \
489         --with-jdk="%{java_home}" \
490         --without-jikes \
491 %else
492         --disable-javahl \
493 %endif
494 %if %{with neon}
495         --without-serf \
496         --with-neon=%{_prefix} \
497         --disable-neon-version-check \
498 %else
499         --with-serf=%{_prefix} \
500         --without-neon \
501 %endif
502         --with-apr=%{_bindir}/apr-1-config \
503         --with-apr-util=%{_bindir}/apu-1-config \
504 %if %{with kwallet}
505         --with-kwallet \
506 %endif
507 %if %{with gnome}
508         --with-gnome-keyring
509 %endif
510
511 %{__make} -j1
512
513 %{__make} tools
514
515 %if %{with csvn}
516 # Python ctypes bindings
517 %{__make} ctypes-python
518 %endif
519 %if %{with python}
520 # Python swig bindings
521 %{__make} swig-py \
522         swig_pydir=%{py_sitedir}/libsvn \
523         swig_pydir_extra=%{py_sitedir}/svn
524 %endif
525 %if %{with perl}
526 # Perl swig bindings
527 %{__make} -j1 swig-pl-lib
528 cd subversion/bindings/swig/perl/native
529 %{__perl} Makefile.PL INSTALLDIRS=vendor
530 %{__make} -j1
531 cd -
532 %endif
533 %if %{with javahl}
534 %{__make} -j1 javahl \
535         javahl_javadir="%{_javadir}"
536 %endif
537 # ruby
538 %if %{with ruby}
539 %{__make} swig-rb
540 %endif
541
542 %if %{with tests}
543 %{__make} -j1 check
544 %if %{with csvn}
545 %{__make} -j1 check-ctypes-python
546 %endif
547 %if %{with python}
548 %{__make} -j1 check-swig-py
549 %endif
550 %if %{with perl}
551 %{__make} -j1 check-swig-pl
552 %endif
553 %if %{with ruby}
554 # disabled, see https://bugs.launchpad.net/pld-linux/+bug/734340
555 #%{__make} check-swig-rb
556 %endif
557 %endif
558
559 %install
560 rm -rf $RPM_BUILD_ROOT
561 install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig,bash_completion.d} \
562         $RPM_BUILD_ROOT{%{apacheconfdir},%{apachelibdir},%{_infodir}} \
563         $RPM_BUILD_ROOT%{_examplesdir}/{%{name}-%{version},python-%{name}-%{version}} \
564         $RPM_BUILD_ROOT%{_sysconfdir}/%{name} \
565         $RPM_BUILD_ROOT/home/services/subversion{,/repos}
566
567 %{__make} install -j1 \
568         toolsdir=%{_bindir} \
569         DESTDIR=$RPM_BUILD_ROOT \
570         APACHE_LIBEXECDIR="$(%{_sbindir}/apxs -q LIBEXECDIR)" \
571 %if %{with javahl}
572         install-javahl \
573         javahl_javadir="%{_javadir}" \
574 %endif
575 %if %{with python}
576         install-swig-py \
577         swig_pydir=%{py_sitedir}/libsvn \
578         swig_pydir_extra=%{py_sitedir}/svn \
579 %endif
580 %if %{with csvn}
581         install-ctypes-python \
582 %endif
583         install-tools
584
585 %if %{with ruby}
586 %{__make} install -j1 \
587         DESTDIR=$RPM_BUILD_ROOT \
588         install-swig-rb install-swig-rb-doc \
589
590 # not our package
591 %{__rm} -r $RPM_BUILD_ROOT%{ruby_ridir}/Kernel
592 %{__rm} -r $RPM_BUILD_ROOT%{ruby_ridir}/OptionParser
593 %{__rm} -r $RPM_BUILD_ROOT%{ruby_ridir}/Time
594 %{__rm} -r $RPM_BUILD_ROOT%{ruby_ridir}/Uconv
595 %{__rm} $RPM_BUILD_ROOT%{ruby_ridir}/cache.ri
596 %{__rm} $RPM_BUILD_ROOT%{ruby_ridir}/created.rid
597 %endif
598
599 %if %{with perl}
600 %{__make} install-swig-pl-lib \
601         DESTDIR=$RPM_BUILD_ROOT
602 %{__make} -C subversion/bindings/swig/perl/native install \
603         DESTDIR=$RPM_BUILD_ROOT \
604         PREFIX=$RPM_BUILD_ROOT%{_prefix} \
605         LIBDIR=$RPM_BUILD_ROOT%{_libdir}
606 %endif
607
608 %if %{with apache}
609 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{apacheconfdir}/65_mod_dav_svn.conf
610 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{apacheconfdir}/66_mod_authz_svn.conf
611 cp -p %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/svnserve
612 install -p %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/svnserve
613 %endif
614
615 %if %{without net_client_only}
616 install -p tools/backup/hot-backup.py $RPM_BUILD_ROOT%{_bindir}/svn-hot-backup
617 %endif
618
619 # rename not to conflict with standard packages. (are these needed at all?)
620 mv $RPM_BUILD_ROOT%{_bindir}/{,svn}diff
621 mv $RPM_BUILD_ROOT%{_bindir}/{,svn}diff3
622 mv $RPM_BUILD_ROOT%{_bindir}/{,svn}diff4
623
624 %if %{with python} || %{with csvn}
625 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
626 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
627 %py_postclean
628 %endif
629 %if %{with python}
630 %{__rm} $RPM_BUILD_ROOT%{py_sitedir}/libsvn/*.la
631 # .a created on ac only
632 %{__rm} -f $RPM_BUILD_ROOT%{py_sitedir}/libsvn/*.a
633 cp -p tools/examples/*.py $RPM_BUILD_ROOT%{_examplesdir}/python-%{name}-%{version}
634 %endif
635
636 cp -p tools/client-side/bash_completion $RPM_BUILD_ROOT/etc/bash_completion.d/%{name}
637 cp -p tools/examples/*.c $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
638
639 %if %{with javahl}
640 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libsvnjavahl*.{la,a}
641 %endif
642 %if %{with swig}
643 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libsvn_swig*.{la,a}
644 %if %{with ruby}
645 %{__rm} $RPM_BUILD_ROOT%{_libdir}/ruby/site_ruby/*/*/svn/ext/*.la
646 %endif
647 %endif
648 %if %{with gnome} || %{with kwallet}
649 # dlopened by soname (libsvn_auth_*-1.so.0)
650 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libsvn_auth_*-1.{so,la,a}
651 %endif
652
653 %find_lang %{name}
654
655 %clean
656 rm -rf $RPM_BUILD_ROOT
657
658 %pre svnserve
659 %groupadd -g 86 svn
660 %useradd -u 180 -d /home/services/subversion -c "Subversion svnserve" -g svn svn
661
662 %post   libs -p /sbin/ldconfig
663 %postun libs -p /sbin/ldconfig
664
665 %post   devel -p /sbin/postshell
666 -/usr/sbin/fix-info-dir -c %{_infodir}
667
668 %postun devel -p /sbin/postshell
669 -/usr/sbin/fix-info-dir -c %{_infodir}
670
671 %post   -n java-subversion -p /sbin/ldconfig
672 %postun -n java-subversion -p /sbin/ldconfig
673
674 %post   -n perl-subversion -p /sbin/ldconfig
675 %postun -n perl-subversion -p /sbin/ldconfig
676
677 %post   -n python-subversion -p /sbin/ldconfig
678 %postun -n python-subversion -p /sbin/ldconfig
679
680 %post   -n ruby-subversion -p /sbin/ldconfig
681 %postun -n ruby-subversion -p /sbin/ldconfig
682
683 %post   -n gnome-keyring-subversion -p /sbin/ldconfig
684 %postun -n gnome-keyring-subversion -p /sbin/ldconfig
685
686 %post   -n kde4-kwallet-subversion -p /sbin/ldconfig
687 %postun -n kde4-kwallet-subversion -p /sbin/ldconfig
688
689 %post svnserve
690 /sbin/chkconfig --add svnserve
691 %service svnserve restart "svnserve daemon"
692
693 %preun svnserve
694 if [ "$1" = "0" ]; then
695         %service svnserve stop
696         /sbin/chkconfig --del svnserve
697 fi
698
699 %postun svnserve
700 if [ "$1" = "0" ]; then
701         %userremove svn
702         %groupremove svn
703 fi
704
705 %post -n apache-mod_dav_svn
706 %service -q httpd restart
707
708 %postun -n apache-mod_dav_svn
709 if [ "$1" = "0" ]; then
710         %service -q httpd restart
711 fi
712
713 %post -n apache-mod_authz_svn
714 %service -q httpd restart
715
716 %postun -n apache-mod_authz_svn
717 if [ "$1" = "0" ]; then
718         %service -q httpd restart
719 fi
720
721 %post -n apache-mod_dontdothat_svn
722 %service -q httpd restart
723
724 %postun -n apache-mod_dontdothat_svn
725 if [ "$1" = "0" ]; then
726         %service -q httpd restart
727 fi
728
729 %files
730 %defattr(644,root,root,755)
731 %doc BUGS CHANGES INSTALL README
732 %doc doc/*/*.html
733 %doc tools/hook-scripts/*.{pl,py,example}
734 %doc tools/hook-scripts/mailer/*.{py,example}
735 %doc tools/xslt/*
736 %attr(755,root,root) %{_bindir}/svn
737 %attr(755,root,root) %{_bindir}/svnadmin
738 %attr(755,root,root) %{_bindir}/svndumpfilter
739 %attr(755,root,root) %{_bindir}/svnrdump
740 %attr(755,root,root) %{_bindir}/svnlook
741 %attr(755,root,root) %{_bindir}/svnsync
742 %attr(755,root,root) %{_bindir}/svnversion
743 %{_mandir}/man1/svn.1*
744 %{_mandir}/man1/svnadmin.1*
745 %{_mandir}/man1/svndumpfilter.1*
746 %{_mandir}/man1/svnrdump.1*
747 %{_mandir}/man1/svnlook.1*
748 %{_mandir}/man1/svnsync.1*
749 %{_mandir}/man1/svnversion.1*
750
751 %files libs -f %{name}.lang
752 %defattr(644,root,root,755)
753 %dir %{_sysconfdir}/%{name}
754 %attr(755,root,root) %{_libdir}/libsvn_client-1.so.*.*.*
755 %attr(755,root,root) %ghost %{_libdir}/libsvn_client-1.so.0
756 %attr(755,root,root) %{_libdir}/libsvn_delta-1.so.*.*.*
757 %attr(755,root,root) %ghost %{_libdir}/libsvn_delta-1.so.0
758 %attr(755,root,root) %{_libdir}/libsvn_diff-1.so.*.*.*
759 %attr(755,root,root) %ghost %{_libdir}/libsvn_diff-1.so.0
760 %attr(755,root,root) %{_libdir}/libsvn_fs-1.so.*.*.*
761 %attr(755,root,root) %ghost %{_libdir}/libsvn_fs-1.so.0
762 %if %{without net_client_only}
763 %attr(755,root,root) %{_libdir}/libsvn_fs_base-1.so.*.*.*
764 %attr(755,root,root) %ghost %{_libdir}/libsvn_fs_base-1.so.0
765 %endif
766 %attr(755,root,root) %{_libdir}/libsvn_fs_fs-1.so.*.*.*
767 %attr(755,root,root) %ghost %{_libdir}/libsvn_fs_fs-1.so.0
768 %attr(755,root,root) %{_libdir}/libsvn_fs_util-1.so.*.*.*
769 %attr(755,root,root) %ghost %{_libdir}/libsvn_fs_util-1.so.0
770 %attr(755,root,root) %{_libdir}/libsvn_ra-1.so.*.*.*
771 %attr(755,root,root) %ghost %{_libdir}/libsvn_ra-1.so.0
772 %attr(755,root,root) %{_libdir}/libsvn_ra_local-1.so.*.*.*
773 %attr(755,root,root) %ghost %{_libdir}/libsvn_ra_local-1.so.0
774 %attr(755,root,root) %{_libdir}/libsvn_ra_%{webdavlib}-1.so.*.*.*
775 %attr(755,root,root) %ghost %{_libdir}/libsvn_ra_%{webdavlib}-1.so.0
776 %attr(755,root,root) %{_libdir}/libsvn_ra_svn-1.so.*.*.*
777 %attr(755,root,root) %ghost %{_libdir}/libsvn_ra_svn-1.so.0
778 %attr(755,root,root) %{_libdir}/libsvn_repos-1.so.*.*.*
779 %attr(755,root,root) %ghost %{_libdir}/libsvn_repos-1.so.0
780 %attr(755,root,root) %{_libdir}/libsvn_subr-1.so.*.*.*
781 %attr(755,root,root) %ghost %{_libdir}/libsvn_subr-1.so.0
782 %attr(755,root,root) %{_libdir}/libsvn_wc-1.so.*.*.*
783 %attr(755,root,root) %ghost %{_libdir}/libsvn_wc-1.so.0
784
785 %files devel
786 %defattr(644,root,root,755)
787 %attr(755,root,root) %{_libdir}/libsvn_client-1.so
788 %attr(755,root,root) %{_libdir}/libsvn_delta-1.so
789 %attr(755,root,root) %{_libdir}/libsvn_diff-1.so
790 %attr(755,root,root) %{_libdir}/libsvn_fs-1.so
791 %if %{without net_client_only}
792 %attr(755,root,root) %{_libdir}/libsvn_fs_base-1.so
793 %endif
794 %attr(755,root,root) %{_libdir}/libsvn_fs_fs-1.so
795 %attr(755,root,root) %{_libdir}/libsvn_fs_util-1.so
796 %attr(755,root,root) %{_libdir}/libsvn_ra-1.so
797 %attr(755,root,root) %{_libdir}/libsvn_ra_local-1.so
798 %attr(755,root,root) %{_libdir}/libsvn_ra_%{webdavlib}-1.so
799 %attr(755,root,root) %{_libdir}/libsvn_ra_svn-1.so
800 %attr(755,root,root) %{_libdir}/libsvn_repos-1.so
801 %attr(755,root,root) %{_libdir}/libsvn_subr-1.so
802 %attr(755,root,root) %{_libdir}/libsvn_wc-1.so
803 %{_libdir}/libsvn_client-1.la
804 %{_libdir}/libsvn_delta-1.la
805 %{_libdir}/libsvn_diff-1.la
806 %{_libdir}/libsvn_fs-1.la
807 %if %{without net_client_only}
808 %{_libdir}/libsvn_fs_base-1.la
809 %endif
810 %{_libdir}/libsvn_fs_fs-1.la
811 %{_libdir}/libsvn_fs_util-1.la
812 %{_libdir}/libsvn_ra-1.la
813 %{_libdir}/libsvn_ra_local-1.la
814 %{_libdir}/libsvn_ra_%{webdavlib}-1.la
815 %{_libdir}/libsvn_ra_svn-1.la
816 %{_libdir}/libsvn_repos-1.la
817 %{_libdir}/libsvn_subr-1.la
818 %{_libdir}/libsvn_wc-1.la
819 %{_includedir}/%{name}-1
820 %{_examplesdir}/%{name}-%{version}
821
822 %files static
823 %defattr(644,root,root,755)
824 %{_libdir}/libsvn_client-1.a
825 %{_libdir}/libsvn_delta-1.a
826 %{_libdir}/libsvn_diff-1.a
827 %{_libdir}/libsvn_fs-1.a
828 %if %{without net_client_only}
829 %{_libdir}/libsvn_fs_base-1.a
830 %endif
831 %{_libdir}/libsvn_fs_fs-1.a
832 %{_libdir}/libsvn_fs_util-1.a
833 %{_libdir}/libsvn_ra-1.a
834 %{_libdir}/libsvn_ra_local-1.a
835 %{_libdir}/libsvn_ra_%{webdavlib}-1.a
836 %{_libdir}/libsvn_ra_svn-1.a
837 %{_libdir}/libsvn_repos-1.a
838 %{_libdir}/libsvn_subr-1.a
839 %{_libdir}/libsvn_wc-1.a
840
841 %if %{with gnome}
842 %files -n gnome-keyring-subversion
843 %defattr(644,root,root,755)
844 %attr(755,root,root) %{_libdir}/libsvn_auth_gnome_keyring-1.so.*.*.*
845 %attr(755,root,root) %ghost %{_libdir}/libsvn_auth_gnome_keyring-1.so.0
846 %endif
847
848 %if %{with kwallet}
849 %files -n kde4-kwallet-subversion
850 %defattr(644,root,root,755)
851 %attr(755,root,root) %{_libdir}/libsvn_auth_kwallet-1.so.*.*.*
852 %attr(755,root,root) %ghost %{_libdir}/libsvn_auth_kwallet-1.so.0
853 %endif
854
855 %if %{without net_client_only}
856 %files svnserve
857 %defattr(644,root,root,755)
858 %attr(755,root,root) %{_bindir}/svnserve
859 %{_mandir}/man5/svnserve.conf.5*
860 %{_mandir}/man8/svnserve.8*
861 %dir %attr(750,svn,svn) /home/services/subversion
862 %dir %attr(750,svn,svn) /home/services/subversion/repos
863 %if %{with apache}
864 %attr(754,root,root) /etc/rc.d/init.d/svnserve
865 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/svnserve
866 %endif
867
868 %files tools
869 %defattr(644,root,root,755)
870 # tools/backup/hot-backup.py
871 %attr(755,root,root) %{_bindir}/svn-hot-backup
872
873 # tools/diff
874 %attr(755,root,root) %{_bindir}/svndiff
875 %attr(755,root,root) %{_bindir}/svndiff3
876 %attr(755,root,root) %{_bindir}/svndiff4
877
878 # tools/server-side
879 %attr(755,root,root) %{_bindir}/svn-populate-node-origins-index
880 %attr(755,root,root) %{_bindir}/svn-rep-sharing-stats
881 %attr(755,root,root) %{_bindir}/svnauthz-validate
882
883 # tools/client-side/svnmucc
884 %attr(755,root,root) %{_bindir}/svnmucc
885 # tools/dev/svnraisetreeconflict
886 %attr(755,root,root) %{_bindir}/svnraisetreeconflict
887
888 %files -n bash-completion-subversion
889 %defattr(644,root,root,755)
890 /etc/bash_completion.d/%{name}
891
892 %endif # net_client_only
893
894 %if %{with javahl}
895 %files -n java-subversion
896 %defattr(644,root,root,755)
897 %attr(755,root,root) %{_libdir}/libsvnjavahl-1.so.*.*.*
898 %attr(755,root,root) %ghost %{_libdir}/libsvnjavahl-1.so.0
899 %attr(755,root,root) %{_libdir}/libsvnjavahl-1.so
900 %{_javadir}/svn-javahl.jar
901 %endif
902
903 %if %{with python}
904 %files -n python-subversion
905 %defattr(644,root,root,755)
906 %doc tools/backup/*.py
907 %attr(755,root,root) %{_libdir}/libsvn_swig_py-1.so.*.*.*
908 %attr(755,root,root) %ghost %{_libdir}/libsvn_swig_py-1.so.0
909 %attr(755,root,root) %{_libdir}/libsvn_swig_py-1.so
910 %dir %{py_sitedir}/libsvn
911 %attr(755,root,root) %{py_sitedir}/libsvn/_*.so
912 %{py_sitedir}/libsvn/*.py[co]
913 %dir %{py_sitedir}/svn
914 %{py_sitedir}/svn/*.py[co]
915 %{_examplesdir}/python-%{name}-%{version}
916 %endif
917
918 %if %{with csvn}
919 %files -n python-csvn
920 %defattr(644,root,root,755)
921 %doc subversion/bindings/ctypes-python/{README,TODO}
922 %doc subversion/bindings/ctypes-python/examples/*.py
923 %dir %{py_sitescriptdir}/csvn
924 %{py_sitescriptdir}/csvn/*.py[co]
925 %dir %{py_sitescriptdir}/csvn/core
926 %{py_sitescriptdir}/csvn/core/*.py[co]
927 %dir %{py_sitescriptdir}/csvn/ext
928 %{py_sitescriptdir}/csvn/ext/*.py[co]
929 %{py_sitescriptdir}/svn_ctypes_python_bindings-0.1-py*.egg-info
930 %endif
931
932 %if %{with perl}
933 %files -n perl-subversion
934 %defattr(644,root,root,755)
935 %attr(755,root,root) %{_libdir}/libsvn_swig_perl-1.so.*.*.*
936 %attr(755,root,root) %ghost %{_libdir}/libsvn_swig_perl-1.so.0
937 %attr(755,root,root) %{_libdir}/libsvn_swig_perl-1.so
938 %{perl_vendorarch}/SVN
939 %dir %{perl_vendorarch}/auto/SVN
940 %dir %{perl_vendorarch}/auto/SVN/*
941 %attr(755,root,root) %{perl_vendorarch}/auto/SVN/*/*.so
942 %{perl_vendorarch}/auto/SVN/*/*.bs
943 %{_mandir}/man3/*.3pm*
944 %endif
945
946 %if %{with ruby}
947 %files -n ruby-subversion
948 %defattr(644,root,root,755)
949 %attr(755,root,root) %{_libdir}/libsvn_swig_ruby-1.so.*.*.*
950 %attr(755,root,root) %ghost %{_libdir}/libsvn_swig_ruby-1.so.0
951 %attr(755,root,root) %{_libdir}/libsvn_swig_ruby-1.so
952 %dir %{ruby_sitelibdir}/svn
953 %{ruby_sitelibdir}/svn/*.rb
954 %dir %{ruby_sitearchdir}/svn
955 %dir %{ruby_sitearchdir}/svn/ext
956 %attr(755,root,root) %{ruby_sitearchdir}/svn/ext/*.so
957 %{ruby_ridir}/Svn
958 %endif
959
960 %if %{with apache}
961 %files -n apache-mod_dav_svn
962 %defattr(644,root,root,755)
963 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{apacheconfdir}/*_mod_dav_svn.conf
964 %attr(755,root,root) %{apachelibdir}/mod_dav_svn.so
965
966 %files -n apache-mod_authz_svn
967 %defattr(644,root,root,755)
968 %doc subversion/mod_authz_svn/INSTALL
969 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{apacheconfdir}/*_mod_authz_svn.conf
970 %attr(755,root,root) %{apachelibdir}/mod_authz_svn.so
971
972 %files -n apache-mod_dontdothat_svn
973 %defattr(644,root,root,755)
974 %doc tools/server-side/mod_dontdothat/README
975 %attr(755,root,root) %{apachelibdir}/mod_dontdothat.so
976 %endif
This page took 0.337115 seconds and 2 git commands to generate.