diff options
author | Christian Beier <dontmind@freeshell.org> | 2014-12-29 16:22:41 +0100 |
---|---|---|
committer | Christian Beier <dontmind@freeshell.org> | 2014-12-29 16:22:41 +0100 |
commit | 91261e52d95ef30e9367a928b4151ec0063b2982 (patch) | |
tree | cfb83eca7b2e1715e7e46c78cae1ee08fc225bad | |
parent | 53becab94cccbcab9b20efd24b6071c2f3557eff (diff) | |
parent | aaee22aaa2d958514a7e3538b37e2383f8fe0f76 (diff) | |
download | libtdevnc-91261e52d95ef30e9367a928b4151ec0063b2982.tar.gz libtdevnc-91261e52d95ef30e9367a928b4151ec0063b2982.zip |
Merge pull request #49 from maxnet/master
Fix libva related compile errors
-rw-r--r-- | client_examples/gtkvncviewer.c | 2 | ||||
-rw-r--r-- | configure.ac | 5 | ||||
-rw-r--r-- | libvncclient/h264.c | 4 | ||||
-rw-r--r-- | libvncclient/zrle.c | 2 |
4 files changed, 8 insertions, 5 deletions
diff --git a/client_examples/gtkvncviewer.c b/client_examples/gtkvncviewer.c index 261b2da..861e4e3 100644 --- a/client_examples/gtkvncviewer.c +++ b/client_examples/gtkvncviewer.c @@ -588,7 +588,7 @@ static void GtkDefaultLog (const char *format, ...) time (&log_clock); strftime (buf, 255, "%d/%m/%Y %X ", localtime (&log_clock)); - fprintf (stdout, buf); + fprintf (stdout, "%s", buf); vfprintf (stdout, format, args); fflush (stdout); diff --git a/configure.ac b/configure.ac index ca9f3b3..fe8b1de 100644 --- a/configure.ac +++ b/configure.ac @@ -150,12 +150,11 @@ AM_CONDITIONAL(HAVE_LIBSSL, test ! -z "$SSL_LIBS") # See if we want libva support -# TODO: check if library actually exists AH_TEMPLATE(CONFIG_LIBVA, [Build libva support]) AC_ARG_WITH(libva, -[ --with-libva build libva support],,) +[ --without-libva disable support for libva],,) if test "x$with_libva" != "xno"; then - AC_CHECK_LIB(va, vaInitialize, + AC_CHECK_LIB(va-x11, vaGetDisplay, VA_LIBS="-lva -lva-x11" [AC_DEFINE(CONFIG_LIBVA) CONFIG_LIBVA="true"], ,) fi diff --git a/libvncclient/h264.c b/libvncclient/h264.c index 1d94454..c63a713 100644 --- a/libvncclient/h264.c +++ b/libvncclient/h264.c @@ -20,6 +20,10 @@ #ifdef LIBVNCSERVER_CONFIG_LIBVA #include <X11/Xlib.h> +#include <va/va_version.h> +#if VA_CHECK_VERSION(0,34,0) +#include <va/va_compat.h> +#endif #include <va/va_x11.h> enum _slice_types { diff --git a/libvncclient/zrle.c b/libvncclient/zrle.c index 7f488b5..0128146 100644 --- a/libvncclient/zrle.c +++ b/libvncclient/zrle.c @@ -198,7 +198,7 @@ HandleZRLE (rfbClient* client, int rx, int ry, int rw, int rh) for(i=0; i<rw; i+=rfbZRLETileWidth) { int subWidth=(i+rfbZRLETileWidth>rw)?rw-i:rfbZRLETileWidth; int subHeight=(j+rfbZRLETileHeight>rh)?rh-j:rfbZRLETileHeight; - int result=HandleZRLETile(client,buf,remaining,rx+i,ry+j,subWidth,subHeight); + int result=HandleZRLETile(client,(uint8_t *)buf,remaining,rx+i,ry+j,subWidth,subHeight); if(result<0) { rfbClientLog("ZRLE decoding failed (%d)\n",result); |