mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-22 20:36:50 +03:00
da583e5739
We have several AC_TRY_RUN's in the configure/m4 stuff, which obviously breaks crosscompiling. This changeset contain fixies for S-Lang library. First try to search library via 'pkg-config slang' and then try to go in old search way. Macro AC_TRY_RUN() now replaced by AC_RUN_IFELSE() Also, next changes was made: * Removed AC_TRY_RUN() from gmodule checking code. * More accuracy in grepping of SLANG_VERSION defined constant * avoid autoconf error 'suspicious presence of an AC_DEFINE in the second argument, where no actions should be taken' Signed-off-by: Slava Zanko <slavazanko@gmail.com>
26 lines
897 B
Plaintext
26 lines
897 B
Plaintext
dnl
|
|
dnl Check whether the g_module_* family of functions works
|
|
dnl on this system. We need to know that at the compile time to
|
|
dnl decide whether to link with X11.
|
|
dnl
|
|
AC_DEFUN([AC_G_MODULE_SUPPORTED], [
|
|
AC_CACHE_CHECK([if gmodule functionality is supported],
|
|
[mc_cv_g_module_supported],
|
|
[
|
|
mc_cv_g_module_supported=no;
|
|
PKG_CHECK_MODULES(GMODULE, [gmodule-2.0 >= 2.8], [found_gmodule=yes], [:])
|
|
if test x"$found_gmodule" = "xyes"; then
|
|
mc_cv_g_module_supported=yes
|
|
fi
|
|
])
|
|
|
|
if test x"$mc_cv_g_module_supported" = "xyes"; then
|
|
if test x`$PKG_CONFIG --variable=gmodule_supported gmodule-2.0` = xtrue; then
|
|
GLIB_LIBS="$GMODULE_LIBS $GLIB_LIBS"
|
|
CFLAGS="$GMODULE_CFLAGS $CFLAGS"
|
|
AC_DEFINE([HAVE_GMODULE], [1],
|
|
[Defined if gmodule functionality is supported])
|
|
fi
|
|
fi
|
|
])
|