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

Contents of /sys-fs/cryptsetup/cryptsetup-1.0.6-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (show annotations) (download)
Sun Apr 19 18:41:07 2009 UTC (5 years, 8 months ago) by cardoe
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +1 -1 lines
FILE REMOVED
clean up old versions. clean up depends
(Portage version: 2.1.6.11/cvs/Linux x86_64)

1 # Copyright 1999-2009 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.0.6-r1.ebuild,v 1.5 2009/04/10 16:51:56 caleb Exp $
4
5 inherit linux-info eutils flag-o-matic multilib
6
7 DESCRIPTION="Tool to setup encrypted devices with dm-crypt"
8 HOMEPAGE="http://luks.endorphin.org/"
9 SRC_URI="http://luks.endorphin.org/source/${P}.tar.bz2"
10
11 LICENSE="GPL-2"
12 SLOT="0"
13 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
14 IUSE="dynamic nls selinux"
15
16 DEPEND="|| (
17 >=sys-fs/lvm2-2.02.45
18 >=sys-fs/device-mapper-1.00.07-r1
19 )
20 >=dev-libs/libgcrypt-1.1.42
21 >=dev-libs/libgpg-error-1.0-r1
22 >=dev-libs/popt-1.7
23 >=sys-fs/udev-124
24 selinux? ( sys-libs/libselinux )
25 !sys-fs/cryptsetup-luks"
26
27 dm-crypt_check() {
28 local CONFIG_CHECK="~DM_CRYPT"
29 local WARNING_DM_CRYPT="CONFIG_DM_CRYPT:\tis not set (required for cryptsetup)\n"
30 check_extra_config
31 }
32
33 crypto_check() {
34 local CONFIG_CHECK="~CRYPTO"
35 local WARNING_CRYPTO="CONFIG_CRYPTO:\tis not set (required for cryptsetup)\n"
36 check_extra_config
37 }
38
39 cbc_check() {
40 local CONFIG_CHECK="~CRYPTO_CBC"
41 local WARNING_CRYPTO_CBC="CONFIG_CRYPTO_CBC:\tis not set (required for kernel 2.6.19)\n"
42 check_extra_config
43 }
44
45 pkg_setup() {
46 dm-crypt_check
47 crypto_check
48 cbc_check
49
50 if use dynamic ; then
51 ewarn "If you need cryptsetup for an initrd or initramfs then you"
52 ewarn "should NOT use the dynamic USE flag"
53 epause 5
54 fi
55 }
56
57 src_unpack() {
58 unpack ${A}
59 cd "${S}"
60
61 # fix for bug #236481, use udevadm instead of udevsettle
62 epatch "${FILESDIR}"/${PN}-1.0.6-udevsettle.patch
63 }
64
65 src_compile() {
66 econf \
67 --sbindir=/sbin \
68 $(use_enable !dynamic static) \
69 --libdir=/usr/$(get_libdir) \
70 $(use_enable nls) \
71 $(use_enable selinux) \
72 || die
73 emake || die
74 }
75
76 src_install() {
77 emake DESTDIR="${D}" install || die "install failed"
78 rmdir "${D}"/usr/$(get_libdir)/cryptsetup
79 insinto /lib/rcscripts/addons
80 newins "${FILESDIR}"/1.0.6-dm-crypt-start.sh dm-crypt-start.sh || die
81 newins "${FILESDIR}"/1.0.5-dm-crypt-stop.sh dm-crypt-stop.sh || die
82 newconfd "${FILESDIR}"/1.0.5-dmcrypt.confd dmcrypt || die
83 newinitd "${FILESDIR}"/1.0.5-dmcrypt.rc dmcrypt || die
84 }
85
86 pkg_postinst() {
87 ewarn "This ebuild introduces a new set of scripts and configuration"
88 ewarn "than the last version. If you are currently using /etc/conf.d/cryptfs"
89 ewarn "then you *MUST* copy your old file to:"
90 ewarn "/etc/conf.d/dmcrypt"
91 ewarn "Or your encrypted partitions will *NOT* work."
92 elog "Please see the example for configuring a LUKS mountpoint"
93 elog "in /etc/conf.d/dmcrypt"
94 elog
95 elog "If you are using baselayout-2 then please do:"
96 elog "rc-update add dmcrypt boot"
97 elog "This version introduces a command line arguement 'key_timeout'."
98 elog "If you want the search for the removable key device to timeout"
99 elog "after 10 seconds add the following to your bootloader config:"
100 elog "key_timeout=10"
101 elog "A timeout of 0 will mean it will wait indefinitely."
102 }

  ViewVC Help
Powered by ViewVC 1.1.20