+
+# clutter and champlain support
+# ----------------------------------------------------------------------
+
+AC_ARG_ENABLE([map],
+ AC_HELP_STRING([--enable-map], [enable map support]),
+ [libgps=$enableval], [libgps=no])
+
+AC_ARG_ENABLE([gpu-accel],
+ AC_HELP_STRING([--enable-gpu-accel], [enable GPU acceleration support - experimental]),
+ [libclutter=$enableval], [libclutter=auto])
+
+if test "x${libclutter}" = "xyes" -o "x${libgps}" = "xyes"; then
+ if test "x${libclutter}" != "xno" -a "x${gtk3}" != "xno"; then
+ PKG_CHECK_MODULES(CLUTTER, [clutter-1.0 >= 1.0],
+ [
+ PKG_CHECK_MODULES(CLUTTER_GTK, [clutter-gtk-1.0 >= 1.0],
+ [
+ HAVE_CLUTTER=yes
+ AC_DEFINE(HAVE_CLUTTER, 1, [define to enable use of clutter library])
+ ],
+ [
+ HAVE_CLUTTER=no
+ AC_MSG_WARN([$CLUTTER_GTK_PKG_ERRORS])
+ ])
+ ],
+ [
+ HAVE_CLUTTER=no
+ AC_MSG_WARN([$CLUTTER_PKG_ERRORS])
+ ])
+ else
+ HAVE_CLUTTER=disabled
+ fi
+else
+ HAVE_CLUTTER=disabled
+fi
+
+AC_SUBST(CLUTTER_CFLAGS)
+AC_SUBST(CLUTTER_LIBS)
+AC_SUBST(CLUTTER_GTK_CFLAGS)
+AC_SUBST(CLUTTER_GTK_LIBS)
+
+
+# Libchamplain support - used for map facility
+# ----------------------------------------------------------------------
+
+if test "x${libgps}" = "xyes" -a "x${HAVE_CLUTTER}" = "xyes"; then
+ if test "x${gtk3}" != "xno"; then
+ PKG_CHECK_MODULES(LIBCHAMPLAIN, [champlain-0.12 >= 0.12],
+ [
+ HAVE_LIBCHAMPLAIN=yes
+ AC_DEFINE(HAVE_LIBCHAMPLAIN, 1, [define to enable use of maps])
+ ],
+ [
+ HAVE_LIBCHAMPLAIN=no
+ AC_MSG_WARN([$LIBCHAMPLAIN_PKG_ERRORS])
+ ])
+ else
+ HAVE_LIBCHAMPLAIN=disabled
+ fi
+else
+ HAVE_LIBCHAMPLAIN=disabled
+fi
+
+if test "x${libgps}" = "xyes" -a "x${HAVE_LIBCHAMPLAIN}" = "xyes" ; then
+ PKG_CHECK_MODULES(LIBCHAMPLAIN_GTK, [champlain-gtk-0.12 >= 0.12],
+ [
+ HAVE_LIBCHAMPLAIN_GTK=yes
+ AC_DEFINE(HAVE_LIBCHAMPLAIN_GTK, 1, [define to enable use of maps])
+ ],
+ [
+ HAVE_LIBCHAMPLAIN_GTK=no
+ AC_MSG_WARN([$LIBCHAMPLAIN_GTK_PKG_ERRORS])
+ ])
+else
+ HAVE_LIBCHAMPLAIN_GTK=disabled
+fi
+
+AM_CONDITIONAL(HAVE_LIBCHAMPLAIN_GTK, [test "x$HAVE_LIBCHAMPLAIN_GTK" = xyes])
+AC_SUBST(LIBCHAMPLAIN_GTK_CFLAGS)
+AC_SUBST(LIBCHAMPLAIN_GTK_LIBS)
+
+# Lua support
+# ----------------------------------------------------------------------
+
+AC_ARG_ENABLE([lua],
+ AC_HELP_STRING([--disable-lua], [disable lua support]),
+ [liblua=$enableval], [liblua=auto])
+
+if test "x${liblua}" != "xno"; then
+ PKG_CHECK_MODULES(LUA, lua5.1 >= 5.1,
+ [
+ HAVE_LUA=yes
+ AC_DEFINE(HAVE_LUA, 1, [define to enable lua support])
+ ],
+ [
+ HAVE_LUA=no
+ AC_MSG_WARN([$LUA_PKG_ERRORS])
+ ])
+else
+ HAVE_LUA=disabled
+fi
+
+AM_CONDITIONAL(HAVE_LUA, [test "x$HAVE_LUA" = xyes])
+AC_SUBST(LUA_CFLAGS)
+AC_SUBST(LUA_LIBS)
+
+# ----------------------------------------------------------------------
+
+AH_TOP([
+/** \file
+ * \short autogenerated definition by autoheader.
+ * \author Bruclik
+ */
+
+/*
+ * This file is a part of Geeqie project (http://www.geeqie.org/).
+ * Copyright (C) 2008 - 2016 The Geeqie Team
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#ifndef _INCLUDE_CONFIG_H
+#define _INCLUDE_CONFIG_H