]> git.pld-linux.org Git - packages/dmraid.git/blob - dmraid.spec
b2d6a1d8d42f02dae2352804d6ee945862e5cc15
[packages/dmraid.git] / dmraid.spec
1 #
2 # Conditional build:
3 %bcond_without  initrd  # without initrd version
4 #
5 Summary:        Device-mapper RAID tool
6 Summary(pl):    Narzêdzie do RAID-u opartego o device-mapper
7 Name:           dmraid
8 Version:        1.0.0
9 %define _rc rc10
10 %define _rel 1
11 Release:        0.%{_rc}.%{_rel}
12 License:        GPL
13 Group:          Base
14 Source0:        http://people.redhat.com/~heinzm/sw/dmraid/src/%{name}-%{version}.%{_rc}.tar.bz2
15 # Source0-md5:  0206f8166bfdc370c4ee8efcb35af111
16 Patch0:         %{name}-selinux-static.patch
17 URL:            http://people.redhat.com/~heinzm/sw/dmraid/
18 BuildRequires:  autoconf
19 BuildRequires:  automake
20 BuildRequires:  device-mapper-devel >= 1.01.01
21 %{?with_initrd:BuildRequires:   device-mapper-static}
22 %{?with_initrd:BuildRequires:   glibc-static}
23 %{?with_initrd:BuildRequires:   libselinux-static}
24 %{?with_initrd:BuildRequires:   libsepol-static}
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %description
28 DMRAID supports device discovery, set activation and display of
29 properties for ATARAID on Linux >= 2.4 using device-mapper.
30
31 %description -l pl
32 DMRAID obs³uguje wykrywanie urz±dzeñ, ustawianie aktywacji i
33 wy¶wietlanie w³a¶ciwo¶ci ATARAID-u na Linuksie >= 2.4 przy u¿yciu
34 device-mappera.
35
36 %package initrd
37 Summary:        Device-mapper RAID tool - statically linked version
38 Summary(pl):    Narzêdzie do RAID-u opartego o device-mapper - wersja statyczna
39 Group:          Base
40
41 %description initrd
42 Statically linked version of dmraid utility.
43
44 %description initrd -l pl
45 Statycznie skonsolidowana wersja programu narzêdziowego dmraid.
46
47 %prep
48 %setup -q -n %{name}
49 mv */* ./
50 %patch0 -p2
51
52 %build
53 cp -f /usr/share/automake/config.sub autoconf
54 %{__aclocal}
55 %{__autoconf}
56
57 %if %{with initrd}
58 %configure \
59         --enable-static_link
60 %{__make} \
61         CC="%{__cc}" \
62         CFLAGS="%{rpmcflags}"
63 cp -f tools/dmraid{,-initrd}
64 %{__make} clean
65 %endif
66
67 %configure
68 %{__make} \
69         CC="%{__cc}" \
70         CFLAGS="%{rpmcflags}"
71
72 %install
73 rm -rf $RPM_BUILD_ROOT
74
75 install -D tools/dmraid $RPM_BUILD_ROOT%{_sbindir}/dmraid
76 %{?with_initrd:install -D tools/dmraid-initrd $RPM_BUILD_ROOT/sbin/dmraid-initrd}
77 install -D man/dmraid.8 $RPM_BUILD_ROOT%{_mandir}/man8/dmraid.8
78
79 %clean
80 rm -rf $RPM_BUILD_ROOT
81
82 %files
83 %defattr(644,root,root,755)
84 %doc README TODO doc/dmraid_design.txt
85 %attr(755,root,root) %{_sbindir}/*
86 %{_mandir}/man8/*
87
88 %if %{with initrd}
89 %files initrd
90 %defattr(644,root,root,755)
91 %attr(755,root,root) /sbin/*
92 %endif
This page took 0.087997 seconds and 3 git commands to generate.