]> git.pld-linux.org Git - packages/cryptsetup.git/blame - cryptsetup.spec
- updated to 1.5.0 (initrd not tested)
[packages/cryptsetup.git] / cryptsetup.spec
CommitLineData
5eb10616
JB
1#
2# Conditonal build:
21d48aec 3%bcond_without initrd # don't build initrd version
c2608e02 4%bcond_with dietlibc # build initrd version with static glibc instead of dietlibc
882a770e 5%bcond_without python # Python binding
ef897fda 6
2488c838 7Summary: LUKS for dm-crypt implemented in cryptsetup
29f5822a 8Summary(pl.UTF-8): LUKS dla dm-crypta zaimplementowany w cryptsetup
ef897fda 9Name: cryptsetup
56c60c79 10Version: 1.5.0
d2b984dc 11Release: 1
d7593791 12License: GPL v2
6351d6a5 13Group: Base
28c8b65f 14# Source0Download: http://code.google.com/p/cryptsetup/downloads/list
ef897fda 15Source0: http://cryptsetup.googlecode.com/files/%{name}-%{version}.tar.bz2
56c60c79 16# Source0-md5: 0fa7ba8923b0ce8eed2aa65f2cb9950c
ef897fda 17Patch0: diet.patch
79b6c53c 18URL: http://code.google.com/p/cryptsetup/
c905abc3 19BuildRequires: autoconf >= 2.67
5fe93676 20BuildRequires: automake
79b6c53c
JB
21BuildRequires: device-mapper-devel >= 1.02.03
22BuildRequires: gettext-devel >= 0.15
0b90291e
JB
23BuildRequires: libgcrypt-devel >= 1.1.42
24BuildRequires: libselinux-devel
25BuildRequires: libsepol-devel
c905abc3 26BuildRequires: libtool >= 2:2.0
0b90291e 27BuildRequires: libuuid-devel
79b6c53c 28BuildRequires: popt-devel >= 1.7
ef897fda
ER
29Provides: cryptsetup-luks = %{version}-%{release}
30Obsoletes: cryptsetup-luks < 1.4.1-2
882a770e
JB
31%if %{with python}
32BuildRequires: python-devel >= 1:2.4
33BuildRequires: rpm-pythonprov
34%endif
d07d45f7 35%if %{with initrd}
21d48aec
JR
36BuildRequires: libgpg-error-static
37 %if %{with dietlibc}
38BuildRequires: device-mapper-dietlibc
ef897fda 39BuildRequires: dietlibc-static
21d48aec
JR
40BuildRequires: libgcrypt-dietlibc
41BuildRequires: libuuid-dietlibc
42BuildRequires: popt-dietlibc
43 %else
5eb10616 44BuildRequires: device-mapper-static >= 1.02.07
a6fd3218 45BuildRequires: libgcrypt-static >= 1.1.42
a6fd3218 46BuildRequires: libselinux-static
8d9e50de 47BuildRequires: libsepol-static
a6fd3218 48BuildRequires: libuuid-static
49BuildRequires: popt-static
c2608e02 50BuildRequires: udev-static
21d48aec 51 %endif
5eb10616 52%endif
79b6c53c 53Requires: popt >= 1.7
c0cc5702 54Provides: cryptsetup = %{version}
12cca230 55Obsoletes: cryptsetup
751c89df
ER
56Conflicts: udev < 1:118-1
57Conflicts: udev-core < 1:115
6351d6a5 58BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
59
60%define _sbindir /sbin
61
62%description
6e98e6fb 63LUKS is the upcoming standard for Linux hard disk encryption. By
64providing a standard on-disk-format, it does not only facilitate
65compatibility among distributions, but also provide secure management
66of multiple user passwords. In contrast to existing solution, LUKS
67stores all setup necessary setup information in the partition header,
68enabling the user to transport or migrate his data seamlessly.
6351d6a5 69
6e98e6fb 70This package contains implementation of LUKS for dm-crypt implemented
71in cryptsetup.
6351d6a5 72
77f30028
JR
73%description -l pl.UTF-8
74LUKS to nadchodzący standard linuksowego szyfrowania twardego dysku.
75Dostarczając standardowy format danych na dysku nie tylko ułatwia
76utrzymanie kompatybilności między dystrybucjami, ale także dostarcza
77bezpieczne zarządzanie wieloma hasłami użytkowników. W przeciwieństwie
78do istniejącego rozwiązania LUKS przechowuje wszystkie potrzebne
79informacje o konfiguracji w nagłówku partycji, pozwalając
80użytkownikowi przenosić lub migrować dane w sposób przezroczysty.
12cca230 81
77f30028 82Ten pakiet zawiera implementację LUKS dla dm-crytpa zaimplementowaną w
12cca230
JB
83cryptsetup.
84
6351d6a5 85%package devel
86Summary: Header files for cryptsetup library
29f5822a 87Summary(pl.UTF-8): Pliki nagłówkowe biblioteki cryptsetup
6351d6a5 88Group: Development/Libraries
89Requires: %{name} = %{version}-%{release}
90Requires: device-mapper-devel
91Requires: libgcrypt-devel >= 1.1.42
ef897fda
ER
92Provides: cryptsetup-luks-devel = %{version}-%{release}
93Obsoletes: cryptsetup-luks-devel < 1.4.1-2
6351d6a5 94
95%description devel
96Header files for cryptsetup library.
97
77f30028
JR
98%description devel -l pl.UTF-8
99Pliki nagłówkowe biblioteki cryptsetup.
6351d6a5 100
101%package static
102Summary: Static cryptsetup library
29f5822a 103Summary(pl.UTF-8): Statyczna biblioteka cryptsetup
6351d6a5 104Group: Development/Libraries
105Requires: %{name}-devel = %{version}-%{release}
ef897fda
ER
106Provides: cryptsetup-luks-static = %{version}-%{release}
107Obsoletes: cryptsetup-luks-static < 1.4.1-2
6351d6a5 108
109%description static
110Static version of cryptsetup library.
111
77f30028 112%description static -l pl.UTF-8
6351d6a5 113Statyczna wersja biblioteki cryptsetup.
114
882a770e
JB
115%package -n python-pycryptsetup
116Summary: Python binding for cryptsetup library
117Summary(pl.UTF-8): Wiązanie Pythona do biblioteki cryptsetup
118Group: Libraries/Python
28c8b65f 119Requires: %{name} = %{version}-%{release}
882a770e
JB
120%pyrequires_eq python-libs
121
122%description -n python-pycryptsetup
123Python binding for cryptsetup library.
124
125%description -n python-pycryptsetup -l pl.UTF-8
126Wiązanie Pythona do biblioteki cryptsetup.
127
d07d45f7
ER
128%package initrd
129Summary: LUKS for dm-crypt implemented in cryptsetup - initrd version
1c89131c 130Summary(pl.UTF-8): LUKS dla dm-crypta zaimplementowany w cryptsetup - wersja initrd
d07d45f7 131Group: Base
311e3692 132Requires: udev-initrd >= 1:115
ef897fda
ER
133Provides: cryptsetup-luks-initrd = %{version}-%{release}
134Obsoletes: cryptsetup-luks-initrd < 1.4.1-2
2dd5e1c3 135Conflicts: geninitrd < 10000.10
d07d45f7
ER
136
137%description initrd
138This package contains implementation of LUKS for dm-crypt implemented
1c89131c
JB
139in cryptsetup - statically linked for initrd.
140
141%description initrd -l pl.UTF-8
ef897fda
ER
142Ten pakiet zawiera implementację LUKS dla dm-crypta zaimplementowaną w
143cryptsetup - wersję statycznie zlinkowaną dla initrd.
d07d45f7 144
6351d6a5 145%prep
ef897fda 146%setup -q
79b6c53c 147%patch0 -p1
6351d6a5 148
c627e74c
JB
149%{__rm} po/stamp-po
150
6351d6a5 151%build
8d9e50de 152%{__gettextize}
d7593791 153%{__libtoolize}
8d9e50de 154%{__aclocal} -I m4
155%{__autoconf}
d7593791 156%{__autoheader}
8d9e50de 157%{__automake}
d07d45f7
ER
158
159%if %{with initrd}
802ed4ef 160CC="%{__cc}"
a6fd3218 161%configure \
21d48aec 162%if %{with dietlibc}
04af2f11 163 CC="diet ${CC#ccache } %{rpmcppflags} %{rpmcflags} %{rpmldflags} -Os" \
8a7a87e4 164 LIBS="-lcompat" \
21d48aec
JR
165 ac_cv_lib_popt_poptConfigFileToString=yes \
166 ac_cv_lib_sepol_sepol_bool_set=no \
167 ac_cv_lib_selinux_is_selinux_enabled=no \
802ed4ef
ER
168%endif
169%if "%{?configure_cache}" == "1"
170 --cache-file=%{?configure_cache_file}%{!?configure_cache_file:configure}-initrd.cache \
21d48aec 171%endif
8a7a87e4 172 --disable-shared \
5eb10616 173 --enable-static \
d6925a9f
ER
174 --enable-static-cryptsetup \
175 --disable-nls
21d48aec 176
21d48aec
JR
177%{__make} -C lib
178
179%if %{with dietlibc}
180# we have to do it by hand cause libtool "know better" and forces
181# static libs from /usr/lib
802ed4ef 182CC="%{__cc}"
04af2f11 183diet ${CC#ccache } %{rpmcppflags} %{rpmcflags} %{rpmldflags} -Os -I. -I./lib -static \
593621cb
JR
184 -o cryptsetup-initrd src/cryptsetup.c ./lib/.libs/libcryptsetup.a \
185 -lpopt -lgcrypt -lgpg-error -ldevmapper -luuid -lcompat
21d48aec
JR
186%else
187%{__make} -C src
d07d45f7 188mv src/cryptsetup cryptsetup-initrd
21d48aec 189%endif
23904b26 190
d07d45f7
ER
191%{__make} clean
192%endif
193
194%configure \
04af2f11 195 --enable-udev \
882a770e
JB
196 --enable-static \
197 %{?with_python:--enable-python}
6351d6a5 198%{__make}
199
200%install
201rm -rf $RPM_BUILD_ROOT
202
203%{__make} install \
204 DESTDIR=$RPM_BUILD_ROOT
205
206install -d $RPM_BUILD_ROOT/%{_lib}
d7593791
JB
207mv -f $RPM_BUILD_ROOT%{_libdir}/libcryptsetup.so.* $RPM_BUILD_ROOT/%{_lib}
208ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libcryptsetup.so.*.*.*) \
6351d6a5 209 $RPM_BUILD_ROOT%{_libdir}/libcryptsetup.so
210
d07d45f7 211%if %{with initrd}
927d0cdf 212install -d $RPM_BUILD_ROOT%{_libdir}/initrd
802ed4ef 213install -p cryptsetup-initrd $RPM_BUILD_ROOT%{_libdir}/initrd/cryptsetup
d07d45f7
ER
214%endif
215
882a770e
JB
216%{?with_python:%{__rm} $RPM_BUILD_ROOT%{py_sitedir}/pycryptsetup.{la,a}}
217
ef897fda 218%find_lang %{name}
6351d6a5 219
220%clean
221rm -rf $RPM_BUILD_ROOT
222
223%post -p /sbin/ldconfig
224%postun -p /sbin/ldconfig
225
ef897fda 226%files -f %{name}.lang
6351d6a5 227%defattr(644,root,root,755)
d7593791 228%doc AUTHORS ChangeLog TODO
6351d6a5 229%attr(755,root,root) %{_sbindir}/cryptsetup
56c60c79 230%attr(755,root,root) %{_sbindir}/veritysetup
6351d6a5 231%attr(755,root,root) /%{_lib}/libcryptsetup.so.*.*.*
c6c27d69 232%attr(755,root,root) %ghost /%{_lib}/libcryptsetup.so.4
d7593791 233%{_mandir}/man8/cryptsetup.8*
56c60c79 234%{_mandir}/man8/veritysetup.8*
6351d6a5 235
236%files devel
237%defattr(644,root,root,755)
238%attr(755,root,root) %{_libdir}/libcryptsetup.so
239%{_libdir}/libcryptsetup.la
d7593791 240%{_includedir}/libcryptsetup.h
79b6c53c 241%{_pkgconfigdir}/libcryptsetup.pc
6351d6a5 242
a6fd3218 243%files static
244%defattr(644,root,root,755)
245%{_libdir}/libcryptsetup.a
d07d45f7 246
882a770e
JB
247%if %{with python}
248%files -n python-pycryptsetup
249%defattr(644,root,root,755)
250%attr(755,root,root) %{py_sitedir}/pycryptsetup.so
251%endif
252
d07d45f7
ER
253%if %{with initrd}
254%files initrd
255%defattr(644,root,root,755)
927d0cdf 256%attr(755,root,root) %{_libdir}/initrd/cryptsetup
d07d45f7 257%endif
This page took 0.086677 seconds and 4 git commands to generate.