You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@guacamole.apache.org by mj...@apache.org on 2019/04/24 22:35:20 UTC

[guacamole-server] branch master updated: GUACAMOLE-296: Add checks for Stream functions in winpr libraries.

This is an automated email from the ASF dual-hosted git repository.

mjumper pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/guacamole-server.git


The following commit(s) were added to refs/heads/master by this push:
     new 1b8e31b  GUACAMOLE-296: Add checks for Stream functions in winpr libraries.
     new 5e8f5ea  GUACAMOLE-296: Merge changes linking libwinpr / libwinpr-utils as needed.
1b8e31b is described below

commit 1b8e31b70cf11a0b2676795ba1333b0ad43a8fae
Author: Nick Couchman <vn...@apache.org>
AuthorDate: Sun Mar 10 17:08:02 2019 -0400

    GUACAMOLE-296: Add checks for Stream functions in winpr libraries.
---
 configure.ac                  | 17 +++++++++++++++++
 src/protocols/rdp/Makefile.am | 15 ++++++++++-----
 2 files changed, 27 insertions(+), 5 deletions(-)

diff --git a/configure.ac b/configure.ac
index 0acb27b..11e765b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -518,6 +518,7 @@ fi
 
 have_freerdp=disabled
 RDP_LIBS=
+WINPR_LIBS=
 AC_ARG_WITH([rdp],
             [AS_HELP_STRING([--with-rdp],
                             [support RDP @<:@default=check@:>@])],
@@ -719,6 +720,21 @@ then
                                   [#include <freerdp/utils/stream.h>])])
 fi
 
+# Find location of Stream_New and Stream_free
+if test "x${have_freerdp}" = "xyes" -a "x${have_winpr}" = "xyes"
+then
+    AC_CHECK_LIB([winpr], [Stream_New, Stream_Free],
+                 [WINPR_LIBS="$WINPR_LIBS -lwinpr"],
+                 [AC_CHECK_LIB([winpr-utils], [Stream_New, Stream_Free],
+                               [WINPR_LIBS="$WINPR_LIBS -lwinpr-utils"],
+                               [AC_MSG_WARN([
+  ------------------------------------------
+  Unable to locate stream functions in winpr
+  libraries.  RDP will be disabled.
+  ------------------------------------------])
+                                    have_freerdp=no])])
+fi
+
 # Check for types in WinPR
 if test "x${have_freerdp}" = "xyes"
 then
@@ -1027,6 +1043,7 @@ AM_CONDITIONAL([ENABLE_WINPR], [test "x${have_winpr}"   = "xyes"])
 AM_CONDITIONAL([ENABLE_RDP],   [test "x${have_freerdp}" = "xyes"])
 
 AC_SUBST(RDP_LIBS)
+AC_SUBST(WINPR_LIBS)
 
 #
 # libssh2
diff --git a/src/protocols/rdp/Makefile.am b/src/protocols/rdp/Makefile.am
index 29a9674..c3f9444 100644
--- a/src/protocols/rdp/Makefile.am
+++ b/src/protocols/rdp/Makefile.am
@@ -155,7 +155,8 @@ libguac_client_rdp_la_LDFLAGS = \
     -version-info 0:0:0         \
     @CAIRO_LIBS@                \
     @PTHREAD_LIBS@              \
-    @RDP_LIBS@
+    @RDP_LIBS@                  \
+    @WINPR_LIBS@
 
 libguac_client_rdp_la_LIBADD =     \
     @COMMON_LTLIB@                 \
@@ -174,7 +175,8 @@ guacdr_cflags                = \
 guacdr_ldflags =                   \
     -module -avoid-version -shared \
     @PTHREAD_LIBS@                 \
-    @RDP_LIBS@
+    @RDP_LIBS@                     \
+    @WINPR_LIBS@
 
 guacdr_libadd =     \
     @COMMON_LTLIB@  \
@@ -193,7 +195,8 @@ guacai_cflags               =  \
 guacai_ldflags =                   \
     -module -avoid-version -shared \
     @PTHREAD_LIBS@                 \
-    @RDP_LIBS@
+    @RDP_LIBS@                     \
+    @WINPR_LIBS@
 
 guacai_libadd =     \
     @COMMON_LTLIB@  \
@@ -212,7 +215,8 @@ guacsnd_cflags               = \
 guacsnd_ldflags =                  \
     -module -avoid-version -shared \
     @PTHREAD_LIBS@                 \
-    @RDP_LIBS@
+    @RDP_LIBS@                     \
+    @WINPR_LIBS@
 
 guacsnd_libadd =    \
     @COMMON_LTLIB@  \
@@ -231,7 +235,8 @@ guacsvc_cflags               = \
 guacsvc_ldflags =                  \
     -module -avoid-version -shared \
     @PTHREAD_LIBS@                 \
-    @RDP_LIBS@
+    @RDP_LIBS@                     \
+    @WINPR_LIBS@
 
 guacsvc_libadd =    \
     @COMMON_LTLIB@  \