Run autoupdate to remove many warnings

Autoconf 2.71 now show all warnings. Instead of cherry picking the 2.4
patch, the choice was made to apply autoupdate directly.

Additionally, AC_INIT now clearly indicates that automake >= 1.14 is required.
This commit is contained in:
Jean-Marc Lasgouttes 2022-04-28 15:31:54 +02:00
parent b65c5480e8
commit 2849127f44
4 changed files with 65 additions and 86 deletions

View File

@ -19,14 +19,14 @@ AC_MSG_CHECKING([for build type])
lyx_devel_version=no
lyx_prerelease=no
AC_ARG_ENABLE(build-type,
AC_HELP_STRING([--enable-build-type=STR],[set build type to rel(ease), pre(release), dev(elopment), prof(iling), or gprof (default: LYX_BUILD_TYPE)]),
AS_HELP_STRING([--enable-build-type=STR],[set build type to rel(ease), pre(release), dev(elopment), prof(iling), or gprof (default: LYX_BUILD_TYPE)]),
[case $enableval in
dev*) build_type=development;;
pre*) build_type=prerelease;;
prof*) build_type=profiling;;
gprof*) build_type=gprof;;
rel*) build_type=release;;
*) AC_MSG_ERROR([bad build type specification \"$enableval\". Please use one of rel(ease), pre(release), dev(elopment), prof(iling), or gprof]);;
*) AC_MSG_ERROR([bad build type specification '$enableval'. Please use one of rel(ease), pre(release), dev(elopment), prof(iling), or gprof]);;
esac],
[build_type=LYX_BUILD_TYPE])
AC_MSG_RESULT([$build_type])
@ -49,7 +49,7 @@ AC_MSG_CHECKING([for version suffix])
dnl We need the literal double quotes in the rpm spec file
RPM_VERSION_SUFFIX='""'
AC_ARG_WITH(version-suffix,
[AC_HELP_STRING([--with-version-suffix@<:@=STR@:>@], install lyx files as lyxSTR (default STR: -AC_PACKAGE_VERSION))],
[AS_HELP_STRING([--with-version-suffix@<:@=STR@:>@],[install lyx files as lyxSTR (default STR: -AC_PACKAGE_VERSION)])],
[if test "x$withval" = "xyes";
then
withval="-"AC_PACKAGE_VERSION
@ -138,12 +138,11 @@ dnl Usage: LYX_PROG_CLANG: set CLANG to yes if the compiler is clang.
AC_DEFUN([LYX_PROG_CLANG],
[AC_CACHE_CHECK([whether the compiler is clang],
[lyx_cv_prog_clang],
[AC_TRY_COMPILE([], [
[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[
#ifndef __clang__
this is not clang
#endif
],
[lyx_cv_prog_clang=yes ; CLANG=yes], [lyx_cv_prog_clang=no ; CLANG=no])])
]])],[lyx_cv_prog_clang=yes ; CLANG=yes],[lyx_cv_prog_clang=no ; CLANG=no])])
if test $CLANG = yes ; then
AC_CACHE_CHECK([for clang version],
[lyx_cv_clang_version],
@ -172,7 +171,7 @@ AC_DEFUN([LYX_CXX_CXX11_FLAGS],
save_CXXFLAGS=$CXXFLAGS
CXXFLAGS="$flag $AM_CXXFLAGS $CXXFLAGS"
dnl sample openmp source code to test
AC_TRY_COMPILE([
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
template <typename T>
struct check
{
@ -195,13 +194,12 @@ AC_DEFUN([LYX_CXX_CXX11_FLAGS],
check_type c;
check_type&& cr = static_cast<check_type&&>(c);
auto d = a;], [],
[lyx_cv_cxx11_flags=$flag; break])
auto d = a;]], [[]])],[lyx_cv_cxx11_flags=$flag; break],[])
CXXFLAGS=$save_CXXFLAGS
CPPFLAGS=$save_CPPFLAGS
done])
if test $lyx_cv_cxx11_flags = none ; then
AC_ERROR([Cannot find suitable C++11 mode for compiler $CXX])
AC_MSG_ERROR(Cannot find suitable C++11 mode for compiler $CXX)
fi
AM_CXXFLAGS="$lyx_cv_cxx11_flags $AM_CXXFLAGS"
])
@ -212,7 +210,7 @@ dnl decide whether we want to use std::regex and set the
dnl LYX_USE_STD_REGEX macro and conditional accordingly.
AC_DEFUN([LYX_CXX_USE_REGEX],
[AC_ARG_ENABLE(std-regex,
AC_HELP_STRING([--enable-std-regex],[use std::regex instead of boost::regex (default is autodetected)]),
AS_HELP_STRING([--enable-std-regex],[use std::regex instead of boost::regex (default is autodetected)]),
[lyx_std_regex=$enableval],
[AC_MSG_CHECKING([for correct regex implementation])
save_CPPFLAGS=$CPPFLAGS
@ -221,20 +219,19 @@ AC_DEFUN([LYX_CXX_USE_REGEX],
CXXFLAGS="$AM_CXXFLAGS $CXXFLAGS"
# The following code snippet has been taken taken from example in
# http://stackoverflow.com/questions/8561850/compile-stdregex-iterator-with-gcc
AC_TRY_LINK(
[
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
#include <regex>
#include <iostream>
#include <string.h>
typedef std::regex_iterator<const char *> Myiter;
], [
]], [[
const char *pat = "axayaz";
Myiter::regex_type rx("a");
Myiter next(pat, pat + strlen(pat), rx);
Myiter end;
], [lyx_std_regex=yes], [lyx_std_regex=no])
]])],[lyx_std_regex=yes],[lyx_std_regex=no])
CXXFLAGS=$save_CXXFLAGS
CPPFLAGS=$save_CPPFLAGS
AC_MSG_RESULT([$lyx_std_regex])
@ -257,13 +254,12 @@ AC_DEFUN([LYX_CXX_USE_CALL_ONCE],
CPPFLAGS="$AM_CPPFLAGS $CPPFLAGS"
save_CXXFLAGS=$CXXFLAGS
CXXFLAGS="$AM_CXXFLAGS $CXXFLAGS"
AC_TRY_LINK(
[
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
#include <mutex>
static std::once_flag flag;
], [
]], [[
std::call_once(flag, [](){ return; });
], [lyx_std_call_once=yes], [lyx_std_call_once=no])
]])],[lyx_std_call_once=yes],[lyx_std_call_once=no])
CXXFLAGS=$save_CXXFLAGS
CPPFLAGS=$save_CPPFLAGS
AC_MSG_RESULT([$lyx_std_call_once])
@ -279,12 +275,11 @@ dnl Usage: LYX_LIB_STDCXX: set lyx_cv_lib_stdcxx to yes if the STL library is li
AC_DEFUN([LYX_LIB_STDCXX],
[AC_CACHE_CHECK([whether STL is libstdc++],
[lyx_cv_lib_stdcxx],
[AC_TRY_COMPILE([#include<vector>], [
[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include<vector>]], [[
#if ! defined(__GLIBCXX__) && ! defined(__GLIBCPP__)
this is not libstdc++
#endif
],
[lyx_cv_lib_stdcxx=yes], [lyx_cv_lib_stdcxx=no])])
]])],[lyx_cv_lib_stdcxx=yes],[lyx_cv_lib_stdcxx=no])])
])
@ -293,12 +288,11 @@ dnl if the STL library is GNU libstdc++ and the C++11 ABI is used.
AC_DEFUN([LYX_LIB_STDCXX_CXX11_ABI],
[AC_CACHE_CHECK([whether STL is libstdc++ using the C++11 ABI],
[lyx_cv_lib_stdcxx_cxx11_abi],
[AC_TRY_COMPILE([#include<vector>], [
[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include<vector>]], [[
#if ! defined(_GLIBCXX_USE_CXX11_ABI) || ! _GLIBCXX_USE_CXX11_ABI
this is not libstdc++ using the C++11 ABI
#endif
],
[lyx_cv_lib_stdcxx_cxx11_abi=yes], [lyx_cv_lib_stdcxx_cxx11_abi=no])])
]])],[lyx_cv_lib_stdcxx_cxx11_abi=yes],[lyx_cv_lib_stdcxx_cxx11_abi=no])])
])
@ -329,8 +323,8 @@ fi
### We might want to get or shut warnings.
AC_ARG_ENABLE(warnings,
AC_HELP_STRING([--enable-warnings],[tell the compiler to display more warnings]),,
[ if test $lyx_devel_version = yes -o $lyx_prerelease = yes && test $ac_cv_prog_gxx = yes ; then
AS_HELP_STRING([--enable-warnings],[tell the compiler to display more warnings]),,
[ if test $lyx_devel_version = yes -o $lyx_prerelease = yes && test $ac_cv_cxx_compiler_gnu = yes ; then
enable_warnings=yes;
else
enable_warnings=no;
@ -341,19 +335,19 @@ fi
### We might want to disable debug
AC_ARG_ENABLE(debug,
AC_HELP_STRING([--enable-debug],[enable debug information]),,
AS_HELP_STRING([--enable-debug],[enable debug information]),,
[AS_CASE([$build_type], [rel*], [enable_debug=no], [enable_debug=yes])]
)
AC_ARG_ENABLE(stdlib-debug,
AC_HELP_STRING([--enable-stdlib-debug],[enable debug mode in the standard library]),,
AS_HELP_STRING([--enable-stdlib-debug],[enable debug mode in the standard library]),,
[AS_CASE([$build_type], [dev*], [enable_stdlib_debug=yes],
[enable_stdlib_debug=no])]
)
### set up optimization
AC_ARG_ENABLE(optimization,
AC_HELP_STRING([--enable-optimization@<:@=ARG@:>@],[enable compiler optimisation]),,
AS_HELP_STRING([--enable-optimization@<:@=ARG@:>@],[enable compiler optimisation]),,
enable_optimization=yes;)
case $enable_optimization in
yes)
@ -367,7 +361,7 @@ case $enable_optimization in
esac
AC_ARG_ENABLE(assertions,
AC_HELP_STRING([--enable-assertions],[add runtime sanity checks in the program]),,
AS_HELP_STRING([--enable-assertions],[add runtime sanity checks in the program]),,
[AS_CASE([$build_type], [dev*|pre*], [enable_assertions=yes],
[enable_assertions=no])]
)
@ -419,8 +413,8 @@ if test x$GXX = xyes; then
AC_LANG_POP(C++)
fi
case $gxx_version in
2.*|3.*) AC_ERROR([gcc >= 4.6 is required]);;
4.0*|4.1*|4.2*|4.3*|4.4*|4.5*) AC_ERROR([gcc >= 4.6 is required]);;
2.*|3.*) AC_MSG_ERROR(gcc >= 4.6 is required);;
4.0*|4.1*|4.2*|4.3*|4.4*|4.5*) AC_MSG_ERROR(gcc >= 4.6 is required);;
esac
if test x$enable_stdlib_debug = xyes ; then
dnl FIXME: for clang/libc++, one should define _LIBCPP_DEBUG2=0
@ -455,7 +449,7 @@ dnl be used.
AC_DEFUN([LYX_USE_INCLUDED_BOOST],[
AC_MSG_CHECKING([whether to use included boost library])
AC_ARG_WITH(included-boost,
[AC_HELP_STRING([--without-included-boost], [do not use the boost lib supplied with LyX, try to find one in the system directories - compilation will abort if nothing suitable is found])],
[AS_HELP_STRING([--without-included-boost],[do not use the boost lib supplied with LyX, try to find one in the system directories - compilation will abort if nothing suitable is found])],
[lyx_cv_with_included_boost=$withval],
[lyx_cv_with_included_boost=yes])
AM_CONDITIONAL(USE_INCLUDED_BOOST, test x$lyx_cv_with_included_boost = xyes)
@ -520,7 +514,7 @@ dnl be used.
AC_DEFUN([LYX_USE_INCLUDED_ICONV],[
AC_MSG_CHECKING([whether to use included iconv library])
AC_ARG_WITH(included-iconv,
[AC_HELP_STRING([--with-included-iconv], [use the iconv lib supplied with LyX instead of the system one])],
[AS_HELP_STRING([--with-included-iconv],[use the iconv lib supplied with LyX instead of the system one])],
[lyx_cv_with_included_iconv=$withval],
[lyx_cv_with_included_iconv=no])
AM_CONDITIONAL(USE_INCLUDED_ICONV, test x$lyx_cv_with_included_iconv = xyes)
@ -586,7 +580,7 @@ dnl be used.
AC_DEFUN([LYX_USE_INCLUDED_ZLIB],[
AC_MSG_CHECKING([whether to use included zlib library])
AC_ARG_WITH(included-zlib,
[AC_HELP_STRING([--with-included-zlib], [use the zlib lib supplied with LyX instead of the system one])],
[AS_HELP_STRING([--with-included-zlib],[use the zlib lib supplied with LyX instead of the system one])],
[lyx_cv_with_included_zlib=$withval],
[lyx_cv_with_included_zlib=no])
AM_CONDITIONAL(USE_INCLUDED_ZLIB, test x$lyx_cv_with_included_zlib = xyes)
@ -617,17 +611,16 @@ dnl necessary APIs are available to print callstacks.
AC_DEFUN([LYX_CHECK_CALLSTACK_PRINTING],
[AC_CACHE_CHECK([whether printing callstack is possible],
[lyx_cv_callstack_printing],
[AC_TRY_COMPILE([
[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#include <execinfo.h>
#include <cxxabi.h>
], [
]], [[
void* array[200];
size_t size = backtrace(array, 200);
backtrace_symbols(array, size);
int status = 0;
abi::__cxa_demangle("abcd", 0, 0, &status);
],
[lyx_cv_callstack_printing=yes], [lyx_cv_callstack_printing=no])])
]])],[lyx_cv_callstack_printing=yes],[lyx_cv_callstack_printing=no])])
if test x"$lyx_cv_callstack_printing" = xyes; then
AC_DEFINE([LYX_CALLSTACK_PRINTING], 1,
[Define if callstack can be printed])
@ -639,7 +632,7 @@ dnl Usage: LYX_USE_INCLUDED_MYTHES : select if the included MyThes should
dnl be used.
AC_DEFUN([LYX_USE_INCLUDED_MYTHES],[
AC_ARG_WITH(included-mythes,
[AC_HELP_STRING([--with-included-mythes], [force to use the MyThes lib supplied with LyX])],
[AS_HELP_STRING([--with-included-mythes],[force to use the MyThes lib supplied with LyX])],
[use_included_mythes=$withval],
[use_included_mythes=no])
if test x$use_included_mythes != xyes ; then
@ -684,7 +677,7 @@ dnl [default-yes-value])
dnl Adds a --with-'dir-name' option (described by 'desc') and puts the
dnl resulting directory name in 'dir-var-name'.
AC_DEFUN([LYX_WITH_DIR],[
AC_ARG_WITH($1,[AC_HELP_STRING([--with-$1],[specify $2])])
AC_ARG_WITH($1,[AS_HELP_STRING([--with-$1],[specify $2])])
AC_MSG_CHECKING([for $2])
if test -z "$with_$3"; then
AC_CACHE_VAL(lyx_cv_$3, lyx_cv_$3=$4)
@ -703,7 +696,7 @@ AC_DEFUN([LYX_LOOP_DIR],[
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
for dir in `eval "echo $1"`; do
if test ! "$dir" = NONE; then
test ! -d "$dir" && AC_MSG_ERROR([\"$dir\" is not a directory])
test ! -d "$dir" && AC_MSG_ERROR(['$dir' is not a directory])
$2
fi
done
@ -717,7 +710,7 @@ AC_DEFUN([LYX_ADD_LIB_DIR],[
$1="${$1} -L$2"
if test "`(uname) 2>/dev/null`" = SunOS &&
uname -r | grep '^5' >/dev/null; then
if test $ac_cv_prog_gxx = yes ; then
if test $ac_cv_cxx_compiler_gnu = yes ; then
$1="${$1} -Wl[,]-R$2"
else
$1="${$1} -R$2"
@ -767,7 +760,7 @@ rm -f conftest*])
AC_DEFUN([LYX_USE_PACKAGING],
[AC_MSG_CHECKING([what packaging should be used])
AC_ARG_WITH(packaging,
[AC_HELP_STRING([--with-packaging=STR], [set packaging for installation among:
[AS_HELP_STRING([--with-packaging=STR],[set packaging for installation among:
posix, windows, macosx, haiku (default is autodetected)])],
[lyx_use_packaging="$withval"], [
case $host in
@ -840,13 +833,12 @@ AC_DEFUN([AC_FUNC_MKDIR],
[AC_CHECK_FUNCS([mkdir _mkdir])
AC_CACHE_CHECK([whether mkdir takes one argument],
[ac_cv_mkdir_takes_one_arg],
[AC_TRY_COMPILE([
[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#include <sys/stat.h>
#if HAVE_UNISTD_H
# include <unistd.h>
#endif
], [mkdir (".");],
[ac_cv_mkdir_takes_one_arg=yes], [ac_cv_mkdir_takes_one_arg=no])])
]], [[mkdir (".");]])],[ac_cv_mkdir_takes_one_arg=yes],[ac_cv_mkdir_takes_one_arg=no])])
if test x"$ac_cv_mkdir_takes_one_arg" = xyes; then
AC_DEFINE([MKDIR_TAKES_ONE_ARG], 1,
[Define if mkdir takes only one argument.])
@ -914,9 +906,7 @@ AC_DEFUN([LYX_CHECK_DEF],
save_CXXFLAGS=$CXXFLAGS
CXXFLAGS="$AM_CXXFLAGS $CXXFLAGS"
AC_LANG_PUSH(C++)
AC_TRY_COMPILE([#include <$2>], [$3],
lyx_have_def_name=yes,
lyx_have_def_name=no)
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <$2>]], [[$3]])],[lyx_have_def_name=yes],[lyx_have_def_name=no])
AC_LANG_POP(C++)
CXXFLAGS=$save_CXXFLAGS
CPPFLAGS=$save_CPPFLAGS

View File

@ -3,18 +3,15 @@ AC_DEFUN([QT_TRY_LINK],
[
SAVE_LIBS="$LIBS"
LIBS="$LIBS $1"
AC_TRY_LINK([
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
#include <qglobal.h>
#include <qstring.h>
],
[
]], [[
QString s("mangle_failure");
#if (QT_VERSION < 400)
break_me_(\\\);
#endif
],
qt_cv_libname=$1,
)
]])],[qt_cv_libname=$1],[])
LIBS="$SAVE_LIBS"
])
@ -25,7 +22,7 @@ AC_DEFUN([QT_CHECK_COMPILE],
AC_CACHE_VAL(qt_cv_libname,
[
AC_LANG_CPLUSPLUS
AC_LANG([C++])
SAVE_CXXFLAGS=$CXXFLAGS
CXXFLAGS="$CXXFLAGS $QT_INCLUDES $QT_LDFLAGS"
qt_corelibs="-lQtCore -lQtCore4"
@ -97,7 +94,7 @@ AC_DEFUN([QT_GET_VERSION],
[
AC_CACHE_CHECK([Qt version],lyx_cv_qtversion,
[
AC_LANG_CPLUSPLUS
AC_LANG([C++])
SAVE_CPPFLAGS=$CPPFLAGS
CPPFLAGS="$CPPFLAGS $QT_INCLUDES"
@ -124,13 +121,13 @@ AC_DEFUN([QT_DO_IT_ALL],
dnl this variable is precious
AC_ARG_VAR(QTDIR, [the place where the Qt files are, e.g. /usr/lib/qt4])
AC_ARG_WITH(qt-dir, [AC_HELP_STRING([--with-qt-dir], [where the root of Qt is installed])],
AC_ARG_WITH(qt-dir, [AS_HELP_STRING([--with-qt-dir],[where the root of Qt is installed])],
[ qt_cv_dir=`eval echo "$withval"/` ])
AC_ARG_WITH(qt-includes, [AC_HELP_STRING([--with-qt-includes], [where the Qt includes are])],
AC_ARG_WITH(qt-includes, [AS_HELP_STRING([--with-qt-includes],[where the Qt includes are])],
[ qt_cv_includes=`eval echo "$withval"` ])
AC_ARG_WITH(qt-libraries, [AC_HELP_STRING([--with-qt-libraries], [where the Qt library is installed])],
AC_ARG_WITH(qt-libraries, [AS_HELP_STRING([--with-qt-libraries],[where the Qt library is installed])],
[ qt_cv_libraries=`eval echo "$withval"` ])
dnl pay attention to $QTDIR unless overridden

View File

@ -3,7 +3,7 @@
AC_DEFUN([CHECK_WITH_ASPELL],
[
lyx_use_aspell=true
AC_ARG_WITH(aspell, AC_HELP_STRING([--without-aspell],[do not check for ASpell library]))
AC_ARG_WITH(aspell, AS_HELP_STRING([--without-aspell],[do not check for ASpell library]))
test "$with_aspell" = "no" && lyx_use_aspell=false
if $lyx_use_aspell ; then
@ -29,19 +29,16 @@ AC_DEFUN([LYX_HAVE_ENCHANT2],
save_CXXFLAGS=$CXXFLAGS
CXXFLAGS="$ENCHANT_CFLAGS $AM_CXXFLAGS $CXXFLAGS"
AC_TRY_COMPILE([#include <enchant++.h>],
[enchant::Broker broker;],
[AC_MSG_RESULT(yes)
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <enchant++.h>]], [[enchant::Broker broker;]])],[AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_ENCHANT2, 1, [Define to 1 if enchant 2.x is detected])
],
[AC_MSG_RESULT(no)])
],[AC_MSG_RESULT(no)])
CXXFLAGS=$save_CXXFLAGS
])
AC_DEFUN([CHECK_WITH_ENCHANT],
[
lyx_use_enchant=true
AC_ARG_WITH(enchant, AC_HELP_STRING([--without-enchant],[do not check for Enchant library]))
AC_ARG_WITH(enchant, AS_HELP_STRING([--without-enchant],[do not check for Enchant library]))
test "$with_enchant" = "no" && lyx_use_enchant=false
if $lyx_use_enchant; then
@ -67,14 +64,11 @@ AC_DEFUN([LYX_HAVE_HUNSPELL_CXXABI],
CXXFLAGS="$ENCHANT_CFLAGS $AM_CXXFLAGS $CXXFLAGS"
# in the C++ ABI, stem() returns a vector, in the C ABI, it returns an int
AC_TRY_COMPILE([#include <hunspell/hunspell.hxx>],
[Hunspell sp("foo", "bar");
int i = sp.stem("test").size();],
[AC_MSG_RESULT(yes)
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <hunspell/hunspell.hxx>]], [[Hunspell sp("foo", "bar");
int i = sp.stem("test").size();]])],[AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_HUNSPELL_CXXABI, 1, [Define to 1 if hunspell C++ (rather than C) ABI is detected])
have_hunspell_cxx_abi=yes
],
[AC_MSG_RESULT(no)])
],[AC_MSG_RESULT(no)])
CXXFLAGS=$save_CXXFLAGS
])
@ -82,7 +76,7 @@ AC_DEFUN([LYX_HAVE_HUNSPELL_CXXABI],
AC_DEFUN([CHECK_WITH_HUNSPELL],
[
lyx_use_hunspell=true
AC_ARG_WITH(hunspell, AC_HELP_STRING([--without-hunspell],[do not check for Hunspell library]))
AC_ARG_WITH(hunspell, AS_HELP_STRING([--without-hunspell],[do not check for Hunspell library]))
test "$with_hunspell" = "no" && lyx_use_hunspell=false
if $lyx_use_hunspell ; then
@ -113,7 +107,7 @@ dnl be used.
AC_DEFUN([LYX_USE_INCLUDED_HUNSPELL],[
AC_MSG_CHECKING([whether to use included hunspell library])
AC_ARG_WITH(included-hunspell,
[AC_HELP_STRING([--with-included-hunspell], [use the hunspell lib supplied with LyX instead of the system one])],
[AS_HELP_STRING([--with-included-hunspell],[use the hunspell lib supplied with LyX instead of the system one])],
[lyx_cv_with_included_hunspell=$withval],
[lyx_cv_with_included_hunspell=no])
AM_CONDITIONAL(USE_INCLUDED_HUNSPELL, test x$lyx_cv_with_included_hunspell = xyes)

View File

@ -1,10 +1,10 @@
dnl Process with autoconf to generate configure script -*- sh -*-
AC_INIT(LyX,2.3.7dev,[lyx-devel@lists.lyx.org],[lyx])
AC_INIT([LyX],[2.3.7dev],[lyx-devel@lists.lyx.org],[lyx])
AC_PRESERVE_HELP_ORDER
# Use ISO format only. The frontend needs to parse this
AC_SUBST(LYX_DATE, ["2020-11-30"])
AC_PREREQ(2.65)
AC_PREREQ([2.65])
AC_CONFIG_SRCDIR(src/main.cpp)
AC_CONFIG_HEADERS([config.h])
@ -31,14 +31,13 @@ AM_SILENT_RULES([yes])
# file names only up to 99 characters. tar-ustar selects the ustar format defined
# by POSIX 1003.1-1988. This format is believed to be old enough to be portable.
save_PACKAGE=$PACKAGE
AM_INIT_AUTOMAKE([foreign dist-bzip2 no-define 1.8 tar-ustar subdir-objects])
AM_INIT_AUTOMAKE([foreign dist-bzip2 no-define 1.14 tar-ustar subdir-objects])
PACKAGE=$save_PACKAGE
# Allow to build some parts of the code as one big chunk
m4_define([ALLPARTS],[boost,client,insets,mathed,core,tex2lyx,frontend_qt])
AC_ARG_ENABLE(monolithic-build,
AC_HELP_STRING([--enable-monolithic-build@<:@=LIST@:>@],
[Use monolithic build for modules in LIST (default: ALLPARTS)]),
AS_HELP_STRING([--enable-monolithic-build@<:@=LIST@:>@],[Use monolithic build for modules in LIST (default: ALLPARTS)]),
[test "$enable_monolithic_build" = yes && enable_monolithic_build="ALLPARTS"
test "$enable_monolithic_build" = no && enable_monolithic_build=
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=" ,"
@ -132,9 +131,8 @@ AC_CHECK_SIZEOF(wchar_t)
# Taken from gettext, needed for libiconv
AC_CACHE_CHECK([for wchar_t], [gt_cv_c_wchar_t],
[AC_TRY_COMPILE([#include <stddef.h>
wchar_t foo = (wchar_t)'\0';], ,
[gt_cv_c_wchar_t=yes], [gt_cv_c_wchar_t=no])])
[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <stddef.h>
wchar_t foo = (wchar_t)'\0';]], [[]])],[gt_cv_c_wchar_t=yes],[gt_cv_c_wchar_t=no])])
if test $gt_cv_c_wchar_t = yes; then
AC_DEFINE([HAVE_WCHAR_T], [1], [Define if you have the 'wchar_t' type.])
HAVE_WCHAR_T=1
@ -240,7 +238,7 @@ esac
if test "x$lyx_win_res" = "xtrue"; then
AC_CHECK_TOOL(RC, windres,)
if test -z "$RC"; then
AC_ERROR([Could not find a resource compiler])
AC_MSG_ERROR(Could not find a resource compiler)
fi
fi
AM_CONDITIONAL(LYX_WIN_RESOURCE, $lyx_win_res)