Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame^] | 1 | From ec6000b9f287e62cb0746e26cfa4372c7ea528f4 Mon Sep 17 00:00:00 2001 |
| 2 | From: Andrea Adami <andrea.adami@gmail.com> |
| 3 | Date: Thu, 19 Apr 2018 23:26:43 +0200 |
| 4 | Subject: [PATCH] sha256.h: avoid inclusion of sys/types.h |
| 5 | |
| 6 | Fix |
| 7 | |
| 8 | purgatory/printf.c:2:10: fatal error: limits.h: |
| 9 | No such file or directory |
| 10 | |
| 11 | Upstream-Status: Inappropriate [klibc specific] |
| 12 | Signed-off-by: Andrea Adami <andrea.adami@gmail.com> |
| 13 | |
| 14 | --- |
| 15 | util_lib/include/sha256.h | 4 ++++ |
| 16 | 1 file changed, 4 insertions(+) |
| 17 | |
| 18 | diff --git a/util_lib/include/sha256.h b/util_lib/include/sha256.h |
| 19 | index 467fb22..40fd3ed 100644 |
| 20 | --- a/util_lib/include/sha256.h |
| 21 | +++ b/util_lib/include/sha256.h |
| 22 | @@ -1,7 +1,11 @@ |
| 23 | #ifndef SHA256_H |
| 24 | #define SHA256_H |
| 25 | |
| 26 | +#ifndef __KLIBC__ |
| 27 | #include <sys/types.h> |
| 28 | +#else |
| 29 | +#include <stddef.h> |
| 30 | +#endif |
| 31 | #include <stdint.h> |
| 32 | |
| 33 | typedef struct |
| 34 | -- |
| 35 | 2.7.4 |
| 36 | |