diff options
author | V3n3RiX <venerix@koprulu.sector> | 2021-12-05 02:47:11 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2021-12-05 02:47:11 +0000 |
commit | 2771f79232c273bc2a57d23bf335dd81ccf6af28 (patch) | |
tree | c8af0fd04194aed03cf067d44e53c7edd3e9ab84 /sys-fs/cryptsetup | |
parent | e9d044d4b9b71200a96adfa280848858c0f468c9 (diff) |
gentoo resync : 05.12.2021
Diffstat (limited to 'sys-fs/cryptsetup')
-rw-r--r-- | sys-fs/cryptsetup/Manifest | 2 | ||||
-rw-r--r-- | sys-fs/cryptsetup/cryptsetup-2.4.2-r1.ebuild | 133 |
2 files changed, 135 insertions, 0 deletions
diff --git a/sys-fs/cryptsetup/Manifest b/sys-fs/cryptsetup/Manifest index b85c1ce6d01d..848d59137156 100644 --- a/sys-fs/cryptsetup/Manifest +++ b/sys-fs/cryptsetup/Manifest @@ -7,6 +7,8 @@ AUX cryptsetup-2.4.1-external-tokens.patch 1015 BLAKE2B ca7b5940caf000cc97742dfc AUX cryptsetup-2.4.1-fix-static-pwquality-build.patch 5226 BLAKE2B 1dfd8b001e8284d5efd5afe0d67a401d334e9588baf6d0f18f533694dd4a22a782066ee43f22fe5bfaea51fc09beac127e91c77b07fc9a63778b55b25e0d2ebf SHA512 71a3f63b86de72ccfa49c9294db433da7f1fd6366e328f7311051edfd980f630ca3435ef8c5e92c55083eb3b25a3b2bbafa75282de1bf65be6820655b7556f2f DIST cryptsetup-2.3.6.tar.xz 11154148 BLAKE2B 23a7d6fdeed2b8fb0492e800266a263b12dcf2b8c4304bda82e46d2de90b6c05a97a40f0f6f9c337b3dc428d51689d76953de5cc4daed210967cf0ea0ff503d2 SHA512 5b25cc806140d24181a0e4f0e7b0bd3caa8263aa502e8633b41c980f06ecba2e6acbf9c2d9cc4a785d38ce90d86dd8d22c52b28b9ca4a15824c2e8bdb3656665 DIST cryptsetup-2.4.1.tar.xz 11171180 BLAKE2B 6b999a19df54276d295eb2f1729be2eefb5fb09cd29aae5f7c0b93c539b4b552f92327f2474e0f4793a3c7f8a264a4ef927178dabfc9ba56012bdf9949ef9ada SHA512 17fc73c180e41acbd4ebeddebaf54f8baeef09fce7f154aa9c55936a58bda7adcc7b1bb257336c22295d7b5af426fc8dfd0e4e644e4a52098bcb8a2adb562ca7 +DIST cryptsetup-2.4.2.tar.xz 11173984 BLAKE2B 33a26ac2f38750171c74cdd827317cd4bba193a6b60cc7250dc52a5117c0feb1d2fca6b52b5ae7926725d77dc6c1ab9d13e85a1c59606e80003294b90578781d SHA512 9464f180f24dffa4566450041fc88c372baa3334c62724487ccee230c16e87572439dc604766d94144cc1fc13802a4322b378185eca0cc848892821653566848 EBUILD cryptsetup-2.3.6-r2.ebuild 3908 BLAKE2B f2b709398da106f2d2b89365d67eee7298703035b1c94960fc0819b00dc48231692a6df2bf13322778e3704003bc0637a14d8198343053010b74fd21b1f52050 SHA512 6a9ee5bdd788a51944af30311ec84698d0fcaf19fe5845be4e0758dc89367ba9786c47b861595dfa691e3b9a82e11a239e54b1166fddd4848ec3bf37d5ceb195 EBUILD cryptsetup-2.4.1-r1.ebuild 4283 BLAKE2B 599590bf68883aad5e64b6a5affc0a464df4339abd11fe9088ea980fc400ba5bc6e7a5fbbd4792a73f735351ea348d1ade9ed42fb9480c991be5e48753799f3c SHA512 bf6ed2dd41144874931c56c4fb697ae4c3df696fefa11373352921729e9e4b9db4f8cd0f4094ba170ebe7a5e8a61c76673b0bc554857090b61f9e0b6ad61f51e +EBUILD cryptsetup-2.4.2-r1.ebuild 4067 BLAKE2B 47d2c7ceb821587d2b5d3940504021a3310838c4fe5233f19c12def4e9a0799f6cb284539f665fc8f2c98457ffa9f72ea8ef4317cd4453d409ce68d208d5e412 SHA512 327ba8aac24198eaf4bbe7a4e8575132679d71f0809c1ede7156f2b89409a1901ce7057dbb9b61cd6237df153ba186c09bf6d98fd559a9f02bdd03fb633c3a31 MISC metadata.xml 1076 BLAKE2B 132b07201bfa3a7d8889d0b2558c15f35829bfa021b31cd5a9cf2cb21de822ceb89fae177b014590f46411cd609b4e44b20165b07c7676483a547987fffcbb9d SHA512 b06b884e0e369022cea4b3634d9df3c7d62d854754969d0c7848a3baf3a3ea69cce2131527539600424c72c539e502378b0627ba7c4fdcbc74e6f7a58b5800a8 diff --git a/sys-fs/cryptsetup/cryptsetup-2.4.2-r1.ebuild b/sys-fs/cryptsetup/cryptsetup-2.4.2-r1.ebuild new file mode 100644 index 000000000000..9bfa24d56c8d --- /dev/null +++ b/sys-fs/cryptsetup/cryptsetup-2.4.2-r1.ebuild @@ -0,0 +1,133 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit linux-info tmpfiles + +DESCRIPTION="Tool to setup encrypted devices with dm-crypt" +HOMEPAGE="https://gitlab.com/cryptsetup/cryptsetup/blob/master/README.md" +SRC_URI="https://www.kernel.org/pub/linux/utils/${PN}/v$(ver_cut 1-2)/${P/_/-}.tar.xz" + +LICENSE="GPL-2+" +SLOT="0/12" # libcryptsetup.so version +[[ ${PV} != *_rc* ]] && \ +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +CRYPTO_BACKENDS="gcrypt kernel nettle +openssl" +# we don't support nss since it doesn't allow cryptsetup to be built statically +# and it's missing ripemd160 support so it can't provide full backward compatibility +IUSE="${CRYPTO_BACKENDS} +argon2 nls pwquality reencrypt ssh static static-libs +udev urandom" +REQUIRED_USE="^^ ( ${CRYPTO_BACKENDS//+/} ) + static? ( !gcrypt !udev )" #496612 + +LIB_DEPEND=" + dev-libs/json-c:=[static-libs(+)] + dev-libs/popt[static-libs(+)] + >=sys-apps/util-linux-2.31-r1[static-libs(+)] + argon2? ( app-crypt/argon2:=[static-libs(+)] ) + gcrypt? ( + dev-libs/libgcrypt:0=[static-libs(+)] + dev-libs/libgpg-error[static-libs(+)] + ) + nettle? ( >=dev-libs/nettle-2.4[static-libs(+)] ) + openssl? ( dev-libs/openssl:0=[static-libs(+)] ) + pwquality? ( dev-libs/libpwquality[static-libs(+)] ) + ssh? ( net-libs/libssh[static-libs(+)] ) + sys-fs/lvm2[static-libs(+)]" +# We have to always depend on ${LIB_DEPEND} rather than put behind +# !static? () because we provide a shared library which links against +# these other packages. #414665 +RDEPEND="static-libs? ( ${LIB_DEPEND} ) + ${LIB_DEPEND//\[static-libs\([+-]\)\]} + udev? ( virtual/libudev:= )" +DEPEND="${RDEPEND} + static? ( ${LIB_DEPEND} )" +BDEPEND=" + virtual/pkgconfig +" + +S="${WORKDIR}/${P/_/-}" + +pkg_setup() { + local CONFIG_CHECK="~DM_CRYPT ~CRYPTO ~CRYPTO_CBC ~CRYPTO_SHA256" + local WARNING_DM_CRYPT="CONFIG_DM_CRYPT:\tis not set (required for cryptsetup)\n" + local WARNING_CRYPTO_SHA256="CONFIG_CRYPTO_SHA256:\tis not set (required for cryptsetup)\n" + local WARNING_CRYPTO_CBC="CONFIG_CRYPTO_CBC:\tis not set (required for kernel 2.6.19)\n" + local WARNING_CRYPTO="CONFIG_CRYPTO:\tis not set (required for cryptsetup)\n" + check_extra_config +} + +src_prepare() { + sed -i '/^LOOPDEV=/s:$: || exit 0:' tests/{compat,mode}-test || die + default +} + +src_configure() { + if use kernel ; then + ewarn "Note that kernel backend is very slow for this type of operation" + ewarn "and is provided mainly for embedded systems wanting to avoid" + ewarn "userspace crypto libraries." + fi + + local myeconfargs=( + --disable-internal-argon2 + --enable-shared + --sbindir=/sbin + # for later use + --with-default-luks-format=LUKS2 + --with-tmpfilesdir="${EPREFIX}/usr/lib/tmpfiles.d" + --with-crypto_backend=$(for x in ${CRYPTO_BACKENDS//+/} ; do usev ${x} ; done) + $(use_enable argon2 libargon2) + $(use_enable nls) + $(use_enable pwquality) + $(use_enable reencrypt cryptsetup-reencrypt) + $(use_enable !static external-tokens) + $(use_enable static static-cryptsetup) + $(use_enable static-libs static) + $(use_enable udev) + $(use_enable !urandom dev-random) + $(use_enable ssh ssh-token) + $(usex argon2 '' '--with-luks2-pbkdf=pbkdf2') + ) + econf "${myeconfargs[@]}" +} + +src_test() { + if [[ ! -e /dev/mapper/control ]] ; then + ewarn "No /dev/mapper/control found -- skipping tests" + return 0 + fi + + local p + for p in /dev/mapper /dev/loop* ; do + addwrite ${p} + done + + default +} + +src_install() { + default + + if use static ; then + mv "${ED}"/sbin/cryptsetup{.static,} || die + mv "${ED}"/sbin/veritysetup{.static,} || die + mv "${ED}"/sbin/integritysetup{.static,} || die + if use ssh ; then + mv "${ED}"/sbin/cryptsetup-ssh{.static,} || die + fi + if use reencrypt ; then + mv "${ED}"/sbin/cryptsetup-reencrypt{.static,} || die + fi + fi + find "${ED}" -type f -name "*.la" -delete || die + + dodoc docs/v*ReleaseNotes + + newconfd "${FILESDIR}"/2.4.0-dmcrypt.confd dmcrypt + newinitd "${FILESDIR}"/2.4.0-dmcrypt.rc dmcrypt +} + +pkg_postinst() { + tmpfiles_process cryptsetup.conf +} |