commit:     4da74a6e48c28eb482c792143e39d50cc933fd9a
Author:     Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
AuthorDate: Thu May  9 17:10:30 2019 +0000
Commit:     Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
CommitDate: Thu May  9 17:11:03 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4da74a6e

app-crypt/efitools: 1.9.2 bump

Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: Matthew Thode <prometheanfire <AT> gentoo.org>

 app-crypt/efitools/Manifest                        |  1 +
 app-crypt/efitools/efitools-1.9.2.ebuild           | 52 ++++++++++++++++++++++
 .../efitools-1.9.2-libressl-compatibility.patch    | 11 +++++
 3 files changed, 64 insertions(+)

diff --git a/app-crypt/efitools/Manifest b/app-crypt/efitools/Manifest
index 5ec4d217cb4..810a8ecac0c 100644
--- a/app-crypt/efitools/Manifest
+++ b/app-crypt/efitools/Manifest
@@ -1,2 +1,3 @@
 DIST efitools-1.7.0.tar.bz2 96042 BLAKE2B 
b0042df906282d878b1400c359c1eece24588f5df7ab753b62f5f0b95e97467cfaa17e04a2ef40a7ec85155c4d13bd438dd94471e0ec98ab23030dd54e7d4214
 SHA512 
1e839c5565b0a113569cf47bf98d656875f9a127b481287a553e8b1276969021e1a39a730b9ede3852e15d1ac045db7ec64767f5ac71a24567236c0938697ccb
 DIST efitools-1.8.1.tar.gz 115319 BLAKE2B 
3aad65defc203055122027cc3a48f50912d2f08b592841780fdc1bf337d75774116e698c4270865275ce7fe64988cd84105138ca979d81818f0065d7ae90f1d0
 SHA512 
114ef8e52160f5a5239ec306dbd587610849bce771ba8145ed092afd79e44f3ecee93cc1d97e2d5fdb880cc825bbbe928b3ef6701fd3b1fa444053894be1098a
+DIST efitools-1.9.2.tar.gz 116037 BLAKE2B 
b3540932eb112e362fd0eed47090360603807dcaec8c6a10058618f8252eeb5dcbbd703d313cb6fadae62c1312815080cf2c77fc86f9dfc9f9afca24ad97f584
 SHA512 
77e0ad7e865814ed388ff6daabe0f4b49ba51672bf2cbb98b7905e209cbd28f9ede2f73213ce45af8a978c1e67dba24ec88a1188661317cc22317b47e575cde8

diff --git a/app-crypt/efitools/efitools-1.9.2.ebuild 
b/app-crypt/efitools/efitools-1.9.2.ebuild
new file mode 100644
index 00000000000..d7fc14afab8
--- /dev/null
+++ b/app-crypt/efitools/efitools-1.9.2.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit flag-o-matic toolchain-funcs
+
+DESCRIPTION="Tools for manipulating UEFI secure boot platforms"
+HOMEPAGE="https://git.kernel.org/cgit/linux/kernel/git/jejb/efitools.git";
+SRC_URI="https://git.kernel.org/pub/scm/linux/kernel/git/jejb/efitools.git/snapshot/${P}.tar.gz";
+
+LICENSE="GPL-2 LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~x86"
+IUSE="libressl static"
+
+LIB_DEPEND="!libressl? ( dev-libs/openssl:0=[static-libs(+)] )
+       libressl? ( dev-libs/libressl:0=[static-libs(+)] )"
+
+RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs(+)]} )
+       sys-apps/util-linux"
+
+DEPEND="${RDEPEND}
+       app-crypt/sbsigntools
+       dev-perl/File-Slurp
+       static? ( ${LIB_DEPEND} )
+       sys-apps/help2man
+       sys-boot/gnu-efi
+       virtual/pkgconfig"
+
+PATCHES=(
+       "${FILESDIR}/1.7.0-Make.rules.patch"
+       "${FILESDIR}/${P}-libressl-compatibility.patch"
+)
+
+src_prepare() {
+       if use static; then
+               append-ldflags -static
+               sed -i "s/-lcrypto\b/$($(tc-getPKG_CONFIG) --static --libs 
libcrypto)/g" \
+                       Makefile || die
+       fi
+
+       # Respect users CFLAGS
+       sed -i -e 's/CFLAGS.*= -O2 -g/CFLAGS += /' Make.rules || die
+
+       # Respect users LDFLAGS
+       sed -i -e 's/LDFLAGS/LIBS/g' Make.rules || die
+       sed -i -e 's/\$(CC)/& $(LDFLAGS)/g' Makefile || die
+
+       # Run 'default', to apply user patches
+       default
+}

diff --git 
a/app-crypt/efitools/files/efitools-1.9.2-libressl-compatibility.patch 
b/app-crypt/efitools/files/efitools-1.9.2-libressl-compatibility.patch
new file mode 100644
index 00000000000..876baae16f8
--- /dev/null
+++ b/app-crypt/efitools/files/efitools-1.9.2-libressl-compatibility.patch
@@ -0,0 +1,11 @@
+--- a/cert-to-efi-hash-list.c  2018-04-21 20:59:24.814748503 +0200
++++ b/cert-to-efi-hash-list.c  2018-04-21 20:59:51.868581307 +0200
+@@ -135,7 +135,7 @@
+         X509 *cert = PEM_read_bio_X509(cert_bio, NULL, NULL, NULL);
+       unsigned char *cert_buf = NULL;
+ 
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
+       int cert_len = i2d_X509_CINF(cert->cert_info, &cert_buf);
+ #else
+       int cert_len = i2d_re_X509_tbs(cert, &cert_buf);

Reply via email to