[packages/pesign] - updated to 116

qboosh qboosh at pld-linux.org
Sun May 19 09:21:32 CEST 2024


commit f6b62b03c9b2de88f9c978aee1513d61688b5c34
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sun May 19 08:05:22 2024 +0200

    - updated to 116

 pesign-gcc.patch | 12 ++++++++++++
 pesign-pld.patch | 18 +++++++++---------
 pesign.spec      | 31 +++++++++++++++++++++----------
 3 files changed, 42 insertions(+), 19 deletions(-)
---
diff --git a/pesign.spec b/pesign.spec
index 966e455..ea737f4 100644
--- a/pesign.spec
+++ b/pesign.spec
@@ -1,15 +1,15 @@
 Summary:	Signing tool for PE-COFF binaries
 Summary(pl.UTF-8):	Narzędzie do podpisywania binariów PE-COFF
 Name:		pesign
-Version:	113
+Version:	116
 Release:	1
 License:	GPL v3+
 Group:		Applications/System
 #Source0Download: https://github.com/rhboot/pesign/releases
 Source0:	https://github.com/rhboot/pesign/releases/download/%{version}/%{name}-%{version}.tar.bz2
-# Source0-md5:	4710e207b69c17537d3b3f18ce19948e
+# Source0-md5:	10cd95bf1bee5097321efc141e8ab292
 Patch0:		%{name}-pld.patch
-Patch1:		%{name}-build.patch
+Patch1:		%{name}-gcc.patch
 URL:		https://github.com/rhboot/pesign
 BuildRequires:	efivar-devel
 BuildRequires:	libuuid-devel
@@ -31,6 +31,9 @@ Provides:	group(pesign)
 Provides:	user(pesign)
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
+# TODO: consider move to /run following upstream
+%define		_rundir	/var/run
+
 %description
 Signing tool for PE-COFF binaries, hopefully at least vaguely
 compliant with the PE and Authenticode specifications.
@@ -89,7 +92,8 @@ CFLAGS="%{rpmcflags} -g" \
 %{__make} \
 	LIBDIR=%{_libdir} \
 	libdir=%{_libdir} \
-	libexecdir=%{_libexecdir}
+	libexecdir=%{_libexecdir} \
+	rundir=%{_rundir}/
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -97,15 +101,20 @@ rm -rf $RPM_BUILD_ROOT
 %{__make} install install_systemd install_sysvinit \
 	DESTDIR=$RPM_BUILD_ROOT \
 	libdir=%{_libdir} \
-	libexecdir=%{_libexecdir}
+	libexecdir=%{_libexecdir} \
+	rundir=%{_rundir}/
 
