summaryrefslogtreecommitdiffstats
path: root/src/configure.in
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2014-10-11 14:47:26 +0200
committerBram Moolenaar <Bram@vim.org>2014-10-11 14:47:26 +0200
commitcbc246a331dc8dea49f6ad443be3d10ec68ef2c2 (patch)
tree28143a4a295066093221ed840dde7c2ada513181 /src/configure.in
parent2a9853925bee1b85247cd5f4ccf98fec1871d1f7 (diff)
updated for version 7.4.475v7.4.475
Problem: Can't compile on a system where Xutf8SetWMProperties() is not in the X11 library. Issue 265. Solution: Add a configure check.
Diffstat (limited to 'src/configure.in')
-rw-r--r--src/configure.in29
1 files changed, 16 insertions, 13 deletions
diff --git a/src/configure.in b/src/configure.in
index 62785e171c..ff1f4824b4 100644
--- a/src/configure.in
+++ b/src/configure.in
@@ -3730,21 +3730,24 @@ fi
dnl Check for multibyte locale functions
dnl Find out if _Xsetlocale() is supported by libX11.
dnl Check if X_LOCALE should be defined.
-
-if test "$enable_multibyte" = "yes"; then
+if test "x$with_x" = "xyes"; then
cflags_save=$CFLAGS
- ldflags_save=$LDFLAGS
- if test "x$x_includes" != "xNONE" ; then
- CFLAGS="$CFLAGS -I$x_includes"
- LDFLAGS="$X_LIBS $LDFLAGS -lX11"
- AC_MSG_CHECKING(whether X_LOCALE needed)
- AC_TRY_COMPILE([#include <X11/Xlocale.h>],,
- AC_TRY_LINK_FUNC([_Xsetlocale], [AC_MSG_RESULT(yes)
- AC_DEFINE(X_LOCALE)], AC_MSG_RESULT(no)),
- AC_MSG_RESULT(no))
- fi
+ libs_save=$LIBS
+ LIBS="$LIBS $X_LIBS $GUI_LIB_LOC $GUI_X_LIBS $X_PRE_LIBS $X_LIB $X_EXTRA_LIBS"
+ CFLAGS="$CFLAGS $X_CFLAGS"
+
+ AC_MSG_CHECKING(whether X_LOCALE needed)
+ AC_TRY_COMPILE([#include <X11/Xlocale.h>],,
+ AC_TRY_LINK_FUNC([_Xsetlocale], [AC_MSG_RESULT(yes)
+ AC_DEFINE(X_LOCALE)], AC_MSG_RESULT(no)),
+ AC_MSG_RESULT(no))
+
+ AC_MSG_CHECKING(whether Xutf8SetWMProperties() can be used)
+ AC_TRY_LINK_FUNC([Xutf8SetWMProperties], [AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_XUTF8SETWMPROPERTIES)], AC_MSG_RESULT(no))
+
CFLAGS=$cflags_save
- LDFLAGS=$ldflags_save
+ LIBS=$libs_save
fi
dnl Link with xpg4, it is said to make Korean locale working