Add checks for whether gdk-pixbuf exists before using avatar set

This commit is contained in:
MarcoPolo-PasTonMolo
2022-05-26 21:06:27 +03:00
parent 6a44e18853
commit 0cff111249
6 changed files with 31 additions and 3 deletions

View File

@@ -65,6 +65,8 @@ AC_ARG_WITH([themes],
[AS_HELP_STRING([--with-themes[[=PATH]]], [install themes (default yes)])])
AC_ARG_ENABLE([icons-and-clipboard],
[AS_HELP_STRING([--enable-icons-and-clipboard], [enable GTK tray icons and clipboard paste support])])
AC_ARG_ENABLE([gdk-pixbuf],
[AS_HELP_STRING([--enable-gdk-pixbuf], [enable GDK Pixbuf support])])
# Required dependencies
@@ -306,6 +308,15 @@ if test "x$enable_otr" != xno; then
AM_COND_IF([BUILD_OTR], [AC_DEFINE([HAVE_LIBOTR], [1], [Have libotr])])
fi
dnl feature: pixbuf
AS_IF([test "x$enable_pixbuf" != xno],
[PKG_CHECK_MODULES([gdk_pixbuf], [gdk-pixbuf-2.0 >= 2.4],
[AC_DEFINE([HAVE_PIXBUF], [1], [gdk-pixbuf module])],
[AS_IF([test "x$enable_pixbuf" = xyes],
[AC_MSG_ERROR([gdk-pixbuf-2.0 >= 2.4 is required for GDK Pixbuf support])],
[AC_MSG_NOTICE([gdk-pixbuf-2.0 >= 2.4 not found, GDK Pixbuf support not enabled])])])])
dnl feature: omemo
AM_CONDITIONAL([BUILD_OMEMO], [false])
if test "x$enable_omemo" != xno; then