]> git.pld-linux.org Git - packages/drbd.git/blobdiff - drbd.spec
- up to 8.2.5
[packages/drbd.git] / drbd.spec
index 691ae9e1cff517950fa71f26257176730cb79169..fe84b773e9fc452bd8d05914915ecc851e60731e 100644 (file)
--- a/drbd.spec
+++ b/drbd.spec
@@ -6,21 +6,32 @@
 %bcond_with    verbose         # verbose build (V=1)
 %bcond_with    grsec_kernel    # build for kernel-grsecurity
 #
+%ifarch sparc
+%undefine      with_smp
+%endif
+
+%if %{without kernel}
+%undefine      with_dist_kernel
+%endif
 %if %{with kernel} && %{with dist_kernel} && %{with grsec_kernel}
 %define        alt_kernel      grsecurity
 %endif
-#
-%define        _rel    1
+%if "%{_alt_kernel}" != "%{nil}"
+%undefine      with_userspace
+%endif
+
+%define                _rel    1
+%define                pname   drbd
 Summary:       drbd is a block device designed to build high availibility clusters
 Summary(pl.UTF-8):     drbd jest urządzeniem blokowym dla klastrów o wysokiej niezawodności
-Name:          drbd
-Version:       8.0.5
+Name:          %{pname}%{_alt_kernel}
+Version:       8.2.5
 Release:       %{_rel}
 License:       GPL
 Group:         Base/Kernel
-Source0:       http://oss.linbit.com/drbd/8.0/%{name}-%{version}.tar.gz
-# Source0-md5: b5463772f1749e86c8c29e56b0e9938b
-Patch0:                %{name}-Makefile.patch
+Source0:       http://oss.linbit.com/drbd/8.2/%{pname}-%{version}.tar.gz
+# Source0-md5: f3297c1d032fd90cd0441285fef05bcb
+Patch0:                %{pname}-Makefile.patch
 URL:           http://www.drbd.org/
 %if %{with userspace}
 BuildRequires: bison
@@ -53,7 +64,11 @@ Summary(pl.UTF-8):   Narzędzie konfiguracyjne i skrypty dla DRBD
 Summary(pt_BR.UTF-8):  Utilitários para gerenciar dispositivos DRBD
 Group:         Applications/System
 Requires(post,preun):  /sbin/chkconfig
+Requires(pre): /usr/bin/getgid
+Requires(pre): /usr/sbin/groupadd
+Requires(postun):      /usr/sbin/groupdel
 Requires:      rc-scripts
+Provides:      group(haclient)
 Conflicts:     drbdsetup24
 
 %description -n drbdsetup
@@ -82,7 +97,7 @@ niezawodności. drbd działa jako mirroring całego urządzenia blokowego
 przez (dedykowaną) sieć. Może być widoczny jako sieciowy RAID1.
 
 %prep
-%setup -q
+%setup -q -n %{pname}-%{version}
 %patch0 -p1
 
 %build
@@ -131,6 +146,9 @@ rm -rf $RPM_BUILD_ROOT
 %postun -n kernel%{_alt_kernel}-block-drbd
 %depmod %{_kernel_ver}
 
+%pre -n drbdsetup
+%groupadd -g 60 haclient
+
 %post -n drbdsetup
 /sbin/chkconfig --add drbd
 %service drbd restart
@@ -141,10 +159,18 @@ if [ "$1" = "0" ]; then
        /sbin/chkconfig --del drbd
 fi
 
+%postun -n drbdsetup
+if [ "$1" = "0" ]; then
+       %groupremove haclient
+fi
+
+
 %if %{with userspace}
 %files -n drbdsetup
 %defattr(644,root,root,755)
-%attr(755,root,root) /sbin/*
+%attr(755,root,root) /sbin/drbdadm
+%attr(2754,root,haclient) /sbin/drbdsetup
+%attr(2754,root,haclient) /sbin/drbdmeta
 %attr(754,root,root) /etc/rc.d/init.d/drbd
 %attr(755,root,root) %{_sysconfdir}/ha.d/resource.d/drbddisk
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/drbd.conf
This page took 0.19976 seconds and 4 git commands to generate.