changeset 27201:7d66380a6b86 v8.2.4129

patch 8.2.4129: building with +sound but without +eval fails Commit: https://github.com/vim/vim/commit/1247126956c2ba666048b2bf99630eef7495e98e Author: Bram Moolenaar <Bram@vim.org> Date: Tue Jan 18 11:11:25 2022 +0000 patch 8.2.4129: building with +sound but without +eval fails Problem: Building with +sound but without +eval fails. (Dominique Pell?) Solution: Disable canberra in tiny and small build. (closes https://github.com/vim/vim/issues/9548)
author Bram Moolenaar <Bram@vim.org>
date Tue, 18 Jan 2022 12:45:03 +0100
parents 8e65bf8592f2
children 1157a690bc1d
files src/auto/configure src/configure.ac src/version.c
diffstat 3 files changed, 45 insertions(+), 20 deletions(-) [+]
line wrap: on
line diff
--- a/src/auto/configure
+++ b/src/auto/configure
@@ -5256,6 +5256,12 @@ esac
 
 
 
+if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  has_eval=no
+else
+  has_eval=yes
+fi
+
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-compiledby argument" >&5
 $as_echo_n "checking --with-compiledby argument... " >&6; }
 
@@ -5333,7 +5339,7 @@ fi
 $as_echo "$enable_luainterp" >&6; }
 
 if test "$enable_luainterp" = "yes" -o "$enable_luainterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     as_fn_error $? "cannot use Lua with tiny or small features" "$LINENO" 5
   fi
 
@@ -6103,7 +6109,7 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_perlinterp" >&5
 $as_echo "$enable_perlinterp" >&6; }
 if test "$enable_perlinterp" = "yes" -o "$enable_perlinterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     as_fn_error $? "cannot use Perl with tiny or small features" "$LINENO" 5
   fi
 
@@ -6308,7 +6314,7 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_pythoninterp" >&5
 $as_echo "$enable_pythoninterp" >&6; }
 if test "$enable_pythoninterp" = "yes" -o "$enable_pythoninterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     as_fn_error $? "cannot use Python with tiny or small features" "$LINENO" 5
   fi
 
@@ -6659,7 +6665,7 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_python3interp" >&5
 $as_echo "$enable_python3interp" >&6; }
 if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     as_fn_error $? "cannot use Python with tiny or small features" "$LINENO" 5
   fi
 
@@ -7587,7 +7593,7 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_rubyinterp" >&5
 $as_echo "$enable_rubyinterp" >&6; }
 if test "$enable_rubyinterp" = "yes" -o "$enable_rubyinterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     as_fn_error $? "cannot use Ruby with tiny or small features" "$LINENO" 5
   fi
 
@@ -7765,7 +7771,7 @@ else
 fi
 
 if test "$enable_netbeans" = "yes"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot use NetBeans with tiny or small features" >&5
 $as_echo "cannot use NetBeans with tiny or small features" >&6; }
     enable_netbeans="no"
@@ -7788,7 +7794,7 @@ else
 fi
 
 if test "$enable_channel" = "yes"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot use channels with tiny or small features" >&5
 $as_echo "cannot use channels with tiny or small features" >&6; }
     enable_channel="no"
@@ -8092,7 +8098,7 @@ else
 fi
 
 if test "$enable_terminal" = "yes" || test "$enable_terminal" = "auto" -a "x$features" = "xhuge" ; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot use terminal emulator with tiny or small features" >&5
 $as_echo "cannot use terminal emulator with tiny or small features" >&6; }
     enable_terminal="no"
@@ -13051,8 +13057,14 @@ if test "$enable_canberra" = "maybe"; th
     enable_canberra="no"
   fi
 else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_canberra" >&5
+  if test "$enable_canberra" = "yes" -a "$has_eval" = "no"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot use sound with tiny or small features" >&5
+$as_echo "cannot use sound with tiny or small features" >&6; }
+    enable_canberra="no"
+  else
+    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_canberra" >&5
 $as_echo "$enable_canberra" >&6; }
+  fi
 fi
 if test "$enable_canberra" = "yes"; then
   if test "x$PKG_CONFIG" != "xno"; then
@@ -13067,7 +13079,7 @@ if test "$enable_canberra" = "yes"; then
 $as_echo_n "checking for libcanberra... " >&6; }
   ac_save_CFLAGS="$CFLAGS"
   ac_save_LIBS="$LIBS"
-  if `echo "$CFLAGS" | grep -v "$canberra_cflags" >/dev/null`; then
+  if `echo "$CFLAGS" | grep -v "$canberra_cflags" 2>/dev/null`; then
     CFLAGS="$CFLAGS $canberra_cflags"
   fi
   LIBS="$LIBS $canberra_lib"
