jkunstle / rpms / vim

Forked from rpms/vim 3 years ago
Clone

Blame SOURCES/7.4.094

dcaee6
To: vim_dev@googlegroups.com
dcaee6
Subject: Patch 7.4.094
dcaee6
Fcc: outbox
dcaee6
From: Bram Moolenaar <Bram@moolenaar.net>
dcaee6
Mime-Version: 1.0
dcaee6
Content-Type: text/plain; charset=UTF-8
dcaee6
Content-Transfer-Encoding: 8bit
dcaee6
------------
dcaee6
dcaee6
Patch 7.4.094
dcaee6
Problem:    Configure may not find that -lint is needed for gettext().
dcaee6
Solution:   Check for gettext() with empty $LIBS.  (Thomas De Schampheleire)
dcaee6
Files:	    src/configure.in, src/auto/configure
dcaee6
dcaee6
dcaee6
*** ../vim-7.4.093/src/configure.in	2013-11-17 20:17:05.000000000 +0100
dcaee6
--- src/configure.in	2013-11-17 20:23:49.000000000 +0100
dcaee6
***************
dcaee6
*** 3725,3730 ****
dcaee6
--- 3725,3733 ----
dcaee6
  fi
dcaee6
  
dcaee6
  dnl Check if gettext() is working and if it needs -lintl
dcaee6
+ dnl We take care to base this on an empty LIBS: on some systems libelf would be
dcaee6
+ dnl in LIBS and implicitly take along libintl. The final LIBS would then not
dcaee6
+ dnl contain libintl, and the link step would fail due to -Wl,--as-needed.
dcaee6
  AC_MSG_CHECKING(--disable-nls argument)
dcaee6
  AC_ARG_ENABLE(nls,
dcaee6
  	[  --disable-nls           Don't support NLS (gettext()).], ,
dcaee6
***************
dcaee6
*** 3743,3758 ****
dcaee6
    if test -f po/Makefile; then
dcaee6
      have_gettext="no"
dcaee6
      if test -n "$MSGFMT"; then
dcaee6
        AC_TRY_LINK(
dcaee6
  	[#include <libintl.h>],
dcaee6
  	[gettext("Test");],
dcaee6
! 	AC_MSG_RESULT([gettext() works]); have_gettext="yes",
dcaee6
! 	  olibs=$LIBS
dcaee6
! 	  LIBS="$LIBS -lintl"
dcaee6
  	  AC_TRY_LINK(
dcaee6
  	      [#include <libintl.h>],
dcaee6
  	      [gettext("Test");],
dcaee6
! 	      AC_MSG_RESULT([gettext() works with -lintl]); have_gettext="yes",
dcaee6
  	      AC_MSG_RESULT([gettext() doesn't work]);
dcaee6
  	      LIBS=$olibs))
dcaee6
      else
dcaee6
--- 3746,3763 ----
dcaee6
    if test -f po/Makefile; then
dcaee6
      have_gettext="no"
dcaee6
      if test -n "$MSGFMT"; then
dcaee6
+       olibs=$LIBS
dcaee6
+       LIBS=""
dcaee6
        AC_TRY_LINK(
dcaee6
  	[#include <libintl.h>],
dcaee6
  	[gettext("Test");],
dcaee6
! 	AC_MSG_RESULT([gettext() works]); have_gettext="yes"; LIBS=$olibs,
dcaee6
! 	  LIBS="-lintl"
dcaee6
  	  AC_TRY_LINK(
dcaee6
  	      [#include <libintl.h>],
dcaee6
  	      [gettext("Test");],
dcaee6
! 	      AC_MSG_RESULT([gettext() works with -lintl]); have_gettext="yes";
dcaee6
! 	      LIBS="$olibs -lintl",
dcaee6
  	      AC_MSG_RESULT([gettext() doesn't work]);
dcaee6
  	      LIBS=$olibs))
dcaee6
      else
dcaee6
*** ../vim-7.4.093/src/auto/configure	2013-11-17 20:17:05.000000000 +0100
dcaee6
--- src/auto/configure	2013-11-17 20:25:13.000000000 +0100
dcaee6
***************
dcaee6
*** 12690,12695 ****
dcaee6
--- 12690,12697 ----
dcaee6
    if test -f po/Makefile; then
dcaee6
      have_gettext="no"
dcaee6
      if test -n "$MSGFMT"; then
dcaee6
+       olibs=$LIBS
dcaee6
+       LIBS=""
dcaee6
        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
dcaee6
  /* end confdefs.h.  */
dcaee6
  #include <libintl.h>
dcaee6
***************
dcaee6
*** 12703,12712 ****
dcaee6
  _ACEOF
dcaee6
  if ac_fn_c_try_link "$LINENO"; then :
dcaee6
    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() works" >&5
dcaee6
! $as_echo "gettext() works" >&6; }; have_gettext="yes"
dcaee6
  else
dcaee6
!   olibs=$LIBS
dcaee6
! 	  LIBS="$LIBS -lintl"
dcaee6
  	  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
dcaee6
  /* end confdefs.h.  */
dcaee6
  #include <libintl.h>
dcaee6
--- 12705,12713 ----
dcaee6
  _ACEOF
dcaee6
  if ac_fn_c_try_link "$LINENO"; then :
dcaee6
    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() works" >&5
dcaee6
! $as_echo "gettext() works" >&6; }; have_gettext="yes"; LIBS=$olibs
dcaee6
  else
dcaee6
!   LIBS="-lintl"
dcaee6
  	  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
dcaee6
  /* end confdefs.h.  */
dcaee6
  #include <libintl.h>
dcaee6
***************
dcaee6
*** 12720,12726 ****
dcaee6
  _ACEOF
dcaee6
  if ac_fn_c_try_link "$LINENO"; then :
dcaee6
    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() works with -lintl" >&5
dcaee6
! $as_echo "gettext() works with -lintl" >&6; }; have_gettext="yes"
dcaee6
  else
dcaee6
    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() doesn't work" >&5
dcaee6
  $as_echo "gettext() doesn't work" >&6; };
dcaee6
--- 12721,12728 ----
dcaee6
  _ACEOF
dcaee6
  if ac_fn_c_try_link "$LINENO"; then :
dcaee6
    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() works with -lintl" >&5
dcaee6
! $as_echo "gettext() works with -lintl" >&6; }; have_gettext="yes";
dcaee6
! 	      LIBS="$olibs -lintl"
dcaee6
  else
dcaee6
    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() doesn't work" >&5
dcaee6
  $as_echo "gettext() doesn't work" >&6; };
dcaee6
*** ../vim-7.4.093/src/version.c	2013-11-17 20:17:05.000000000 +0100
dcaee6
--- src/version.c	2013-11-17 20:27:43.000000000 +0100
dcaee6
***************
dcaee6
*** 740,741 ****
dcaee6
--- 740,743 ----
dcaee6
  {   /* Add new patch number below this line */
dcaee6
+ /**/
dcaee6
+     94,
dcaee6
  /**/
dcaee6
dcaee6
-- 
dcaee6
BLACK KNIGHT: The Black Knight always triumphs. Have at you!
dcaee6
   ARTHUR takes his last leg off.  The BLACK KNIGHT's body lands upright.
dcaee6
BLACK KNIGHT: All right, we'll call it a draw.
dcaee6
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
dcaee6
dcaee6
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
dcaee6
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
dcaee6
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
dcaee6
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///