/[gentoo-x86]/sys-fs/cryptsetup/cryptsetup-1.4.3.ebuild
Gentoo

Contents of /sys-fs/cryptsetup/cryptsetup-1.4.3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Tue Oct 30 03:11:30 2012 UTC (21 months, 4 weeks ago) by jer
Branch: MAIN
Changes since 1.3: +2 -2 lines
Stable for HPPA (bug #429704).

(Portage version: 2.2.0_alpha142/cvs/Linux x86_64, signed Manifest commit with key A792A613)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sys-fs/cryptsetup/cryptsetup-1.4.3.ebuild,v 1.3 2012/10/25 16:15:09 blueness Exp $
4
5 EAPI="4"
6
7 inherit linux-info libtool
8
9 MY_P=${P/_rc/-rc}
10 DESCRIPTION="Tool to setup encrypted devices with dm-crypt"
11 HOMEPAGE="http://code.google.com/p/cryptsetup/"
12 SRC_URI="http://cryptsetup.googlecode.com/files/${MY_P}.tar.bz2"
13
14 LICENSE="GPL-2"
15 SLOT="0"
16 KEYWORDS="~alpha amd64 arm hppa ~ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc ~x86"
17 IUSE="nls selinux static static-libs"
18
19 S=${WORKDIR}/${MY_P}
20
21 LIB_DEPEND="dev-libs/libgpg-error[static-libs(+)]
22 >=dev-libs/popt-1.7[static-libs(+)]
23 >=sys-apps/util-linux-2.17.2[static-libs(+)]
24 >=dev-libs/libgcrypt-1.1.42[static-libs(+)]
25 >=sys-fs/lvm2-2.02.64[static-libs(+)]
26 >=sys-fs/udev-124[static-libs(+)]
27 >=sys-libs/e2fsprogs-libs-1.41[static-libs(+)]"
28 # We have to always depend on ${LIB_DEPEND} rather than put behind
29 # static? () because we provide a shared library which links against
30 # these other packages. #414665
31 RDEPEND="static-libs? ( ${LIB_DEPEND} )
32 ${LIB_DEPEND//\[static-libs(+)]}
33 !<sys-apps/baselayout-2
34 !sys-fs/cryptsetup-luks
35 selinux? ( sys-libs/libselinux )"
36 DEPEND="${RDEPEND}
37 static? ( ${LIB_DEPEND} )"
38
39 pkg_setup() {
40 local CONFIG_CHECK="~DM_CRYPT ~CRYPTO ~CRYPTO_CBC"
41 local WARNING_DM_CRYPT="CONFIG_DM_CRYPT:\tis not set (required for cryptsetup)\n"
42 local WARNING_CRYPTO_CBC="CONFIG_CRYPTO_CBC:\tis not set (required for kernel 2.6.19)\n"
43 local WARNING_CRYPTO="CONFIG_CRYPTO:\tis not set (required for cryptsetup)\n"
44 check_extra_config
45 }
46
47 src_prepare() {
48 sed -i '/^LOOPDEV=/s:$: || exit 0:' tests/{compat,mode}-test
49 elibtoolize
50 }
51
52 src_configure() {
53 econf \
54 --sbindir=/sbin \
55 --enable-shared \
56 $(use_enable static static-cryptsetup) \
57 $(use_enable static-libs static) \
58 $(use_enable nls) \
59 $(use_enable selinux)
60 }
61
62 src_test() {
63 if [[ ! -e /dev/mapper/control ]] ; then
64 ewarn "No /dev/mapper/control found -- skipping tests"
65 return 0
66 fi
67 local p
68 for p in /dev/mapper /dev/loop* ; do
69 addwrite ${p}
70 done
71 default
72 }
73
74 src_install() {
75 default
76 use static && { mv "${ED}"/sbin/cryptsetup{.static,} || die ; }
77 use static-libs || find "${ED}"/usr -name '*.la' -delete
78
79 newconfd "${FILESDIR}"/1.0.6-dmcrypt.confd dmcrypt
80 newinitd "${FILESDIR}"/dmcrypt.rc dmcrypt
81 }
82
83 pkg_postinst() {
84 ewarn "This ebuild introduces a new set of scripts and configuration"
85 ewarn "than the last version. If you are currently using /etc/conf.d/cryptfs"
86 ewarn "then you *MUST* copy your old file to:"
87 ewarn "/etc/conf.d/dmcrypt"
88 ewarn "Or your encrypted partitions will *NOT* work."
89 elog "Please see the example for configuring a LUKS mountpoint"
90 elog "in /etc/conf.d/dmcrypt"
91 elog
92 elog "If you are using baselayout-2 then please do:"
93 elog "rc-update add dmcrypt boot"
94 elog "This version introduces a command line arguement 'key_timeout'."
95 elog "If you want the search for the removable key device to timeout"
96 elog "after 10 seconds add the following to your bootloader config:"
97 elog "key_timeout=10"
98 elog "A timeout of 0 will mean it will wait indefinitely."
99 elog
100 elog "Users using cryptsetup-1.0.x (dm-crypt plain) volumes must use"
101 elog "a compatibility mode when using cryptsetup-1.1.x. This can be"
102 elog "done by specifying the cipher (-c), key size (-s) and hash (-h)."
103 elog "For more info, see http://code.google.com/p/cryptsetup/wiki/FrequentlyAskedQuestions#6._Issues_with_Specific_Versions_of_cryptsetup"
104 }

  ViewVC Help
Powered by ViewVC 1.1.20