kumquat-buildroot/package/libkcapi/0001-Fix-getrandom-call-in-kcapi-rng.c.patch
Fabrice Fontaine 8a7b707ea3 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

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-05-03 22:05:27 +02:00

32 lines
776 B
Diff

From 581717cfb0e35c041246da0c0c591a6e9f7a40e5 Mon Sep 17 00:00:00 2001
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
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 <fontaine.fabrice@gmail.com>
[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