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