To:
[email protected]
Subject: patch 5.5a.11
Fcc: outbox
From: Bram Moolenaar <
[email protected]>
------------
Patch 5.5a.11
Problem: Tcl: Configure always uses tclsh8.0.
Also: Loading a library doesn't work.
Solution: Add "--with-tclsh" configure argument to allow specifying another
name for the tcl shell.
Call Tcl_Init() in tclinit() to make loading libraries work.
(Johannes Zellner)
Files: src/configure.in, src/configure, src/if_tcl.c
*** ../vim-5.5a.10/src/configure.in Mon Aug 30 10:40:50 1999
--- src/configure.in Sun Sep 5 20:12:00 1999
***************
*** 272,280 ****
AC_MSG_RESULT($enable_tclinterp)
if test "$enable_tclinterp" = "yes"; then
! AC_SUBST(vi_cv_path_tcl)
dnl on FreeBSD tclsh is a silly script. tclsh8.0 is what we need.
! AC_PATH_PROG(vi_cv_path_tcl, tclsh8.0)
if test "X$vi_cv_path_tcl" = "X"; then
AC_PATH_PROG(vi_cv_path_tcl, tclsh)
fi
--- 272,287 ----
AC_MSG_RESULT($enable_tclinterp)
if test "$enable_tclinterp" = "yes"; then
!
dnl on FreeBSD tclsh is a silly script. tclsh8.0 is what we need.
! AC_MSG_CHECKING(--with-tclsh argument)
! AC_ARG_WITH(tclsh, [ --with-tclsh=PATH which tclsh to use (default: tclsh8.0)],
! tclsh_name="$withval",
! tclsh_name="tclsh8.0")
! AC_MSG_RESULT($tclsh_name)
! AC_PATH_PROG(vi_cv_path_tcl, $tclsh_name)
! AC_SUBST(vi_cv_path_tcl)
!
if test "X$vi_cv_path_tcl" = "X"; then
AC_PATH_PROG(vi_cv_path_tcl, tclsh)
fi
*** ../vim-5.5a.10/src/configure Mon Aug 30 10:40:50 1999
--- src/configure Sun Sep 5 20:12:03 1999
***************
*** 24,29 ****
--- 24,31 ----
ac_help="$ac_help
--enable-tclinterp Include Tcl interpreter."
ac_help="$ac_help
+ --with-tclsh=PATH which tclsh to use (default: tclsh8.0)"
+ ac_help="$ac_help
--enable-cscope Include cscope interface."
ac_help="$ac_help
--enable-multibyte Include multibyte editing support."
***************
*** 1415,1425 ****
echo "$ac_t""$enable_tclinterp" 1>&6
if test "$enable_tclinterp" = "yes"; then
!
! # Extract the first word of "tclsh8.0", so it can be a program name with args.
! set dummy tclsh8.0; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
! echo "configure:1423: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_vi_cv_path_tcl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
--- 1417,1438 ----
echo "$ac_t""$enable_tclinterp" 1>&6
if test "$enable_tclinterp" = "yes"; then
!
! echo $ac_n "checking --with-tclsh argument""... $ac_c" 1>&6
! echo "configure:1423: checking --with-tclsh argument" >&5
! # Check whether --with-tclsh or --without-tclsh was given.
! if test "${with_tclsh+set}" = set; then
! withval="$with_tclsh"
! tclsh_name="$withval"
! else
! tclsh_name="tclsh8.0"
! fi
!
! echo "$ac_t""$tclsh_name" 1>&6
! # Extract the first word of "$tclsh_name", so it can be a program name with args.
! set dummy $tclsh_name; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
! echo "configure:1436: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_vi_cv_path_tcl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
***************
*** 1451,1461 ****
echo "$ac_t""no" 1>&6
fi
if test "X$vi_cv_path_tcl" = "X"; then
# Extract the first word of "tclsh", so it can be a program name with args.
set dummy tclsh; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
! echo "configure:1459: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_vi_cv_path_tcl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
--- 1464,1476 ----
echo "$ac_t""no" 1>&6
fi
+
+
if test "X$vi_cv_path_tcl" = "X"; then
# Extract the first word of "tclsh", so it can be a program name with args.
set dummy tclsh; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
! echo "configure:1474: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_vi_cv_path_tcl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
*** ../vim-5.5a.10/src/if_tcl.c Mon Aug 30 10:40:55 1999
--- src/if_tcl.c Sun Sep 5 20:17:21 1999
***************
*** 1542,1547 ****
--- 1542,1549 ----
Tcl_Channel ch1, ch2;
tcl.interp = Tcl_CreateInterp();
+ if (Tcl_Init(tcl.interp) == TCL_ERROR)
+ return;
tcl.do_exit = 0;
#if 0
/* VIM sure is interactive */
*** ../vim-5.5a.10/src/version.c Sun Sep 5 20:06:44 1999
--- src/version.c Sun Sep 5 20:06:12 1999
***************
*** 420,420 ****
--- 420,421 ----
{ /* Add new patch number below this line */
+ 11,
--
It is illegal for anyone to try and stop a child from playfully jumping over
puddles of water.
[real standing law in California, United States of America]
--/-/---- Bram Moolenaar ----
[email protected] ----
[email protected] ---\-\--
\ \ www.vim.org/iccf www.moolenaar.net www.vim.org / /