aports/community/signify/gcc14.patch

30 lines
1021 B
Diff

Fix -Wimplicit-function-declaration error with gcc 14.
Based on a PR and upstream comments at: Fix build with clang 16
https://github.com/aperezdc/signify/pull/43
Error:
```
signify.c: In function 'parseb64file':
signify.c:144:13: error: implicit declaration of function 'b64_pton' [-Wimplicit-function-declaration]
144 | if (b64_pton(commentend + 1, buf, buflen) != buflen)
| ^~~~~~~~
signify.c: In function 'createheader':
signify.c:231:13: error: implicit declaration of function 'b64_ntop' [-Wimplicit-function-declaration]
231 | if (b64_ntop(buf, buflen, b64, sizeof(b64)) == -1)
| ^~~~~~~~
```
--- signify-32-origin/compat.h
+++ signify-32/compat.h
@@ -56,4 +56,8 @@
extern void explicit_bzero(void *buf, size_t len);
#endif /* BUNDLED_BZERO */
+extern int b64_ntop(unsigned char const *src, size_t srclength, char *target,
+ size_t targsize);
+extern int b64_pton(char const *src, unsigned char *target, size_t targsize);
+
#endif /* !COMPAT_H */