aports/community/java-netty-transport-native/musl-compat.patch

22 lines
832 B
Diff

--- a/src/main/c/netty_epoll_native.c
+++ b/src/main/c/netty_epoll_native.c
@@ -86,7 +86,7 @@
extern int epoll_create1(int flags) __attribute__((weak));
extern int epoll_pwait2(int epfd, struct epoll_event *events, int maxevents, const struct timespec *timeout, const sigset_t *sigmask) __attribute__((weak));
-#ifndef __USE_GNU
+#ifndef _GNU_SOURCE
struct mmsghdr {
struct msghdr msg_hdr; /* Message header */
unsigned int msg_len; /* Number of bytes transmitted */
--- a/src/main/c/netty_epoll_linuxsocket.c
+++ b/src/main/c/netty_epoll_linuxsocket.c
@@ -26,6 +26,7 @@
#include <errno.h>
#include <netinet/in.h>
#include <netinet/udp.h> // SOL_UDP
+#include <sys/types.h>
#include <sys/sendfile.h>
#include <linux/tcp.h> // TCP_NOTSENT_LOWAT is a linux specific define
#include "netty_epoll_linuxsocket.h"