package/rng-tools: bump to version 6.15

Drop patches (already in version)

https://github.com/nhorman/rng-tools/releases/tag/v6.15

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
This commit is contained in:
Fabrice Fontaine 2022-02-09 20:24:36 +01:00 committed by Arnout Vandecappelle (Essensium/Mind)
parent 0fc614345f
commit 91cc129d72
4 changed files with 2 additions and 94 deletions

View File

@ -1,43 +0,0 @@
From d1840e54a15fc454936cada10cce7fd91d06232b Mon Sep 17 00:00:00 2001
From: Neil Horman <nhorman@gmail.com>
Date: Thu, 15 Jul 2021 08:43:01 -0400
Subject: [PATCH] Adding ability to detect non-posix extensions for pthreads
Theres a desire to build rngd with musl, which doesn't have all the gnu
extensions (but it has some). So test for those. Note, this requires
the addition of the USE_EXTENSIONS macro to enable -d_GNU_SOURCE
Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
[Retrieved from:
https://github.com/nhorman/rng-tools/commit/d1840e54a15fc454936cada10cce7fd91d06232b]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
configure.ac | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/configure.ac b/configure.ac
index 0fe06fc..de7dca3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -25,6 +25,7 @@ AC_CANONICAL_TARGET dnl required for broken AX_PTHREAD
AM_INIT_AUTOMAKE([foreign])
AC_CONFIG_HEADERS([rng-tools-config.h])
AC_CONFIG_MACRO_DIRS([m4])
+AC_USE_SYSTEM_EXTENSIONS
dnl Parse options
@@ -100,6 +101,12 @@ AS_IF(
], [AC_MSG_NOTICE([Disabling JITTER entropy source])]
)
+AC_CHECK_DECL(pthread_attr_setaffinity_np,
+ [AC_DEFINE([HAVE_PTHREAD_ATTR_SETAFFINITY], 1,[Set ATTR_SETAFFINITY])],
+ [ AC_CHECK_DECL(pthread_setaffinity_np,
+ [AC_DEFINE([HAVE_PTHREAD_SETAFFINITY],1, [Set PTHREAD_SETAFFINITY])], [ AC_MSG_ERROR([Neither pthread_setaffinity_np nor pthread_attr_setaffinity_np found])],[[#include <pthread.h>]])
+ ], [[#include <pthread.h>]])
+
AS_IF(
[ test "x$with_nistbeacon" != "xno"],
[

View File

@ -1,49 +0,0 @@
From 5caa086dc14cecf68d1a5c31e87ba1efb2c00893 Mon Sep 17 00:00:00 2001
From: Neil Horman <nhorman@gmail.com>
Date: Thu, 15 Jul 2021 08:48:10 -0400
Subject: [PATCH] Allow for use of either pthread affinity set methods
musl has support for pthread_setaffinity_np, but not
pthread_attr_setaffinity_np. so check for hte existence of either
function in configure, and use the appropriate one.
Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
[Retrieved from:
https://github.com/nhorman/rng-tools/commit/5caa086dc14cecf68d1a5c31e87ba1efb2c00893]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
rngd_jitter.c | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/rngd_jitter.c b/rngd_jitter.c
index ea29436..5c7e09e 100644
--- a/rngd_jitter.c
+++ b/rngd_jitter.c
@@ -67,12 +67,25 @@ static int rngd_notime_start(void *ctx,
for(i=i-1;i>=0;i--) {
CPU_SET(i,cpus);
}
- pthread_attr_setaffinity_np(&thread_ctx->notime_pthread_attr, cpusize, cpus);
+ /*
+ * Note that only one of:
+ * HAVE_PTHREAD_ATTR_SETAFFINITY
+ * and
+ * HAVE_PTHREAD_SETAFFINITY
+ * Will ever be set, as per the configure.ac logic
+ */
+#ifdef HAVE_PTHREAD_ATTR_SETAFFINITY
+ pthread_attr_setaffinity_np(&thread_ctx->notime_pthread_attr, cpusize, cpus);
+#endif
ret = -pthread_create(&thread_ctx->notime_thread_id,
&thread_ctx->notime_pthread_attr,
start_routine, arg);
+#ifdef HAVE_PTHREAD_SETAFFINITY
+ pthread_setaffinity_np(&thread_ctx->notime_thread_id, cpusize, cpus);
+#endif
+
CPU_FREE(cpus);
return ret;
}

View File

@ -1,3 +1,3 @@
# Locally computed
sha256 4dd86f6ae37d917a8489f44070d39d7feddcc622429b95efd7aa85a1f3cfdf81 rng-tools-6.14.tar.gz
sha256 bff0c58dff90ec10bd61f672e48618e045155eabd60b32d63a9c4ffbdad05f3a rng-tools-6.15.tar.gz
sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 COPYING

View File

@ -4,7 +4,7 @@
#
################################################################################
RNG_TOOLS_VERSION = 6.14
RNG_TOOLS_VERSION = 6.15
RNG_TOOLS_SITE = $(call github,nhorman,$(RNG_TOOLS_NAME),v$(RNG_TOOLS_VERSION))
RNG_TOOLS_LICENSE = GPL-2.0
RNG_TOOLS_LICENSE_FILES = COPYING