opnsense-ports/graphics/sane-backends/files/patch-backend__pieusb_buffer.c
Franco Fichtner 321dd2094f */*: sync with upstream
Taken from: FreeBSD
2015-10-20 07:26:03 +02:00

24 lines
538 B
C

--- backend/pieusb_buffer.c.orig 2015-09-01 00:31:33 UTC
+++ backend/pieusb_buffer.c
@@ -100,6 +100,12 @@
#include <stdio.h>
#include <fcntl.h>
#include <sys/mman.h>
+
+#ifdef HAVE_SYS_ENDIAN_H
+#include <sys/endian.h>
+#endif
+
+#ifdef HAVE_ENDIAN_H
#include <endian.h>
/* When creating the release backend, make complains about unresolved external
@@ -110,6 +116,8 @@
#define le16toh(x) __bswap_16 (x)
#endif
+#endif
+
static void buffer_update_read_index(struct Pieusb_Read_Buffer* buffer, int increment);
/* READER */