1 |
commit: df1c5015302f17225c762613b97dc7046933fd47 |
2 |
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Feb 10 22:38:04 2019 +0000 |
4 |
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Feb 10 22:47:38 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=df1c5015 |
7 |
|
8 |
sys-fs/cryptsetup: Bump to version 2.1.0 |
9 |
|
10 |
Package-Manager: Portage-2.3.59, Repoman-2.3.12 |
11 |
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org> |
12 |
|
13 |
sys-fs/cryptsetup/Manifest | 1 + |
14 |
sys-fs/cryptsetup/cryptsetup-2.1.0.ebuild | 130 ++++++++++++++++++++++++++++++ |
15 |
sys-fs/cryptsetup/metadata.xml | 1 + |
16 |
3 files changed, 132 insertions(+) |
17 |
|
18 |
diff --git a/sys-fs/cryptsetup/Manifest b/sys-fs/cryptsetup/Manifest |
19 |
index dffce1a9b49..ac52db49dce 100644 |
20 |
--- a/sys-fs/cryptsetup/Manifest |
21 |
+++ b/sys-fs/cryptsetup/Manifest |
22 |
@@ -1,3 +1,4 @@ |
23 |
DIST cryptsetup-1.7.5.tar.xz 1232696 BLAKE2B 1bd62b186564e0b902480d66f623074f8d2f06ea09f11788566e33d58f7d0dc8c79d5827e5966e1a20a5597c2cbdec76da49c8f54c0538a1ac3f869d8ef55456 SHA512 d473f7b06d705a3868a70f3767fafc664436b5897ba59025ea1268f815cb80a9076841ff9ff96cc130fb83ba18b03c1eee38cfaf1b471fdd883a3e126b771439 |
24 |
DIST cryptsetup-2.0.5.tar.xz 10476304 BLAKE2B cf1e335fce48a7bf835b2008dfc0a96ef35d344e2c9f6a0a5a2ff45644f9015311e99b8f9e05b0b23cad69d74f91dd1b7cdd766560fb6504e7453d6e46bea186 SHA512 bac3f5fde1be02d325c097f85e77aef44ce764c1bca7f0554cedd69b9444e5a5529f11b9ae74d36dc1977e88e11422a58dfa17e48559eac7f5e6c4ce332409ae |
25 |
DIST cryptsetup-2.0.6.tar.xz 10621424 BLAKE2B ecda2cb3c0a8a46b69519ab9ea9a1ece44fb21602cbce0751e52a16e5e493c7772fdc62c1151b95a783a847d9afd5a64f64bcac6673acba4bb90a417047c93cb SHA512 1fdb9068fe2b5825cef65323a9b788b5e043c1000e614e47e2b21ab3969e416653580aba639755ba936718ad612b986768029df5e07f3fa191db2bf29d2501ef |
26 |
+DIST cryptsetup-2.1.0.tar.xz 10662576 BLAKE2B c79b24c986d5925aed31eddf8f271c3d0f12c89b3f99f953cfa39fe0d9dca2ab3dd2f6ea22141aca0148d6d533d197378b011561075ca26a14ca2e90500a1689 SHA512 f1b68e4d9d0ca2361fe9bdd51c60630dd4ab7a689b7be7756edf4dee12929d2356dd0658c9b940ffe27c033ef289efaf49daf21d250d37fdfa15394b5d821928 |
27 |
|
28 |
diff --git a/sys-fs/cryptsetup/cryptsetup-2.1.0.ebuild b/sys-fs/cryptsetup/cryptsetup-2.1.0.ebuild |
29 |
new file mode 100644 |
30 |
index 00000000000..1af159a06fe |
31 |
--- /dev/null |
32 |
+++ b/sys-fs/cryptsetup/cryptsetup-2.1.0.ebuild |
33 |
@@ -0,0 +1,130 @@ |
34 |
+# Copyright 1999-2019 Gentoo Authors |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+ |
37 |
+EAPI=6 |
38 |
+ |
39 |
+inherit autotools linux-info libtool eapi7-ver |
40 |
+ |
41 |
+DESCRIPTION="Tool to setup encrypted devices with dm-crypt" |
42 |
+HOMEPAGE="https://gitlab.com/cryptsetup/cryptsetup/blob/master/README.md" |
43 |
+SRC_URI="mirror://kernel/linux/utils/${PN}/v$(ver_cut 1-2)/${P/_/-}.tar.xz" |
44 |
+ |
45 |
+LICENSE="GPL-2+" |
46 |
+SLOT="0/12" # libcryptsetup.so version |
47 |
+[[ ${PV} != *_rc* ]] && \ |
48 |
+KEYWORDS="~amd64 ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" |
49 |
+CRYPTO_BACKENDS="gcrypt kernel nettle +openssl" |
50 |
+# we don't support nss since it doesn't allow cryptsetup to be built statically |
51 |
+# and it's missing ripemd160 support so it can't provide full backward compatibility |
52 |
+IUSE="${CRYPTO_BACKENDS} +argon2 libressl +luks1_default nls pwquality reencrypt static static-libs +udev urandom" |
53 |
+REQUIRED_USE="^^ ( ${CRYPTO_BACKENDS//+/} ) |
54 |
+ static? ( !gcrypt )" #496612 |
55 |
+ |
56 |
+LIB_DEPEND=" |
57 |
+ dev-libs/json-c:=[static-libs(+)] |
58 |
+ dev-libs/libgpg-error[static-libs(+)] |
59 |
+ dev-libs/popt[static-libs(+)] |
60 |
+ >=sys-apps/util-linux-2.31-r1[static-libs(+)] |
61 |
+ argon2? ( app-crypt/argon2:=[static-libs(+)] ) |
62 |
+ gcrypt? ( dev-libs/libgcrypt:0=[static-libs(+)] ) |
63 |
+ nettle? ( >=dev-libs/nettle-2.4[static-libs(+)] ) |
64 |
+ openssl? ( |
65 |
+ !libressl? ( dev-libs/openssl:0=[static-libs(+)] ) |
66 |
+ libressl? ( dev-libs/libressl:=[static-libs(+)] ) |
67 |
+ ) |
68 |
+ pwquality? ( dev-libs/libpwquality[static-libs(+)] ) |
69 |
+ sys-fs/lvm2[static-libs(+)] |
70 |
+ udev? ( virtual/libudev[static-libs(+)] )" |
71 |
+# We have to always depend on ${LIB_DEPEND} rather than put behind |
72 |
+# !static? () because we provide a shared library which links against |
73 |
+# these other packages. #414665 |
74 |
+RDEPEND="static-libs? ( ${LIB_DEPEND} ) |
75 |
+ ${LIB_DEPEND//\[static-libs\(+\)\]}" |
76 |
+DEPEND="${RDEPEND} |
77 |
+ virtual/pkgconfig |
78 |
+ static? ( ${LIB_DEPEND} )" |
79 |
+ |
80 |
+S="${WORKDIR}/${P/_/-}" |
81 |
+ |
82 |
+PATCHES=( "${FILESDIR}"/${PN}-2.0.4-fix-static-pwquality-build.patch ) |
83 |
+ |
84 |
+pkg_pretend() { |
85 |
+ if ! use luks1_default ; then |
86 |
+ ewarn "WARNING! WARNING! WARNING!" |
87 |
+ ewarn "You have chosen LUKS2 as your default format." |
88 |
+ ewarn "This can break LUKS1 backwards compatibility." |
89 |
+ ewarn "Enable \"luks1_default\" USE flag if you need backwards compatibility." |
90 |
+ fi |
91 |
+} |
92 |
+ |
93 |
+pkg_setup() { |
94 |
+ local CONFIG_CHECK="~DM_CRYPT ~CRYPTO ~CRYPTO_CBC ~CRYPTO_SHA256" |
95 |
+ local WARNING_DM_CRYPT="CONFIG_DM_CRYPT:\tis not set (required for cryptsetup)\n" |
96 |
+ local WARNING_CRYPTO_SHA256="CONFIG_CRYPTO_SHA256:\tis not set (required for cryptsetup)\n" |
97 |
+ local WARNING_CRYPTO_CBC="CONFIG_CRYPTO_CBC:\tis not set (required for kernel 2.6.19)\n" |
98 |
+ local WARNING_CRYPTO="CONFIG_CRYPTO:\tis not set (required for cryptsetup)\n" |
99 |
+ check_extra_config |
100 |
+} |
101 |
+ |
102 |
+src_prepare() { |
103 |
+ sed -i '/^LOOPDEV=/s:$: || exit 0:' tests/{compat,mode}-test || die |
104 |
+ default |
105 |
+ eautoreconf |
106 |
+} |
107 |
+ |
108 |
+src_configure() { |
109 |
+ if use kernel ; then |
110 |
+ ewarn "Note that kernel backend is very slow for this type of operation" |
111 |
+ ewarn "and is provided mainly for embedded systems wanting to avoid" |
112 |
+ ewarn "userspace crypto libraries." |
113 |
+ fi |
114 |
+ |
115 |
+ local myeconfargs=( |
116 |
+ --disable-internal-argon2 |
117 |
+ --enable-shared |
118 |
+ --sbindir=/sbin |
119 |
+ # for later use |
120 |
+ --with-default-luks-format=LUKS$(usex luks1_default 1 2) |
121 |
+ --with-tmpfilesdir="${EPREFIX%/}/usr/lib/tmpfiles.d" |
122 |
+ --with-crypto_backend=$(for x in ${CRYPTO_BACKENDS//+/} ; do usev ${x} ; done) |
123 |
+ $(use_enable argon2 libargon2) |
124 |
+ $(use_enable nls) |
125 |
+ $(use_enable pwquality) |
126 |
+ $(use_enable reencrypt cryptsetup-reencrypt) |
127 |
+ $(use_enable static static-cryptsetup) |
128 |
+ $(use_enable static-libs static) |
129 |
+ $(use_enable udev) |
130 |
+ $(use_enable !urandom dev-random) |
131 |
+ ) |
132 |
+ econf "${myeconfargs[@]}" |
133 |
+} |
134 |
+ |
135 |
+src_test() { |
136 |
+ if [[ ! -e /dev/mapper/control ]] ; then |
137 |
+ ewarn "No /dev/mapper/control found -- skipping tests" |
138 |
+ return 0 |
139 |
+ fi |
140 |
+ |
141 |
+ local p |
142 |
+ for p in /dev/mapper /dev/loop* ; do |
143 |
+ addwrite ${p} |
144 |
+ done |
145 |
+ |
146 |
+ default |
147 |
+} |
148 |
+ |
149 |
+src_install() { |
150 |
+ default |
151 |
+ |
152 |
+ if use static ; then |
153 |
+ mv "${ED%}"/sbin/cryptsetup{.static,} || die |
154 |
+ mv "${ED%}"/sbin/veritysetup{.static,} || die |
155 |
+ use reencrypt && { mv "${ED%}"/sbin/cryptsetup-reencrypt{.static,} || die ; } |
156 |
+ fi |
157 |
+ find "${ED}" -name "*.la" -delete || die |
158 |
+ |
159 |
+ dodoc docs/v*ReleaseNotes |
160 |
+ |
161 |
+ newconfd "${FILESDIR}"/1.6.7-dmcrypt.confd dmcrypt |
162 |
+ newinitd "${FILESDIR}"/1.6.7-dmcrypt.rc dmcrypt |
163 |
+} |
164 |
|
165 |
diff --git a/sys-fs/cryptsetup/metadata.xml b/sys-fs/cryptsetup/metadata.xml |
166 |
index 33e359aeaf2..e044cae4089 100644 |
167 |
--- a/sys-fs/cryptsetup/metadata.xml |
168 |
+++ b/sys-fs/cryptsetup/metadata.xml |
169 |
@@ -9,6 +9,7 @@ |
170 |
<flag name="argon2">Enable password hashing algorithm from <pkg>app-crypt/argon2</pkg></flag> |
171 |
<flag name="gcrypt">Use <pkg>dev-libs/libgcrypt</pkg> crypto backend</flag> |
172 |
<flag name="kernel">Use kernel crypto backend (mainly for embedded systems)</flag> |
173 |
+ <flag name="luks1_default">Default to LUKS1 on disk encryption format rather than new LUKS2</flag> |
174 |
<flag name="nettle">Use <pkg>dev-libs/nettle</pkg> crypto backend</flag> |
175 |
<flag name="openssl">Use <pkg>dev-libs/openssl</pkg> crypto backend</flag> |
176 |
<flag name="pwquality">Use <pkg>dev-libs/libpwquality</pkg> for password quality checking</flag> |