Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 1 | From 78247d478cec254bad27f4ed97b532f4f54bf1b0 Mon Sep 17 00:00:00 2001 |
| 2 | From: Pierre-Jean Texier <pjtexier@koncepto.io> |
| 3 | Date: Thu, 23 Jan 2020 19:14:40 +0100 |
| 4 | Subject: [PATCH 1/2] zck.h: fix build on musl |
| 5 | |
| 6 | The ssize_t type requires the <sys/types.h> header. This fixes build with musl |
| 7 | libc: |
| 8 | |
| 9 | include/zck.h:68:1: error: unknown type name 'ssize_t'; did you mean 'size_t'? |
| 10 | 68 | ssize_t zck_read(zckCtx *zck, char *dst, size_t dst_size) |
| 11 | | ^~~~~~~ |
| 12 | | size_t |
| 13 | include/zck.h:81:1: error: unknown type name 'ssize_t'; did you mean 'size_t'? |
| 14 | 81 | ssize_t zck_write(zckCtx *zck, const char *src, const size_t src_size) |
| 15 | | ^~~~~~~ |
| 16 | | size_t |
| 17 | |
| 18 | Upstream-Status: Submitted [https://github.com/zchunk/zchunk/pull/23] |
| 19 | |
| 20 | Signed-off-by: Pierre-Jean Texier <pjtexier@koncepto.io> |
| 21 | --- |
| 22 | include/zck.h.in | 1 + |
| 23 | 1 file changed, 1 insertion(+) |
| 24 | |
| 25 | diff --git a/include/zck.h.in b/include/zck.h.in |
| 26 | index 91d2557..b847576 100644 |
| 27 | --- a/include/zck.h.in |
| 28 | +++ b/include/zck.h.in |
| 29 | @@ -5,6 +5,7 @@ |
| 30 | |
| 31 | #include <stdlib.h> |
| 32 | #include <stdbool.h> |
| 33 | +#include <sys/types.h> |
| 34 | |
| 35 | typedef enum zck_hash { |
| 36 | ZCK_HASH_SHA1, |
| 37 | -- |
| 38 | 2.7.4 |
| 39 | |