diff options
author | Lars Wendler <polynomial-c@gentoo.org> | 2020-11-26 09:22:30 +0100 |
---|---|---|
committer | Lars Wendler <polynomial-c@gentoo.org> | 2020-11-26 09:24:20 +0100 |
commit | f47895050be6398fb90fc0b9e16886e1628606d2 (patch) | |
tree | 73a9fd8595865e51c19c6b5663840c9a6059000f /dev-libs/volume_key | |
parent | dev-python/lxml: Stabilize 4.6.1 amd64, #756466 (diff) | |
download | gentoo-f47895050be6398fb90fc0b9e16886e1628606d2.tar.gz gentoo-f47895050be6398fb90fc0b9e16886e1628606d2.tar.bz2 gentoo-f47895050be6398fb90fc0b9e16886e1628606d2.zip |
dev-libs/volume_key: Revbump for python3_9 support
added support for higher LUKS versions
Package-Manager: Portage-3.0.10, Repoman-3.0.2
Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
Diffstat (limited to 'dev-libs/volume_key')
-rw-r--r-- | dev-libs/volume_key/files/volume_key-0.3.12-support_higher_LUKS_versions.patch | 33 | ||||
-rw-r--r-- | dev-libs/volume_key/volume_key-0.3.12-r2.ebuild | 55 |
2 files changed, 88 insertions, 0 deletions
diff --git a/dev-libs/volume_key/files/volume_key-0.3.12-support_higher_LUKS_versions.patch b/dev-libs/volume_key/files/volume_key-0.3.12-support_higher_LUKS_versions.patch new file mode 100644 index 000000000000..6f5aec1dfe5a --- /dev/null +++ b/dev-libs/volume_key/files/volume_key-0.3.12-support_higher_LUKS_versions.patch @@ -0,0 +1,33 @@ +From 26c09768662d8958debe8c9410dae9fda02292c3 Mon Sep 17 00:00:00 2001 +From: Jiri Kucera <jkucera@redhat.com> +Date: Jan 23 2019 13:35:52 +0000 +Subject: Add support for higher versions of LUKS + + +--- + +diff --git a/lib/volume_luks.c b/lib/volume_luks.c +index f4bf2c8..d1c5d47 100644 +--- a/lib/volume_luks.c ++++ b/lib/volume_luks.c +@@ -30,6 +30,10 @@ Author: Miloslav Trmač <mitr@redhat.com> */ + #include "volume.h" + #include "volume_luks.h" + ++#ifndef CRYPT_LUKS ++#define CRYPT_LUKS NULL ++#endif ++ + /* LUKS - specific code */ + + /* Return an error message for ERR_NO, for g_free (). */ +@@ -105,7 +109,7 @@ open_crypt_device (const char *path, char **last_log_entry, GError **error) + if (r < 0) + goto err; + crypt_set_log_callback(cd, record_cryptsetup_log_entry, last_log_entry); +- r = crypt_load (cd, CRYPT_LUKS1, NULL); ++ r = crypt_load (cd, CRYPT_LUKS, NULL); + if (r < 0) + goto err_cd; + return cd; + diff --git a/dev-libs/volume_key/volume_key-0.3.12-r2.ebuild b/dev-libs/volume_key/volume_key-0.3.12-r2.ebuild new file mode 100644 index 000000000000..90c67ed022e2 --- /dev/null +++ b/dev-libs/volume_key/volume_key-0.3.12-r2.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{6..9} ) + +inherit python-single-r1 + +DESCRIPTION="Library for manipulating and storing storage volume encryption keys" +HOMEPAGE="https://pagure.io/volume_key" +SRC_URI="http://releases.pagure.org/${PN}/${P}.tar.xz" + +LICENSE="GPL-2+" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86" +IUSE="test" +RESTRICT="!test? ( test )" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +RDEPEND=" + ${PYTHON_DEPS} + app-crypt/gpgme + dev-libs/glib:2 + dev-libs/nspr + dev-libs/nss + sys-apps/util-linux + sys-fs/cryptsetup:= +" +DEPEND="${RDEPEND}" +BDEPEND=" + sys-devel/gettext + test? ( dev-libs/nss[utils] ) +" + +PATCHES=( + "${FILESDIR}/${P}-support_higher_LUKS_versions.patch" +) + +pkg_setup() { + python-single-r1_pkg_setup +} + +src_configure() { + # --without-python disables python2 + econf --without-python --with-python3 +} + +src_install() { + default + find "${ED}" -type f -name "*.la" -delete || die + + python_optimize +} |