mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-06 00:48:18 -07:00
app-crypt/pesign: EAPI 7, fix GCC 10, drop libressl
Closes: https://bugs.gentoo.org/721934 Closes: https://bugs.gentoo.org/775503 Package-Manager: Portage-3.0.13, Repoman-3.0.2 Signed-off-by: David Michael <fedora.dm0@gmail.com> Signed-off-by: Mike Gilbert <floppym@gentoo.org>
This commit is contained in:
committed by
Mike Gilbert
parent
d1a22fa531
commit
61124b721f
46
app-crypt/pesign/files/pesign-113-enum-conversion.patch
Normal file
46
app-crypt/pesign/files/pesign-113-enum-conversion.patch
Normal file
@@ -0,0 +1,46 @@
|
||||
From c555fd74c009242c3864576bd5f17a1f8f4fdffd Mon Sep 17 00:00:00 2001
|
||||
From: Peter Jones <pjones@redhat.com>
|
||||
Date: Tue, 18 Feb 2020 16:28:56 -0500
|
||||
Subject: [PATCH] pesigcheck: Fix a wrong assignment
|
||||
|
||||
gcc says:
|
||||
|
||||
pesigcheck.c: In function 'check_signature':
|
||||
pesigcheck.c:321:17: error: implicit conversion from 'enum <anonymous>' to 'enum <anonymous>' [-Werror=enum-conversion]
|
||||
321 | reason->type = siBuffer;
|
||||
| ^
|
||||
pesigcheck.c:333:17: error: implicit conversion from 'enum <anonymous>' to 'enum <anonymous>' [-Werror=enum-conversion]
|
||||
333 | reason->type = siBuffer;
|
||||
| ^
|
||||
cc1: all warnings being treated as errors
|
||||
|
||||
And indeed, that line of code makes no sense at all - it was supposed to
|
||||
be reason->sig.type.
|
||||
|
||||
Signed-off-by: Peter Jones <pjones@redhat.com>
|
||||
---
|
||||
src/pesigcheck.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/pesigcheck.c b/src/pesigcheck.c
|
||||
index 524cce3..8fa0f1a 100644
|
||||
--- a/src/pesigcheck.c
|
||||
+++ b/src/pesigcheck.c
|
||||
@@ -318,7 +318,7 @@ check_signature(pesigcheck_context *ctx, int *nreasons,
|
||||
reason->type = SIGNATURE;
|
||||
reason->sig.data = data;
|
||||
reason->sig.len = datalen;
|
||||
- reason->type = siBuffer;
|
||||
+ reason->sig.type = siBuffer;
|
||||
nreason += 1;
|
||||
is_invalid = true;
|
||||
}
|
||||
@@ -330,7 +330,7 @@ check_signature(pesigcheck_context *ctx, int *nreasons,
|
||||
reason->type = SIGNATURE;
|
||||
reason->sig.data = data;
|
||||
reason->sig.len = datalen;
|
||||
- reason->type = siBuffer;
|
||||
+ reason->sig.type = siBuffer;
|
||||
nreason += 1;
|
||||
has_valid_cert = true;
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
# Copyright 1999-2019 Gentoo Authors
|
||||
# Copyright 1999-2021 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
EAPI=7
|
||||
|
||||
inherit eutils toolchain-funcs
|
||||
inherit flag-o-matic toolchain-funcs
|
||||
|
||||
DESCRIPTION="Tools for manipulating signed PE-COFF binaries"
|
||||
HOMEPAGE="https://github.com/rhboot/pesign"
|
||||
@@ -12,24 +12,31 @@ SRC_URI="https://github.com/rhboot/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="libressl"
|
||||
|
||||
RDEPEND="
|
||||
dev-libs/nspr
|
||||
dev-libs/nss
|
||||
dev-libs/openssl:0=
|
||||
dev-libs/popt
|
||||
!libressl? ( dev-libs/openssl:0= )
|
||||
libressl? ( dev-libs/libressl:0= )
|
||||
sys-apps/util-linux
|
||||
sys-libs/efivar
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
DEPEND="${RDEPEND}"
|
||||
BDEPEND="
|
||||
sys-apps/help2man
|
||||
sys-boot/gnu-efi
|
||||
virtual/pkgconfig
|
||||
"
|
||||
|
||||
PATCHES=( "${FILESDIR}"/${PN}-113-nss.patch )
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-113-nss.patch
|
||||
"${FILESDIR}"/${PN}-113-enum-conversion.patch
|
||||
)
|
||||
|
||||
src_configure() {
|
||||
append-cflags -O1 #721934
|
||||
default
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake AR="$(tc-getAR)" \
|
||||
@@ -47,6 +54,5 @@ src_install() {
|
||||
einstalldocs
|
||||
|
||||
# remove some files that don't make sense for Gentoo installs
|
||||
rm -rf "${ED%/}/etc/" "${ED%/}/var/" \
|
||||
"${ED%/}/usr/share/doc/${PF}/COPYING" || die
|
||||
rm -rf "${ED}/etc" "${ED}/var" "${ED}/usr/share/doc/${PF}/COPYING" || die
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user