2007-06-05 04:29:16 +02:00
|
|
|
#
|
2011-02-02 01:35:12 +01:00
|
|
|
# spec file for package cryptsetup
|
2007-06-05 04:29:16 +02:00
|
|
|
#
|
2013-03-13 17:21:37 +01:00
|
|
|
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2007-06-05 04:29:16 +02:00
|
|
|
#
|
2008-08-08 17:19:08 +02:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2007-06-05 04:29:16 +02:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
Name: cryptsetup
|
2012-04-16 11:57:35 +02:00
|
|
|
Url: http://code.google.com/p/cryptsetup/
|
2013-08-26 10:24:57 +02:00
|
|
|
Version: 1.6.2
|
2013-03-26 12:48:10 +01:00
|
|
|
Release: 0
|
|
|
|
Summary: Set Up dm-crypt Based Encrypted Block Devices
|
|
|
|
License: SUSE-GPL-2.0-with-openssl-exception and LGPL-2.0+
|
|
|
|
Group: System/Base
|
|
|
|
|
|
|
|
Source: http://cryptsetup.googlecode.com/files/cryptsetup-%version.tar.bz2
|
|
|
|
Source1: http://cryptsetup.googlecode.com/files/cryptsetup-%version.tar.bz2.asc
|
|
|
|
Source2: baselibs.conf
|
|
|
|
Source3: %{name}.keyring
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2012-07-10 08:28:35 +02:00
|
|
|
BuildRequires: device-mapper-devel
|
|
|
|
BuildRequires: e2fsprogs-devel
|
2013-03-13 17:21:37 +01:00
|
|
|
%if 0%{?suse_version} > 1220
|
2012-12-11 13:52:39 +01:00
|
|
|
BuildRequires: gpg-offline
|
2013-03-13 17:21:37 +01:00
|
|
|
%endif
|
2012-07-10 08:28:35 +02:00
|
|
|
BuildRequires: libgcrypt-devel
|
|
|
|
BuildRequires: libselinux-devel
|
2011-10-02 17:40:14 +02:00
|
|
|
BuildRequires: libtool
|
2013-03-26 12:48:10 +01:00
|
|
|
# 2.6.38 has the required if_alg.h
|
|
|
|
BuildRequires: linux-glibc-devel >= 2.6.38
|
2012-07-10 08:28:35 +02:00
|
|
|
BuildRequires: pkgconfig
|
|
|
|
BuildRequires: popt-devel
|
2007-06-05 04:29:16 +02:00
|
|
|
|
|
|
|
%description
|
2007-08-27 17:34:37 +02:00
|
|
|
cryptsetup is used to conveniently set up dm-crypt based device-mapper
|
|
|
|
targets. It allows to set up targets to read cryptoloop compatible
|
|
|
|
volumes as well as LUKS formatted ones. The package additionally
|
|
|
|
includes support for automatically setting up encrypted volumes at boot
|
|
|
|
time via the config file /etc/crypttab.
|
2007-06-05 04:29:16 +02:00
|
|
|
|
2011-12-18 21:29:05 +01:00
|
|
|
%package -n libcryptsetup4
|
2007-08-27 17:34:37 +02:00
|
|
|
Summary: Set Up dm-crypt Based Encrypted Block Devices
|
2007-06-05 04:29:16 +02:00
|
|
|
Group: System/Base
|
2008-09-15 16:32:21 +02:00
|
|
|
|
2011-12-18 21:29:05 +01:00
|
|
|
%description -n libcryptsetup4
|
2008-09-15 16:32:21 +02:00
|
|
|
cryptsetup is used to conveniently set up dm-crypt based device-mapper
|
|
|
|
targets. It allows to set up targets to read cryptoloop compatible
|
|
|
|
volumes as well as LUKS formatted ones. The package additionally
|
|
|
|
includes support for automatically setting up encrypted volumes at boot
|
|
|
|
time via the config file /etc/crypttab.
|
|
|
|
|
|
|
|
%package -n libcryptsetup-devel
|
|
|
|
Summary: Set Up dm-crypt Based Encrypted Block Devices
|
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
# cryptsetup-devel last used 11.1
|
|
|
|
Provides: cryptsetup-devel = %{version}
|
|
|
|
Obsoletes: cryptsetup-devel < %{version}
|
2012-07-10 08:28:35 +02:00
|
|
|
Requires: glibc-devel
|
2011-12-18 21:29:05 +01:00
|
|
|
Requires: libcryptsetup4 = %{version}
|
2007-06-05 04:29:16 +02:00
|
|
|
|
2008-09-15 16:32:21 +02:00
|
|
|
%description -n libcryptsetup-devel
|
2007-08-27 17:34:37 +02:00
|
|
|
cryptsetup is used to conveniently set up dm-crypt based device-mapper
|
|
|
|
targets. It allows to set up targets to read cryptoloop compatible
|
|
|
|
volumes as well as LUKS formatted ones. The package additionally
|
|
|
|
includes support for automatically setting up encrypted volumes at boot
|
|
|
|
time via the config file /etc/crypttab.
|
2007-06-05 04:29:16 +02:00
|
|
|
|
|
|
|
%prep
|
2013-03-13 17:21:37 +01:00
|
|
|
%if 0%{?gpg_verify:1}
|
2012-12-11 13:52:39 +01:00
|
|
|
%gpg_verify %{S:1}
|
2013-03-13 17:21:37 +01:00
|
|
|
%endif
|
2013-03-26 12:48:10 +01:00
|
|
|
%setup -q
|
2007-06-05 04:29:16 +02:00
|
|
|
|
|
|
|
%build
|
|
|
|
# cryptsetup build
|
|
|
|
%{?suse_update_config:%{suse_update_config}}
|
|
|
|
autoreconf -f -i
|
2010-01-18 14:07:23 +01:00
|
|
|
test -e po/Makevars || cp po/Makevars.template po/Makevars
|
2011-09-26 09:42:42 +02:00
|
|
|
%configure \
|
2012-12-13 14:06:34 +01:00
|
|
|
--disable-static --enable-shared \
|
|
|
|
--enable-cryptsetup-reencrypt \
|
|
|
|
--enable-selinux
|
2010-06-26 21:08:28 +02:00
|
|
|
make %{?_smp_mflags}
|
2007-06-05 04:29:16 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
make install DESTDIR=$RPM_BUILD_ROOT
|
2012-12-13 14:06:34 +01:00
|
|
|
install -d -m 755 $RPM_BUILD_ROOT/sbin
|
|
|
|
ln -s ..%{_sbindir}/cryptsetup $RPM_BUILD_ROOT/sbin
|
2012-02-10 13:56:38 +01:00
|
|
|
# don't want this file in /lib (FHS compat check), and can't move it to /usr/lib
|
2012-12-13 14:06:34 +01:00
|
|
|
rm -f $RPM_BUILD_ROOT/%_libdir/*.la
|
2007-06-05 04:29:16 +02:00
|
|
|
#
|
|
|
|
%find_lang %name --all-name
|
|
|
|
|
|
|
|
%pre
|
|
|
|
|
|
|
|
%post
|
2012-12-13 14:06:34 +01:00
|
|
|
test -n "$FIRST_ARG" || FIRST_ARG="$1"
|
2011-10-27 17:53:38 +02:00
|
|
|
#
|
|
|
|
# convert noauto to nofail and turn on fsck (bnc#724113)
|
|
|
|
#
|
|
|
|
marker="/var/adm/crypsetup.fstab.noauto_converted"
|
|
|
|
if [ "$FIRST_ARG" -gt 1 -a ! -e "$marker" ]; then
|
|
|
|
echo "updating /etc/fstab ... "
|
|
|
|
tmpfstab="/etc/fstab.cryptsetup.$$"
|
|
|
|
sed -e '/^\/dev\/mapper\/cr_.*,noauto\s/{s/,noauto\(\s\)/,nofail\1/;s/ 0 0$/ 0 2/}' < /etc/fstab > "$tmpfstab"
|
|
|
|
if diff -u0 /etc/fstab "$tmpfstab"; then
|
|
|
|
echo "no change"
|
|
|
|
rm -f "$tmpfstab"
|
|
|
|
> "$marker"
|
|
|
|
else
|
|
|
|
cp "$tmpfstab" "$marker"
|
|
|
|
mv "$tmpfstab" /etc/fstab
|
|
|
|
fi
|
|
|
|
fi
|
2007-06-05 04:29:16 +02:00
|
|
|
|
2011-12-18 21:29:05 +01:00
|
|
|
%post -n libcryptsetup4 -p /sbin/ldconfig
|
2008-09-15 16:32:21 +02:00
|
|
|
|
2011-12-18 21:29:05 +01:00
|
|
|
%postun -n libcryptsetup4 -p /sbin/ldconfig
|
2008-09-15 16:32:21 +02:00
|
|
|
|
2007-06-05 04:29:16 +02:00
|
|
|
%files -f %name.lang
|
|
|
|
%defattr(-,root,root)
|
2012-12-13 14:06:34 +01:00
|
|
|
#ghost %verify(not md5 size mtime) %config(noreplace,missingok) /etc/crypttab
|
|
|
|
#ghost %verify(not md5 size mtime) %config(noreplace,missingok) /etc/cryptotab
|
2012-02-10 13:56:38 +01:00
|
|
|
/sbin/cryptsetup
|
2012-12-13 14:06:34 +01:00
|
|
|
%{_sbindir}/cryptsetup
|
|
|
|
%{_sbindir}/veritysetup
|
|
|
|
%{_sbindir}/cryptsetup-reencrypt
|
2007-06-05 04:29:16 +02:00
|
|
|
%_mandir/man8/cryptsetup.8.gz
|
2012-08-02 14:19:12 +02:00
|
|
|
%_mandir/man8/cryptsetup-reencrypt.8.gz
|
|
|
|
%_mandir/man8/veritysetup.8.gz
|
2008-09-15 16:32:21 +02:00
|
|
|
|
2011-12-18 21:29:05 +01:00
|
|
|
%files -n libcryptsetup4
|
2008-09-15 16:32:21 +02:00
|
|
|
%defattr(-,root,root)
|
2012-12-13 14:06:34 +01:00
|
|
|
/%{_libdir}/libcryptsetup.so.4*
|
2007-06-05 04:29:16 +02:00
|
|
|
|
2008-09-15 16:32:21 +02:00
|
|
|
%files -n libcryptsetup-devel
|
2007-06-05 04:29:16 +02:00
|
|
|
%defattr(-,root,root)
|
|
|
|
%_includedir/libcryptsetup.h
|
|
|
|
%{_libdir}/libcryptsetup.so
|
2010-01-18 14:07:23 +01:00
|
|
|
%{_libdir}/pkgconfig/*
|
2007-11-29 18:20:01 +01:00
|
|
|
|
2007-06-05 04:29:16 +02:00
|
|
|
%changelog
|