summaryrefslogtreecommitdiff
path: root/sys-fs/cryptmount/cryptmount-6.3.0.ebuild
blob: b03b2950fe731b44eb7505731e72da2fc447dd92 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit autotools linux-info

DESCRIPTION="A utility for management and user-mode mounting of encrypted filesystems"
HOMEPAGE="http://cryptmount.sourceforge.net/"
SRC_URI="https://github.com/rwpenney/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"

LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="~amd64 ~arm64 ~x86"
IUSE="argv0switch cswap fsck +gcrypt +largefile mount +nls +luks +openssl systemd"
REQUIRED_USE="
	luks? ( gcrypt )
	openssl? ( gcrypt )
"

RDEPEND="
	sys-fs/lvm2
	virtual/libiconv
	virtual/libintl
	gcrypt? ( dev-libs/libgcrypt:0= )
	luks? ( sys-fs/cryptsetup )
	openssl? ( dev-libs/openssl:0= )
	systemd? ( sys-apps/systemd )
"

DEPEND="
	${RDEPEND}
	sys-kernel/linux-headers
"

BDEPEND="nls? ( sys-devel/gettext )"

CONFIG_CHECK="BLK_DEV_DM"
ERROR_BLK_DEV_DM="
	Please enable Device Mapper support in your kernel config
	-> Device Drivers
		-> Multiple devices driver support (RAID and LVM)
			-> Multiple devices driver support (RAID and LVM)
				<*>/<M> Device mapper support
"

src_prepare() {
	default

	# Fix doc directory
	sed -e 's/doc\/cryptmount/doc\/${PF}/g' -i Makefile.am || die

	eautoreconf
}

src_configure() {
	local myeconf=(
		--disable-rpath
		$(use_enable argv0switch)
		$(use_enable cswap)
		$(use_enable fsck)
		$(use_with gcrypt libgcrypt)
		$(use_enable largefile)
		$(use_enable mount delegation)
		$(use_enable nls)
		$(use_enable luks)
		$(use_enable openssl openssl-compat)
		$(use_with systemd)
	)

	econf "${myeconf[@]}"
}