]>
Commit | Line | Data |
---|---|---|
1 | # | |
2 | # Conditonal build: | |
3 | %bcond_without initrd # don't build initrd version | |
4 | # | |
5 | %define realname cryptsetup | |
6 | Summary: LUKS for dm-crypt implemented in cryptsetup | |
7 | Summary(pl.UTF-8): LUKS dla dm-crypta zaimplementowany w cryptsetup | |
8 | Name: cryptsetup-luks | |
9 | Version: 1.0.6 | |
10 | Release: 4 | |
11 | License: GPL v2 | |
12 | Group: Base | |
13 | Source0: http://luks.endorphin.org/source/%{realname}-%{version}.tar.bz2 | |
14 | # Source0-md5: 00d452eb7a76e39f5749545d48934a10 | |
15 | Patch1: %{name}-nostatic.patch | |
16 | URL: http://luks.endorphin.org/ | |
17 | BuildRequires: autoconf | |
18 | BuildRequires: automake | |
19 | BuildRequires: device-mapper-devel | |
20 | BuildRequires: gettext-devel | |
21 | BuildRequires: libgcrypt-devel >= 1.1.42 | |
22 | BuildRequires: libselinux-devel | |
23 | BuildRequires: libsepol-devel | |
24 | BuildRequires: libtool | |
25 | BuildRequires: libuuid-devel | |
26 | BuildRequires: popt-devel | |
27 | %if %{with initrd} | |
28 | BuildRequires: device-mapper-static >= 1.02.07 | |
29 | BuildRequires: libgcrypt-static >= 1.1.42 | |
30 | BuildRequires: libgpg-error-static | |
31 | BuildRequires: libselinux-static | |
32 | BuildRequires: libsepol-static | |
33 | BuildRequires: libuuid-static | |
34 | BuildRequires: popt-static | |
35 | %endif | |
36 | Provides: cryptsetup = %{version} | |
37 | Obsoletes: cryptsetup | |
38 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
39 | ||
40 | %define _sbindir /sbin | |
41 | %define _noautoreqdep libcryptsetup.so.0 | |
42 | ||
43 | %description | |
44 | LUKS is the upcoming standard for Linux hard disk encryption. By | |
45 | providing a standard on-disk-format, it does not only facilitate | |
46 | compatibility among distributions, but also provide secure management | |
47 | of multiple user passwords. In contrast to existing solution, LUKS | |
48 | stores all setup necessary setup information in the partition header, | |
49 | enabling the user to transport or migrate his data seamlessly. | |
50 | ||
51 | This package contains implementation of LUKS for dm-crypt implemented | |
52 | in cryptsetup. | |
53 | ||
54 | %description -l pl.UTF-8 | |
55 | LUKS to nadchodzący standard linuksowego szyfrowania twardego dysku. | |
56 | Dostarczając standardowy format danych na dysku nie tylko ułatwia | |
57 | utrzymanie kompatybilności między dystrybucjami, ale także dostarcza | |
58 | bezpieczne zarządzanie wieloma hasłami użytkowników. W przeciwieństwie | |
59 | do istniejącego rozwiązania LUKS przechowuje wszystkie potrzebne | |
60 | informacje o konfiguracji w nagłówku partycji, pozwalając | |
61 | użytkownikowi przenosić lub migrować dane w sposób przezroczysty. | |
62 | ||
63 | Ten pakiet zawiera implementację LUKS dla dm-crytpa zaimplementowaną w | |
64 | cryptsetup. | |
65 | ||
66 | %package devel | |
67 | Summary: Header files for cryptsetup library | |
68 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki cryptsetup | |
69 | Group: Development/Libraries | |
70 | Requires: %{name} = %{version}-%{release} | |
71 | Requires: device-mapper-devel | |
72 | Requires: libgcrypt-devel >= 1.1.42 | |
73 | Obsoletes: cryptsetup-devel | |
74 | ||
75 | %description devel | |
76 | Header files for cryptsetup library. | |
77 | ||
78 | %description devel -l pl.UTF-8 | |
79 | Pliki nagłówkowe biblioteki cryptsetup. | |
80 | ||
81 | %package static | |
82 | Summary: Static cryptsetup library | |
83 | Summary(pl.UTF-8): Statyczna biblioteka cryptsetup | |
84 | Group: Development/Libraries | |
85 | Requires: %{name}-devel = %{version}-%{release} | |
86 | Obsoletes: cryptsetup-static | |
87 | ||
88 | %description static | |
89 | Static version of cryptsetup library. | |
90 | ||
91 | %description static -l pl.UTF-8 | |
92 | Statyczna wersja biblioteki cryptsetup. | |
93 | ||
94 | %package initrd | |
95 | Summary: LUKS for dm-crypt implemented in cryptsetup - initrd version | |
96 | Group: Base | |
97 | ||
98 | %description initrd | |
99 | This package contains implementation of LUKS for dm-crypt implemented | |
100 | in cryptsetup - staticaly linked for initrd. | |
101 | ||
102 | %prep | |
103 | %setup -q -n %{realname}-%{version} | |
104 | %patch1 -p1 | |
105 | ||
106 | %build | |
107 | %{__gettextize} | |
108 | %{__libtoolize} | |
109 | %{__aclocal} -I m4 | |
110 | %{__autoconf} | |
111 | %{__autoheader} | |
112 | %{__automake} | |
113 | ||
114 | %if %{with initrd} | |
115 | %configure \ | |
116 | --disable-shared-library \ | |
117 | --enable-static \ | |
118 | --enable-static-cryptsetup \ | |
119 | --disable-nls | |
120 | %{__make} | |
121 | mv src/cryptsetup cryptsetup-initrd | |
122 | %{__make} clean | |
123 | %endif | |
124 | ||
125 | %configure \ | |
126 | --enable-static | |
127 | %{__make} | |
128 | ||
129 | %install | |
130 | rm -rf $RPM_BUILD_ROOT | |
131 | ||
132 | %{__make} install \ | |
133 | DESTDIR=$RPM_BUILD_ROOT | |
134 | ||
135 | install -d $RPM_BUILD_ROOT/%{_lib} | |
136 | mv -f $RPM_BUILD_ROOT%{_libdir}/libcryptsetup.so.* $RPM_BUILD_ROOT/%{_lib} | |
137 | ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libcryptsetup.so.*.*.*) \ | |
138 | $RPM_BUILD_ROOT%{_libdir}/libcryptsetup.so | |
139 | ||
140 | %if %{with initrd} | |
141 | install cryptsetup-initrd $RPM_BUILD_ROOT%{_sbindir} | |
142 | %endif | |
143 | ||
144 | %find_lang %{realname} | |
145 | ||
146 | %clean | |
147 | rm -rf $RPM_BUILD_ROOT | |
148 | ||
149 | %post -p /sbin/ldconfig | |
150 | %postun -p /sbin/ldconfig | |
151 | ||
152 | %files -f %{realname}.lang | |
153 | %defattr(644,root,root,755) | |
154 | %doc AUTHORS ChangeLog TODO | |
155 | %attr(755,root,root) %{_sbindir}/cryptsetup | |
156 | %attr(755,root,root) /%{_lib}/libcryptsetup.so.*.*.* | |
157 | %attr(755,root,root) %ghost /%{_lib}/libcryptsetup.so.0 | |
158 | %{_mandir}/man8/cryptsetup.8* | |
159 | ||
160 | %files devel | |
161 | %defattr(644,root,root,755) | |
162 | %attr(755,root,root) %{_libdir}/libcryptsetup.so | |
163 | %{_libdir}/libcryptsetup.la | |
164 | %{_includedir}/libcryptsetup.h | |
165 | ||
166 | %files static | |
167 | %defattr(644,root,root,755) | |
168 | %{_libdir}/libcryptsetup.a | |
169 | ||
170 | %if %{with initrd} | |
171 | %files initrd | |
172 | %defattr(644,root,root,755) | |
173 | %attr(755,root,root) %{_sbindir}/cryptsetup-initrd | |
174 | %endif |