diff --git a/ChangeLog b/ChangeLog index 38cc012..36994e9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,6 @@ +2004-01-16 Johannes E. Schindelin + * compile fix for cygwin + 2004-01-09 Karl Runge * x11vnc options -allow, -localhost, -nodragging, -input_skip * minimize memory usage under -nofb diff --git a/cargs.c b/cargs.c index c436f2c..f393698 100644 --- a/cargs.c +++ b/cargs.c @@ -53,7 +53,7 @@ rfbProcessArguments(rfbScreenInfoPtr rfbScreen,int* argc, char *argv[]) { int i,i1; - if(!argc) return; + if(!argc) return TRUE; for (i = i1 = 1; i < *argc;) { if (strcmp(argv[i], "-help") == 0) { diff --git a/configure.ac b/configure.ac index 147be1f..5c4bfba 100644 --- a/configure.ac +++ b/configure.ac @@ -103,6 +103,10 @@ AC_CHECK_LIB(nsl,gethostbyname) AC_CHECK_LIB(socket,socket) AC_CHECK_FUNCS([ftime gethostbyname gethostname gettimeofday inet_ntoa memmove memset mkfifo select socket strchr strcspn strdup strerror strstr setsid]) +# check, if shmget is in cygipc.a +AC_CHECK_LIB(cygipc,shmget) +AM_CONDITIONAL(CYGIPC, test "$HAVE_CYGIPC" = "true") + # Check if /dev/vcsa1 exists, if so, define LINUX AM_CONDITIONAL(LINUX, test -c /dev/vcsa1) diff --git a/contrib/Makefile.am b/contrib/Makefile.am index 8d00a9a..848b9a2 100644 --- a/contrib/Makefile.am +++ b/contrib/Makefile.am @@ -3,11 +3,15 @@ LDADD = ../libvncserver.a noinst_PROGRAMS=zippy +if CYGIPC +LD_CYGIPC=-lcygipc +endif + if HAVE_X bin_PROGRAMS=x11vnc x11vnc_SOURCES=x11vnc.c INCLUDES=@X_CFLAGS@ -x11vnc_LDADD=@X_LIBS@ $(LDADD) +x11vnc_LDADD=@X_LIBS@ $(LD_CYGIPC) $(LDADD) endif zippy_SOURCES=zippy.c diff --git a/rfbserver.c b/rfbserver.c index 3c6aec8..914aa0b 100644 --- a/rfbserver.c +++ b/rfbserver.c @@ -228,7 +228,6 @@ rfbNewTCPOrUDPClient(rfbScreen,sock,isUDP) rfbClientPtr cl,cl_; struct sockaddr_in addr; size_t addrlen = sizeof(struct sockaddr_in); - int i; cl = (rfbClientPtr)calloc(sizeof(rfbClientRec),1); @@ -317,8 +316,11 @@ rfbNewTCPOrUDPClient(rfbScreen,sock,isUDP) #ifdef LIBVNCSERVER_HAVE_LIBJPEG cl->tightCompressLevel = TIGHT_DEFAULT_COMPRESSION; cl->tightQualityLevel = -1; - for (i = 0; i < 4; i++) - cl->zsActive[i] = FALSE; + { + int i; + for (i = 0; i < 4; i++) + cl->zsActive[i] = FALSE; + } #endif cl->enableCursorShapeUpdates = FALSE; diff --git a/vncauth.c b/vncauth.c index 1843434..2146e67 100644 --- a/vncauth.c +++ b/vncauth.c @@ -22,6 +22,8 @@ */ #include +#include +#include #include #include "d3des.h"