3 %bcond_without selinux # build without SELinux support
5 Summary: Userspace support for the device-mapper
6 Summary(pl): Wsparcie dla mapowania urz±dzeñ w przestrzeni u¿ytkownika
11 Group: Applications/System
12 Source0: ftp://sources.redhat.com/pub/dm/%{name}.%{version}.tgz
13 # Source0-md5: a2562b57e7cca026faa425fa5da92bbc
14 Patch0: %{name}-stack.patch
15 URL: http://sources.redhat.com/dm/
16 BuildRequires: autoconf
17 BuildRequires: automake
18 %{?with_selinux:BuildRequires: libselinux-devel >= 1.10}
19 %{?with_selinux:Requires: libselinux >= 1.10}
20 Conflicts: dev < 2.9.0-8
21 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23 %define _sbindir /sbin
26 The goal of this driver is to support volume management.
27 The driver enables the definition of new block devices composed of
28 ranges of sectors of existing devices. This can be used to define
29 disk partitions - or logical volumes. This light-weight kernel
30 component can support user-space tools for logical volume management.
33 Celem tego sterownika jest obs³uga zarz±dzania wolumenami.
34 Sterownik w³±cza definiowanie nowych urz±dzeñ blokowych z³o¿onych z
35 przedzia³ów sektorów na istniej±cych urz±dzeniach. Mo¿e to byæ
36 wykorzystane do definiowania partycji na dysku lub logicznych
37 wolumenów. Ten lekki sk³adnik j±dra mo¿e wspieraæ dzia³aj±ce w
38 przestrzeni u¿ytkownika narzêdzia do zarz±dzania logicznymi
42 Summary: Header files and development documentation for %{name}
43 Summary(pl): Pliki nag³ówkowe i dokumentacja do %{name}
44 Group: Development/Libraries
45 Requires: %{name} = %{version}-%{release}
48 Header files and development documentation for %{name}.
50 %description devel -l pl
51 Pliki nag³ówkowe i dokumentacja do %{name}.
54 Summary: Static devmapper library
55 Summary(pl): Statyczna biblioteka devmapper
56 Group: Development/Libraries
57 Requires: %{name}-devel = %{version}-%{release}
60 Static devmapper library.
62 %description static -l pl
63 Statyczna biblioteka devmapper.
66 %setup -q -n %{name}.%{version}
70 cp -f /usr/share/automake/config.sub autoconf
74 SELINUX=%{?with_selinux:yes}%{!?with_selinux:no} \
75 --with-optimisation="%{rpmcflags}" \
76 --with-user=%(id -u) \
77 --with-group=%(id -g) \
78 --with-interface=ioctl
81 ar cru libdevmapper.a lib/ioctl/*.o lib/*.o
85 rm -rf $RPM_BUILD_ROOT
86 install -d $RPM_BUILD_ROOT{/%{_lib},%{_libdir}/%{name}}
89 DESTDIR=$RPM_BUILD_ROOT
91 SONAME=$(basename $(ls -1 $RPM_BUILD_ROOT%{_libdir}/lib*.so.*.*))
92 ln -sf /%{_lib}/${SONAME} $RPM_BUILD_ROOT%{_libdir}/libdevmapper.so
93 mv -f $RPM_BUILD_ROOT%{_libdir}/lib*.so.*.* $RPM_BUILD_ROOT/%{_lib}
94 cp -f scripts/* $RPM_BUILD_ROOT%{_libdir}/%{name}
96 install libdevmapper.a $RPM_BUILD_ROOT%{_libdir}
99 rm -rf $RPM_BUILD_ROOT
101 %post -p /sbin/ldconfig
102 %postun -p /sbin/ldconfig
105 %defattr(644,root,root,755)
106 %doc INTRO INSTALL README
107 %attr(755,root,root) %{_sbindir}/*
108 %attr(755,root,root) /%{_lib}/lib*.so.*.*
109 %dir %{_libdir}/%{name}
110 %attr(755,root,root) %{_libdir}/%{name}/*
114 %defattr(644,root,root,755)
115 %attr(755,root,root) %{_libdir}/libdevmapper.so
119 %defattr(644,root,root,755)