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