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