summaryrefslogtreecommitdiff
path: root/net/libvncserver
diff options
context:
space:
mode:
authorjperkin <jperkin@pkgsrc.org>2013-02-27 18:24:51 +0000
committerjperkin <jperkin@pkgsrc.org>2013-02-27 18:24:51 +0000
commite77ab68d84199827592f7a745470f7e26746dc93 (patch)
tree635c41ab1df645c4dc1485839740bbcdd9ca9149 /net/libvncserver
parent96daac1fb6f2347983a598876378de606dc4cc0e (diff)
downloadpkgsrc-e77ab68d84199827592f7a745470f7e26746dc93.tar.gz
Add SunOS byteswap support.
Diffstat (limited to 'net/libvncserver')
-rw-r--r--net/libvncserver/distinfo4
-rw-r--r--net/libvncserver/patches/patch-libvncserver_websockets.c13
2 files changed, 12 insertions, 5 deletions
diff --git a/net/libvncserver/distinfo b/net/libvncserver/distinfo
index b5ae8fa02b5..5139ee27095 100644
--- a/net/libvncserver/distinfo
+++ b/net/libvncserver/distinfo
@@ -1,6 +1,6 @@
-$NetBSD: distinfo,v 1.8 2012/05/06 09:08:36 obache Exp $
+$NetBSD: distinfo,v 1.9 2013/02/27 18:24:51 jperkin Exp $
SHA1 (LibVNCServer-0.9.9.tar.gz) = 2004c6ae493baeff3da40b61e0a0f73c83182dad
RMD160 (LibVNCServer-0.9.9.tar.gz) = e62e0903124abb85746bcac6498214fe09c3b4d7
Size (LibVNCServer-0.9.9.tar.gz) = 1678609 bytes
-SHA1 (patch-libvncserver_websockets.c) = 059c8a3d0971caa3a43eb48a69b8ca81e6df0a78
+SHA1 (patch-libvncserver_websockets.c) = 6b9e25e3f54af967d8f6581a2c1e3250b8772693
diff --git a/net/libvncserver/patches/patch-libvncserver_websockets.c b/net/libvncserver/patches/patch-libvncserver_websockets.c
index a46c0c2010d..dd814269447 100644
--- a/net/libvncserver/patches/patch-libvncserver_websockets.c
+++ b/net/libvncserver/patches/patch-libvncserver_websockets.c
@@ -1,10 +1,10 @@
-$NetBSD: patch-libvncserver_websockets.c,v 1.1 2012/05/06 09:08:36 obache Exp $
+$NetBSD: patch-libvncserver_websockets.c,v 1.2 2013/02/27 18:24:51 jperkin Exp $
* byte-order handling for !Linux.
--- libvncserver/websockets.c.orig 2012-05-04 14:19:00.000000000 +0000
+++ libvncserver/websockets.c
-@@ -31,12 +31,34 @@
+@@ -31,12 +31,41 @@
/* errno */
#include <errno.h>
@@ -35,12 +35,19 @@ $NetBSD: patch-libvncserver_websockets.c,v 1.1 2012/05/06 09:08:36 obache Exp $
+#define WS_NTOH16(n) OSSwapBigToHostInt16(n)
+#define WS_HTON64(n) OSSwapHostToBigInt64(n)
+#define WS_HTON16(n) OSSwapHostToBitInt16(n)
++#elif defined(__sun)
++#include <sys/byteorder.h>
++#define WS_NTOH64(n) ntohll(n)
++#define WS_NTOH32(n) ntohl(n)
++#define WS_NTOH16(n) ntohs(n)
++#define WS_HTON64(n) htonll(n)
++#define WS_HTON16(n) htons(n)
+#else
+#include <byteswap.h>
#if defined(__BYTE_ORDER) && defined(__BIG_ENDIAN) && __BYTE_ORDER == __BIG_ENDIAN
#define WS_NTOH64(n) (n)
#define WS_NTOH32(n) (n)
-@@ -50,6 +72,7 @@
+@@ -50,6 +79,7 @@
#define WS_HTON64(n) bswap_64(n)
#define WS_HTON16(n) bswap_16(n)
#endif