Skip to contentSkip to conversation

libkcapi: bump to version 1.1.0

PATCH New Fabrice Fontaine 2 participants 2 messages May 2, 2018 – May 3, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 libkcapi: bump to version 1.1.0

- Remove patches (already in version)
- Add patch for getrandom (sent upstream:
https://github.com/smuellerDD/libkcapi/pull/56)
- Add hash for license files

---
 .../0001-Fix-getrandom-call-in-kcapi-rng.c.patch   |  31 +++++
 ...1-Have-sufficient-memory-size-for-message.patch |  31 -----
 .../0002-Do-not-compile-unused-functions.patch     |  35 ------
 ...0003-Unify-code-to-read-from-seed-sources.patch | 132 ---------------------
 ...4-internal.h-make-inline-functions-static.patch | 103 ----------------
 package/libkcapi/libkcapi.hash                     |   5 +-
 package/libkcapi/libkcapi.mk                       |   2 +-
 7 files changed, 36 insertions(+), 303 deletions(-)
 create mode 100644 package/libkcapi/0001-Fix-getrandom-call-in-kcapi-rng.c.patch
 delete mode 100644 package/libkcapi/0001-Have-sufficient-memory-size-for-message.patch
 delete mode 100644 package/libkcapi/0002-Do-not-compile-unused-functions.patch
 delete mode 100644 package/libkcapi/0003-Unify-code-to-read-from-seed-sources.patch
 delete mode 100644 package/libkcapi/0004-internal.h-make-inline-functions-static.patch
package/libkcapi/0001-Fix-getrandom-call-in-kcapi-rng.c.patch new file +31 -0
new file mode 100644
index 0000000000..d83edd9261
@@ -0,0 +1,31 @@
+From 581717cfb0e35c041246da0c0c591a6e9f7a40e5 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <[email protected]>
+Date: Wed, 2 May 2018 21:03:45 +0200
+Subject: [PATCH] Fix getrandom call in kcapi-rng.c
+
+_GNU_SOURCE must be defined and unistd.h must be included to be able to
+use getrandom
+
+Signed-off-by: Fabrice Fontaine <[email protected]>
+
+[Upstream status: https://github.com/smuellerDD/libkcapi/pull/56]
+---
+ lib/kcapi-rng.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/lib/kcapi-rng.c b/lib/kcapi-rng.c
+index 45f4d18..9ceabd4 100644
+--- a/lib/kcapi-rng.c
++++ b/lib/kcapi-rng.c
+@@ -18,6 +18,8 @@
+  * DAMAGE.
+  */
+ 
++#define _GNU_SOURCE
++#include <unistd.h>
+ #include <linux/random.h>
+ #ifdef HAVE_GETRANDOM
+ #include <sys/random.h>
+-- 
+2.14.1
+
package/libkcapi/0001-Have-sufficient-memory-size-for-message.patch deleted +0 -31
deleted file mode 100644
index 39e683f58a..0000000000
@@ -1,31 +0,0 @@
-From b56deda7c13c257050fdbdd71c1a5a47b78aa63e Mon Sep 17 00:00:00 2001
-From: Stephan Mueller <[email protected]>
-Date: Thu, 3 Aug 2017 17:50:51 +0200
-Subject: [PATCH] Have sufficient memory size for message
-
-With GCC 7, the size of the buffer in snprintf is checked. The
-occurrence here is found to be too small.
-
-Signed-off-by: Stephan Mueller <[email protected]>
-[Upstream commit: https://github.com/smuellerDD/libkcapi/commit/b56deda7c13c257050fdbdd71c1a5a47b78aa63e]
-Signed-off-by: Marcin Nowakowski <[email protected]>
----
- speed-test/cryptoperf-base.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/speed-test/cryptoperf-base.c b/speed-test/cryptoperf-base.c
-index 8766ca7..07384ae 100644
---- a/speed-test/cryptoperf-base.c
-+++ b/speed-test/cryptoperf-base.c
-@@ -172,7 +172,7 @@ char *cp_print_status(struct cp_test *test, int raw)
- 			(unsigned long)(processed_bytes/totaltime),
- 			(unsigned long)ops);
- 	} else {
--		#define VALLEN 10
-+		#define VALLEN 23
- 		char byteseconds[VALLEN + 1];
- 
- 		memset(byteseconds, 0, sizeof(byteseconds));
--- 
-2.7.4
-
package/libkcapi/0002-Do-not-compile-unused-functions.patch deleted +0 -35
deleted file mode 100644
index 97ab7fc50b..0000000000
@@ -1,35 +0,0 @@
-From 217b154a5f65d46064ceb69ce69664105e703a74 Mon Sep 17 00:00:00 2001
-From: Stephan Mueller <[email protected]>
-Date: Thu, 3 Aug 2017 17:52:48 +0200
-Subject: [PATCH] Do not compile unused functions
-
-GCC 7 now rightfully complains about unused functions.
-
-Signed-off-by: Stephan Mueller <[email protected]>
-
-[Upstream commit: https://github.com/smuellerDD/libkcapi/commit/217b154a5f65d46064ceb69ce69664105e703a74]
-Signed-off-by: Marcin Nowakowski <[email protected]>
----
- apps/kcapi-rng.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/apps/kcapi-rng.c b/apps/kcapi-rng.c
-index df7decf..e15edf9 100644
---- a/apps/kcapi-rng.c
-+++ b/apps/kcapi-rng.c
-@@ -45,6 +45,7 @@ struct kcapi_handle *rng = NULL;
- unsigned int Verbosity = 0;
- char *rng_name = NULL;
- 
-+#ifndef HAVE_GETRANDOM
- static int read_complete(int fd, uint8_t *buf, uint32_t buflen)
- {
- 	ssize_t ret;
-@@ -76,6 +77,7 @@ static int read_random(uint8_t *buf, uint32_t buflen)
- 	close(fd);
- 	return ret;
- }
-+#endif
- 
- static int get_random(uint8_t *buf, uint32_t buflen)
- {
package/libkcapi/0003-Unify-code-to-read-from-seed-sources.patch deleted +0 -132

132 lines not on this page · raw message

package/libkcapi/0004-internal.h-make-inline-functions-static.patch deleted +0 -103

103 lines not on this page · raw message

package/libkcapi/libkcapi.hash +4 -1
index 9873e6623e..9cb1e80ccb 100644
@@ -1,2 +1,5 @@
 # Locally calculated
-sha256 411fc32b3e36ac0268837a8d4538eb8aef487b3a3e9b21a2b88b8ed2f926edf3	libkcapi-0.14.0.tar.xz
+sha256 ac80211317750f6a545b1e5547cfb6ae450b37c11acb6d24982a581705eb5250	libkcapi-1.1.0.tar.xz
+sha256 b0336f8f07a6abf8b0a59d961f53601d7c4a7c09a8137805b730a34a976039f8	COPYING
+sha256 e6d6a009505e345fe949e1310334fcb0747f28dae2856759de102ab66b722cb4	COPYING.gplv2
+sha256 13aa749a5b0a454917a944ed8fffc530b784f5ead522b1aacaf4ec8aa55a6239	COPYING.bsd
package/libkcapi/libkcapi.mk +1 -1
index d21c81b168..44469017df 100644
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-LIBKCAPI_VERSION = 0.14.0
+LIBKCAPI_VERSION = 1.1.0
 LIBKCAPI_SOURCE = libkcapi-$(LIBKCAPI_VERSION).tar.xz
 LIBKCAPI_SITE = http://www.chronox.de/libkcapi
 LIBKCAPI_AUTORECONF = YES
Signature · 1 line
2.14.1
#1 lore raw

PATCH 1/1 libkcapi: bump to version 1.1.0

Hello,

Quoted 6 lines · Fabrice Fontaine

- Remove patches (already in version)
- Add patch for getrandom (sent upstream:
https://github.com/smuellerDD/libkcapi/pull/56)
- Add hash for license files

Quoted 14 lines
---
 .../0001-Fix-getrandom-call-in-kcapi-rng.c.patch   |  31 +++++
 ...1-Have-sufficient-memory-size-for-message.patch |  31 -----
 .../0002-Do-not-compile-unused-functions.patch     |  35 ------
 ...0003-Unify-code-to-read-from-seed-sources.patch | 132 ---------------------
 ...4-internal.h-make-inline-functions-static.patch | 103 ----------------
 package/libkcapi/libkcapi.hash                     |   5 +-
 package/libkcapi/libkcapi.mk                       |   2 +-
 7 files changed, 36 insertions(+), 303 deletions(-)
 create mode 100644 package/libkcapi/0001-Fix-getrandom-call-in-kcapi-rng.c.patch
 delete mode 100644 package/libkcapi/0001-Have-sufficient-memory-size-for-message.patch
 delete mode 100644 package/libkcapi/0002-Do-not-compile-unused-functions.patch
 delete mode 100644 package/libkcapi/0003-Unify-code-to-read-from-seed-sources.patch
 delete mode 100644 package/libkcapi/0004-internal.h-make-inline-functions-static.patch

Applied to master, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com