aboutsummaryrefslogtreecommitdiffstats
path: root/lang/tclX
diff options
context:
space:
mode:
authormi <mi@FreeBSD.org>2009-11-27 15:14:43 +0800
committermi <mi@FreeBSD.org>2009-11-27 15:14:43 +0800
commit429d87c52ef68114435b052982353b89cf04e258 (patch)
tree1a7d3d354eddfea474ec2e50461df8240ed17c10 /lang/tclX
parentabb6ce8d247685667626d7828b14d914dd979d5f (diff)
downloadfreebsd-ports-gnome-429d87c52ef68114435b052982353b89cf04e258.tar.gz
freebsd-ports-gnome-429d87c52ef68114435b052982353b89cf04e258.tar.zst
freebsd-ports-gnome-429d87c52ef68114435b052982353b89cf04e258.zip
Make TclX compilable against Tcl-8.6. Doing so is still a bad idea,
because some things (especially -- profiling) break at run time.
Diffstat (limited to 'lang/tclX')
-rw-r--r--lang/tclX/files/patch-errorLine73
1 files changed, 73 insertions, 0 deletions
diff --git a/lang/tclX/files/patch-errorLine b/lang/tclX/files/patch-errorLine
new file mode 100644
index 000000000000..f30c85e7a990
--- /dev/null
+++ b/lang/tclX/files/patch-errorLine
@@ -0,0 +1,73 @@
+Index: generic/tclExtdInt.h
+===================================================================
+RCS file: /cvsroot/tclx/tclx/generic/tclExtdInt.h,v
+retrieving revision 1.7
+retrieving revision 1.8
+diff -U2 -r1.7 -r1.8
+--- generic/tclExtdInt.h 12 Jul 2005 19:03:15 -0000 1.7
++++ generic/tclExtdInt.h 15 Dec 2008 20:00:27 -0000 1.8
+@@ -13,5 +13,5 @@
+ * implied warranty.
+ *-----------------------------------------------------------------------------
+- * $Id: tclExtdInt.h,v 1.7 2005/07/12 19:03:15 hobbs Exp $
++ * $Id: tclExtdInt.h,v 1.8 2008/12/15 20:00:27 andreas_kupries Exp $
+ *-----------------------------------------------------------------------------
+ */
+@@ -186,4 +186,13 @@
+
+ /*
++ * Handle hiding of errorLine in 8.6
++ */
++#if (TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION < 6)
++#define ERRORLINE(interp) ((interp)->errorLine)
++#else
++#define ERRORLINE(interp) (Tcl_GetErrorLine(interp))
++#endif
++
++/*
+ * Callback type for walking directories.
+ */
+Index: generic/tclXgeneral.c
+===================================================================
+RCS file: /cvsroot/tclx/tclx/generic/tclXgeneral.c,v
+retrieving revision 1.3
+retrieving revision 1.4
+diff -U2 -r1.3 -r1.4
+--- generic/tclXgeneral.c 4 Apr 2002 06:09:05 -0000 1.3
++++ generic/tclXgeneral.c 15 Dec 2008 20:00:27 -0000 1.4
+@@ -13,5 +13,5 @@
+ * implied warranty.
+ *-----------------------------------------------------------------------------
+- * $Id: tclXgeneral.c,v 1.3 2002/04/04 06:09:05 hobbs Exp $
++ * $Id: tclXgeneral.c,v 1.4 2008/12/15 20:00:27 andreas_kupries Exp $
+ *-----------------------------------------------------------------------------
+ */
+@@ -406,5 +406,5 @@
+
+ sprintf (buf, "\n (\"loop\" body line %d)",
+- interp->errorLine);
++ ERRORLINE(interp));
+ Tcl_AddErrorInfo (interp, buf);
+ }
+Index: generic/tclXlib.c
+===================================================================
+RCS file: /cvsroot/tclx/tclx/generic/tclXlib.c,v
+retrieving revision 1.4
+retrieving revision 1.5
+diff -U2 -r1.4 -r1.5
+--- generic/tclXlib.c 24 Mar 2005 05:04:38 -0000 1.4
++++ generic/tclXlib.c 15 Dec 2008 20:00:27 -0000 1.5
+@@ -13,5 +13,5 @@
+ * implied warranty.
+ *-----------------------------------------------------------------------------
+- * $Id: tclXlib.c,v 1.4 2005/03/24 05:04:38 hobbs Exp $
++ * $Id: tclXlib.c,v 1.5 2008/12/15 20:00:27 andreas_kupries Exp $
+ *-----------------------------------------------------------------------------
+ */
+@@ -240,5 +240,5 @@
+ buf = ckalloc (strlen (fileName) + 64);
+ sprintf (buf, "\n (file \"%s\" line %d)", fileName,
+- interp->errorLine);
++ ERRORLINE(interp));
+ Tcl_AddErrorInfo (interp, buf);
+ ckfree (buf);