GUACAMOLE-1133: Merge build-time sanity check for libvncserver usage of gcrypt.

This commit is contained in:
Mike Jumper 2021-01-24 14:15:35 -08:00 committed by GitHub
commit c122a5f14a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 22 additions and 0 deletions

View File

@ -57,6 +57,7 @@ ARG BUILD_DEPENDENCIES=" \
freerdp2-dev \ freerdp2-dev \
gcc \ gcc \
libcairo2-dev \ libcairo2-dev \
libgcrypt-dev \
libjpeg62-turbo-dev \ libjpeg62-turbo-dev \
libossp-uuid-dev \ libossp-uuid-dev \
libpango1.0-dev \ libpango1.0-dev \

View File

@ -519,6 +519,27 @@ then
AC_CHECK_LIB([vncclient], [rfbInitClient], [VNC_LIBS="$VNC_LIBS -lvncclient"], [have_libvncserver=no]) AC_CHECK_LIB([vncclient], [rfbInitClient], [VNC_LIBS="$VNC_LIBS -lvncclient"], [have_libvncserver=no])
fi fi
#
# Underlying libvncserver usage of gcrypt
#
if test "x${have_libvncserver}" = "xyes"
then
# Whether libvncserver was built against libgcrypt
AC_CHECK_DECL([LIBVNCSERVER_WITH_CLIENT_GCRYPT],
[AC_CHECK_HEADER(gcrypt.h,,
[AC_MSG_WARN([
--------------------------------------------
libvncserver appears to be built against
libgcrypt, but the libgcrypt headers
could not be found. VNC will be disabled.
--------------------------------------------])
have_libvncserver=no])],,
[[#include <rfb/rfbconfig.h>]])
fi
AM_CONDITIONAL([ENABLE_VNC], [test "x${have_libvncserver}" = "xyes"]) AM_CONDITIONAL([ENABLE_VNC], [test "x${have_libvncserver}" = "xyes"])
AC_SUBST(VNC_LIBS) AC_SUBST(VNC_LIBS)