--- a/src/configure.ac
+++ b/src/configure.ac
@@ -540,6 +540,12 @@ esac
 AC_SUBST(dovimdiff)
 AC_SUBST(dogvimdiff)
 
+if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  has_eval=no
+else
+  has_eval=yes
+fi
+
 AC_MSG_CHECKING(--with-compiledby argument)
 AC_ARG_WITH(compiledby, [  --with-compiledby=NAME  name to show in :version message],
 	compiledby="$withval"; AC_MSG_RESULT($withval),
@@ -585,7 +591,7 @@ AC_ARG_ENABLE(luainterp,
 AC_MSG_RESULT($enable_luainterp)
 
 if test "$enable_luainterp" = "yes" -o "$enable_luainterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_ERROR([cannot use Lua with tiny or small features])
   fi
 
@@ -1072,7 +1078,7 @@ AC_ARG_ENABLE(perlinterp,
 	[enable_perlinterp="no"])
 AC_MSG_RESULT($enable_perlinterp)
 if test "$enable_perlinterp" = "yes" -o "$enable_perlinterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_ERROR([cannot use Perl with tiny or small features])
   fi
   AC_SUBST(vi_cv_path_perl)
@@ -1221,7 +1227,7 @@ AC_ARG_ENABLE(pythoninterp,
 	[enable_pythoninterp="no"])
 AC_MSG_RESULT($enable_pythoninterp)
 if test "$enable_pythoninterp" = "yes" -o "$enable_pythoninterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_ERROR([cannot use Python with tiny or small features])
   fi
 
@@ -1456,7 +1462,7 @@ AC_ARG_ENABLE(python3interp,
 	[enable_python3interp="no"])
 AC_MSG_RESULT($enable_python3interp)
 if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_ERROR([cannot use Python with tiny or small features])
   fi
 
@@ -1969,7 +1975,7 @@ AC_ARG_ENABLE(rubyinterp,
 	[enable_rubyinterp="no"])
 AC_MSG_RESULT($enable_rubyinterp)
 if test "$enable_rubyinterp" = "yes" -o "$enable_rubyinterp" = "dynamic"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_ERROR([cannot use Ruby with tiny or small features])
   fi
 
@@ -2082,7 +2088,7 @@ AC_ARG_ENABLE(netbeans,
 	[  --disable-netbeans      Disable NetBeans integration support.],
 	, [enable_netbeans="yes"])
 if test "$enable_netbeans" = "yes"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_RESULT([cannot use NetBeans with tiny or small features])
     enable_netbeans="no"
   else
@@ -2097,7 +2103,7 @@ AC_ARG_ENABLE(channel,
 	[  --disable-channel       Disable process communication support.],
 	, [enable_channel="yes"])
 if test "$enable_channel" = "yes"; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_RESULT([cannot use channels with tiny or small features])
     enable_channel="no"
   else
@@ -2205,7 +2211,7 @@ AC_ARG_ENABLE(terminal,
 	[  --enable-terminal       Enable terminal emulation support.],
 	, [enable_terminal="auto"])
 if test "$enable_terminal" = "yes" || test "$enable_terminal" = "auto" -a "x$features" = "xhuge" ; then
-  if test "x$features" = "xtiny" -o "x$features" = "xsmall"; then
+  if test "$has_eval" = "no"; then
     AC_MSG_RESULT([cannot use terminal emulator with tiny or small features])
     enable_terminal="no"
   else
@@ -3794,7 +3800,12 @@ if test "$enable_canberra" = "maybe"; th
     enable_canberra="no"
   fi
 else
-  AC_MSG_RESULT($enable_canberra)
+  if test "$enable_canberra" = "yes" -a "$has_eval" = "no"; then
+    AC_MSG_RESULT([cannot use sound with tiny or small features])
+    enable_canberra="no"
+  else
+    AC_MSG_RESULT($enable_canberra)
+  fi
 fi
 if test "$enable_canberra" = "yes"; then
   if test "x$PKG_CONFIG" != "xno"; then
@@ -3808,7 +3819,7 @@ if test "$enable_canberra" = "yes"; then
   AC_MSG_CHECKING(for libcanberra)
   ac_save_CFLAGS="$CFLAGS"
   ac_save_LIBS="$LIBS"
-  if `echo "$CFLAGS" | grep -v "$canberra_cflags" >/dev/null`; then
+  if `echo "$CFLAGS" | grep -v "$canberra_cflags" 2>/dev/null`; then
     CFLAGS="$CFLAGS $canberra_cflags"
   fi
   LIBS="$LIBS $canberra_lib"
--- a/src/version.c
+++ b/src/version.c
@@ -751,6 +751,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    4129,
+/**/
     4128,
 /**/
     4127,