1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-03 06:04:53 +00:00

- Fix build with Tcl 8.6

Reported by:	miwi (Tcl/Tk 86 exp-run latecomers)
Approved by:	portmgr
This commit is contained in:
Pietro Cerutti 2013-05-22 08:03:52 +00:00
parent 06b034d04d
commit 153dd8a22f
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=318746
4 changed files with 43 additions and 1 deletions

View File

@ -20,7 +20,6 @@ LICENSE= GPLv2
WRKSRC= ${WRKDIR}/${PORTNAME}
USE_XORG= x11 xinerama
USE_TCL_BUILD= yes
USE_TCL= yes
USE_GMAKE= yes
MAKE_ARGS= PREFIX="${PREFIX}" \

View File

@ -0,0 +1,12 @@
--- includes.h.orig 2013-05-22 09:36:16.000000000 +0200
+++ includes.h 2013-05-22 09:42:02.000000000 +0200
@@ -29,6 +29,9 @@
#include <locale.h>
#include <tcl.h>
+#if (TCL_MAJOR_VERSION < 8) || (TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION < 6)
+#define Tcl_GetErrorLine(interp) (interp->errorLine)
+#endif
#include "defines.h"
#include "guidefs.h"

View File

@ -0,0 +1,20 @@
--- shell.c.orig 2013-05-22 09:35:54.000000000 +0200
+++ shell.c 2013-05-22 09:44:04.000000000 +0200
@@ -992,7 +992,7 @@
Tcl_SetVar(interpreter,"SCRIPTPATH",scriptPath,TCL_LEAVE_ERR_MSG);
if(Tcl_EvalFile(interpreter,scriptPath)!=TCL_OK)
{
- SetError("%s:%d:%s",scriptPath,interpreter->errorLine,Tcl_GetStringResult(interpreter));
+ SetError("%s:%d:%s",scriptPath,Tcl_GetErrorLine(interpreter),Tcl_GetStringResult(interpreter));
fail=true;
}
}
@@ -1066,7 +1066,7 @@
}
else
{
- SetError("Failed to Tcl_Init(): %s",tclInterpreter->result);
+ SetError("Failed to Tcl_Init(): %s",Tcl_GetStringResult(tclInterpreter));
}
UnInitChannels(tclInterpreter);
}

View File

@ -0,0 +1,11 @@
--- shellcmd.c.orig 2013-05-22 09:45:47.000000000 +0200
+++ shellcmd.c 2013-05-22 09:46:25.000000000 +0200
@@ -6354,7 +6354,7 @@
{
if(tclResult!=TCL_OK)
{
- sprintf(tempString,"Error in line %d: ",localInterpreter->errorLine);
+ sprintf(tempString,"Error in line %d: ",Tcl_GetErrorLine(localInterpreter));
EditorAuxInsert(buffer,(UINT8 *)tempString,(UINT32)strlen(tempString));
}
EditorAuxInsert(buffer,(UINT8 *)stringResult,(UINT32)strlen(stringResult));