Preparing release
[geeqie.git] / configure.ac
index 941d610..79d8f1f 100644 (file)
@@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script.  -*- Autoconf
  -*-
 
 dnl This file is a part of Geeqie project (http://www.geeqie.org/).
-dnl Copyright (C) 2008 - 2018 The Geeqie Team
+dnl Copyright (C) 2008 - 2019 The Geeqie Team
 dnl
 dnl This program is free software; you can redistribute it and/or modify
 dnl it under the terms of the GNU General Public License as published by
@@ -15,7 +15,7 @@ dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 dnl GNU General Public License for more details.
 
 AC_PREREQ(2.57)
-AC_INIT([geeqie], m4_esyscmd_s(git rev-parse --quiet --verify --short HEAD), [geeqie@freelists.org], [], [http://www.geeqie.org/])
+AC_INIT([geeqie], 1.5.1, [https://github.com/BestImageViewer/geeqie/issues], [], [http://www.geeqie.org/])
 
 # Add -Werror to the default CFLAGS
 CFLAGS+=" -Werror -Wno-error=deprecated-declarations -Wno-error=sign-compare -Wno-error=return-type"
@@ -197,17 +197,12 @@ else
   prefix=$prefix
 fi
 
-AM_PATH_GLIB_2_0(2.24.0,,AC_MSG_ERROR(GLIB >= 2.24.0 not installed.))
-AC_ARG_ENABLE([gtk3], AC_HELP_STRING([--disable-gtk3], [use gtk2 instead of gtk3]),[gtk3="${enableval}"], [gtk3=m4_ifdef([AM_PATH_GTK_3_0], [auto], [no])])
+AM_PATH_GLIB_2_0(2.52.0,,AC_MSG_ERROR(GLIB >= 2.52.0 not installed.))
+AC_ARG_ENABLE([gtk3], AC_HELP_STRING([--enable-gtk3], [use gtk3 instead of gtk2]),[gtk3="${enableval}"], [gtk3=m4_ifdef([AM_PATH_GTK_3_0], m4_ifdef([AM_PATH_GTK_2_0], [no], [auto]), [no])])
 
 if test x$gtk3 = xyes; then
     AC_MSG_WARN("Gtk3 enabled")
     m4_ifdef([AM_PATH_GTK_3_0], [AM_PATH_GTK_3_0(3.0.0,,AC_MSG_ERROR(GTK+ >= 3.0.0 not installed.))])
-else
-    if test x$gtk3 != xno; then
-       AC_MSG_WARN("Gtk3 is preferred...")
-       m4_ifdef([AM_PATH_GTK_3_0], [AM_PATH_GTK_3_0(3.0.0,,[gtk3=no])])
-    fi
 fi
 
 if test x$gtk3 = xno; then
@@ -523,15 +518,29 @@ AC_ARG_ENABLE([lua],
     [liblua=$enableval], [liblua=auto])
 
 if test "x${liblua}" != "xno"; then
-  PKG_CHECK_MODULES(LUA, lua5.1 >= 5.1,
+  PKG_CHECK_MODULES(LUA, lua5.3 >= 5.3,
     [
       HAVE_LUA=yes
       AC_DEFINE(HAVE_LUA, 1, [define to enable lua support])
     ],
     [
-      HAVE_LUA=no
-      AC_MSG_WARN([$LUA_PKG_ERRORS])
-    ])
+     PKG_CHECK_MODULES(LUA, lua5.1 >= 5.1,
+       [
+        HAVE_LUA=yes
+        AC_DEFINE(HAVE_LUA, 1, [define to enable lua support])
+       ],
+       [
+        PKG_CHECK_MODULES(LUA, lua >= 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
@@ -574,6 +583,21 @@ AC_SUBST(PDF_LIBS)
 
 AM_CONDITIONAL(HAVE_MARKDOWN, [ "$(command -v markdown)" ])
 
+# _NL_TIME_FIRST_WEEKDAY support
+# note that it is an enum and not a define
+# ----------------------------------------------------------------------
+
+AC_MSG_CHECKING([for _NL_TIME_FIRST_WEEKDAY])
+AC_TRY_LINK([#include <langinfo.h>], [
+char c;
+c = *((unsigned char *)  nl_langinfo(_NL_TIME_FIRST_WEEKDAY));
+], nl_ok=yes, nl_ok=no)
+AC_MSG_RESULT($nl_ok)
+if test "$nl_ok" = "yes"; then
+  AC_DEFINE([HAVE__NL_TIME_FIRST_WEEKDAY], [1],
+      [Define if _NL_TIME_FIRST_WEEKDAY is available])
+fi
+
 # ----------------------------------------------------------------------
 
 AH_TOP([