-# omitted from install (as of 113)
+# install disabled in libdpe/Makefile (as of 116)
 install -D libdpe/libdpe.so $RPM_BUILD_ROOT%{_libdir}/libdpe.so.0.%{version}
 ln -sf libdpe.so.0.%{version} $RPM_BUILD_ROOT%{_libdir}/libdpe.so
 cp -p libdpe/libdpe.a $RPM_BUILD_ROOT%{_libdir}
 install -d $RPM_BUILD_ROOT%{_includedir}/libdpe
 cp -p include/libdpe/*.h $RPM_BUILD_ROOT%{_includedir}/libdpe
 
+%if "%{_rundir}" != "/run"
+install -d $RPM_BUILD_ROOT%{_rundir}/pesign
+%endif
+
 # just unwanted COPYING file; make space for %doc
 %{__rm} $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/COPYING
 
@@ -137,15 +146,16 @@ fi
 
 %files
 %defattr(644,root,root,755)
-%doc README TODO
+%doc README.md TODO
 %attr(755,root,root) %{_bindir}/authvar
 %attr(755,root,root) %{_bindir}/efikeygen
-%attr(755,root,root) %{_bindir}/efisiglist
 %attr(755,root,root) %{_bindir}/pesigcheck
 %attr(755,root,root) %{_bindir}/pesign
 %attr(755,root,root) %{_bindir}/pesign-client
+%attr(755,root,root) %{_bindir}/pesum
 %dir %{_libexecdir}/pesign
 %attr(755,root,root) %{_libexecdir}/pesign/pesign-authorize
+%attr(755,root,root) %{_libexecdir}/pesign/pesign-rpmbuild-helper
 %dir %{_sysconfdir}/pesign
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/pesign/groups
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/pesign/users
@@ -156,11 +166,12 @@ fi
 /etc/rpm/macros.pesign
 %attr(754,root,root) /etc/rc.d/init.d/pesign
 %{systemdunitdir}/pesign.service
-%attr(770,pesign,pesign) %dir /var/run/pesign
+%if "%{_rundir}" != "/run"
+%attr(770,pesign,pesign) %dir %{_rundir}/pesign
+%endif
 %{systemdtmpfilesdir}/pesign.conf
 %{_mandir}/man1/authvar.1*
 %{_mandir}/man1/efikeygen.1*
-%{_mandir}/man1/efisiglist.1*
 %{_mandir}/man1/pesigcheck.1*
 %{_mandir}/man1/pesign.1*
 %{_mandir}/man1/pesign-client.1*
diff --git a/pesign-gcc.patch b/pesign-gcc.patch
new file mode 100644
index 0000000..a6db1cc
--- /dev/null
+++ b/pesign-gcc.patch
@@ -0,0 +1,12 @@
+--- pesign-116/src/password.c.orig	2023-01-31 15:55:13.000000000 +0100
++++ pesign-116/src/password.c	2024-05-19 07:27:39.565292240 +0200
+@@ -313,7 +313,9 @@ SECU_FilePasswd(PK11SlotInfo *slot, PRBo
+ 		/* Workaround for -fanalzer/reallocarray() bug
+ 		 * https://bugzilla.redhat.com/show_bug.cgi?id=2047926 */
+ #pragma GCC diagnostic push
++#if defined(__GNUC__) && (__GNUC__ >= 11)
+ #pragma GCC diagnostic ignored "-Wanalyzer-mismatching-deallocation"
++#endif
+ 		new_phrases = reallocarray(phrases, nphrases + 1, sizeof(struct token_pass));
+ 		if (!new_phrases)
+ 			goto err_phrases;
diff --git a/pesign-pld.patch b/pesign-pld.patch
index 112c4ad..dace633 100644
--- a/pesign-pld.patch
+++ b/pesign-pld.patch
@@ -1,6 +1,6 @@
---- pesign-113/src/pesign.sysvinit.in.orig	2019-05-10 20:53:51.000000000 +0200
-+++ pesign-113/src/pesign.sysvinit.in	2019-09-12 19:03:31.078192655 +0200
-@@ -13,45 +13,47 @@
+--- pesign-116/src/pesign.sysvinit.in.orig	2023-01-31 15:55:13.000000000 +0100
++++ pesign-116/src/pesign.sysvinit.in	2024-05-19 07:13:51.483111680 +0200
+@@ -13,45 +13,48 @@
  # Description: The pesign PE signing daemon
  ### END INIT INFO
  
@@ -19,12 +19,12 @@
 +    fi
 +
 +    msg_starting pesign
-     mkdir /var/run/pesign 2>/dev/null &&
-         chown pesign:pesign /var/run/pesign &&
-         chmod 0770 /var/run/pesign
+     mkdir @@RUNDIR@@pesign 2>/dev/null &&
+         chown pesign:pesign @@RUNDIR@@pesign &&
+         chmod 0770 @@RUNDIR@@pesign
      daemon /usr/bin/pesign --daemonize
      RETVAL=$?
--    echo
+     echo
 -    touch /var/lock/subsys/pesign
 +    [ $RETVAL -eq 0 ] && touch /var/lock/subsys/pesign
      @@LIBEXECDIR@@/pesign/pesign-authorize
@@ -39,7 +39,7 @@
 +    fi
 +
 +    msg_stopping pesign
-     killproc -p /var/run/pesign.pid pesignd
+     killproc -p @@RUNDIR@@pesign.pid pesignd
 -    RETVAL=$?
 -    echo
      rm -f /var/lock/subsys/pesign
@@ -68,7 +68,7 @@
  # See how we were called.
  case "$1" in
      start)
-@@ -61,26 +63,22 @@
+@@ -61,26 +64,22 @@ case "$1" in
  	stop
  	;;
      status)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/pesign.git/commitdiff/f6b62b03c9b2de88f9c978aee1513d61688b5c34



More information about the pld-cvs-commit mailing list