diff options
author | Marcelo Araujo <araujo@FreeBSD.org> | 2017-07-05 08:04:36 +0000 |
---|---|---|
committer | Marcelo Araujo <araujo@FreeBSD.org> | 2017-07-05 08:04:36 +0000 |
commit | 37134177895e45b36d98999b0ae8dd8f6070d5b2 (patch) | |
tree | d6edd01b1cdb1a612486633aa3432f96a9d2965d | |
parent | 4e4fd724ab67b9762d4af0e902024824f4de0dbb (diff) |
- Add few patches that fixes some usability such like md5 and sha1 when
we use the shared library with dlopen(3).
- Bump PORTREVISION.
Sponsored by: iXsystems, Inc.
Notes
Notes:
svn path=/head/; revision=445054
-rw-r--r-- | net/libvncserver/Makefile | 1 | ||||
-rw-r--r-- | net/libvncserver/files/patch-common_md5.c | 11 | ||||
-rw-r--r-- | net/libvncserver/files/patch-common_md5.h | 59 | ||||
-rw-r--r-- | net/libvncserver/files/patch-common_vncauth.c | 22 | ||||
-rw-r--r-- | net/libvncserver/files/patch-rfb_rfb.h | 20 |
5 files changed, 113 insertions, 0 deletions
diff --git a/net/libvncserver/Makefile b/net/libvncserver/Makefile index 480e1e5f3fdd..c617b19d266b 100644 --- a/net/libvncserver/Makefile +++ b/net/libvncserver/Makefile @@ -3,6 +3,7 @@ PORTNAME= libvncserver PORTVERSION= 0.9.11 +PORTREVISION= 1 DISTVERSIONPREFIX= LibVNCServer- CATEGORIES= net devel diff --git a/net/libvncserver/files/patch-common_md5.c b/net/libvncserver/files/patch-common_md5.c new file mode 100644 index 000000000000..c2b4aa538622 --- /dev/null +++ b/net/libvncserver/files/patch-common_md5.c @@ -0,0 +1,11 @@ +--- common/md5.c.orig 2017-07-05 07:48:23 UTC ++++ common/md5.c +@@ -29,7 +29,7 @@ + #include "md5.h" + + /* #ifdef _LIBC */ +-# include <endian.h> ++# include <sys/endian.h> + # if __BYTE_ORDER == __BIG_ENDIAN + # define WORDS_BIGENDIAN 1 + # endif diff --git a/net/libvncserver/files/patch-common_md5.h b/net/libvncserver/files/patch-common_md5.h new file mode 100644 index 000000000000..585fa75eeb32 --- /dev/null +++ b/net/libvncserver/files/patch-common_md5.h @@ -0,0 +1,59 @@ +--- common/md5.h.orig 2017-07-05 07:48:49 UTC ++++ common/md5.h +@@ -98,21 +98,21 @@ struct md5_ctx + + /* Initialize structure containing state of computation. + (RFC 1321, 3.3: Step 3) */ +-extern void __md5_init_ctx (struct md5_ctx *ctx) __THROW; ++extern void __md5_init_ctx (struct md5_ctx *ctx) ; + + /* Starting with the result of former calls of this function (or the + initialization function update the context for the next LEN bytes + starting at BUFFER. + It is necessary that LEN is a multiple of 64!!! */ + extern void __md5_process_block (const void *buffer, size_t len, +- struct md5_ctx *ctx) __THROW; ++ struct md5_ctx *ctx) ; + + /* Starting with the result of former calls of this function (or the + initialization function update the context for the next LEN bytes + starting at BUFFER. + It is NOT required that LEN is a multiple of 64. */ + extern void __md5_process_bytes (const void *buffer, size_t len, +- struct md5_ctx *ctx) __THROW; ++ struct md5_ctx *ctx) ; + + /* Process the remaining bytes in the buffer and put result from CTX + in first 16 bytes following RESBUF. The result is always in little +@@ -121,7 +121,7 @@ extern void __md5_process_bytes (const void *buffer, s + + IMPORTANT: On some systems it is required that RESBUF is correctly + aligned for a 32 bits value. */ +-extern void *__md5_finish_ctx (struct md5_ctx *ctx, void *resbuf) __THROW; ++extern void *__md5_finish_ctx (struct md5_ctx *ctx, void *resbuf) ; + + + /* Put result from CTX in first 16 bytes following RESBUF. The result is +@@ -130,19 +130,19 @@ extern void *__md5_finish_ctx (struct md5_ctx *ctx, vo + + IMPORTANT: On some systems it is required that RESBUF is correctly + aligned for a 32 bits value. */ +-extern void *__md5_read_ctx (const struct md5_ctx *ctx, void *resbuf) __THROW; ++extern void *__md5_read_ctx (const struct md5_ctx *ctx, void *resbuf) ; + + + /* Compute MD5 message digest for bytes read from STREAM. The + resulting message digest number will be written into the 16 bytes + beginning at RESBLOCK. */ +-extern int __md5_stream (FILE *stream, void *resblock) __THROW; ++extern int __md5_stream (FILE *stream, void *resblock) ; + + /* Compute MD5 message digest for LEN bytes beginning at BUFFER. The + result is always in little endian byte order, so that a byte-wise + output yields to the wanted ASCII representation of the message + digest. */ + extern void *__md5_buffer (const char *buffer, size_t len, +- void *resblock) __THROW; ++ void *resblock) ; + + #endif /* md5.h */ diff --git a/net/libvncserver/files/patch-common_vncauth.c b/net/libvncserver/files/patch-common_vncauth.c new file mode 100644 index 000000000000..ddbe8704295e --- /dev/null +++ b/net/libvncserver/files/patch-common_vncauth.c @@ -0,0 +1,22 @@ +--- common/vncauth.c.orig 2017-07-05 07:43:58 UTC ++++ common/vncauth.c +@@ -42,6 +42,10 @@ + #include <sys/stat.h> + #endif + ++#ifdef __FreeBSD__ ++#include <fcntl.h> ++#endif ++ + #include <time.h> + + #ifdef WIN32 +@@ -196,6 +200,8 @@ rfbEncryptBytes(unsigned char *bytes, char *passwd) + rfbDes(bytes+i, bytes+i); + } + } ++ ++void rfbEncryptBytes2(unsigned char *, const int, unsigned char *); + + void + rfbEncryptBytes2(unsigned char *where, const int length, unsigned char *key) { diff --git a/net/libvncserver/files/patch-rfb_rfb.h b/net/libvncserver/files/patch-rfb_rfb.h new file mode 100644 index 000000000000..6276f8584c50 --- /dev/null +++ b/net/libvncserver/files/patch-rfb_rfb.h @@ -0,0 +1,20 @@ +--- rfb/rfb.h.orig 2017-07-05 07:45:47 UTC ++++ rfb/rfb.h +@@ -43,7 +43,7 @@ extern "C" + #include <string.h> + #include <rfb/rfbproto.h> + +-#if defined(ANDROID) || defined(LIBVNCSERVER_HAVE_ANDROID) ++#if defined(ANDROID) || defined(LIBVNCSERVER_HAVE_ANDROID) || defined(__FreeBSD__) + #include <arpa/inet.h> + #include <sys/select.h> + #endif +@@ -265,6 +265,8 @@ typedef struct _rfbScreenInfo + rfbBool autoPort; + int port; + SOCKET listenSock; ++ SOCKET unixSock; ++ const char *unixSockPath; + int maxSock; + int maxFd; + #ifdef WIN32 |