summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornijtmans@users.sourceforge.net <jan.nijtmans>2013-01-31 12:41:37 (GMT)
committernijtmans@users.sourceforge.net <jan.nijtmans>2013-01-31 12:41:37 (GMT)
commit5501c43711b339823508af6b068f311d47ec62b3 (patch)
treecb292af67bf9c892e222f9bab28866705e5d321d
parent3c36d5c5181ad26915431a799ff76c5c7dbb3671 (diff)
parent154148a00fe716bcb45aa2173cdcc7d81951e45b (diff)
downloadtk-5501c43711b339823508af6b068f311d47ec62b3.zip
tk-5501c43711b339823508af6b068f311d47ec62b3.tar.gz
tk-5501c43711b339823508af6b068f311d47ec62b3.tar.bz2
Merge trunk.
Define some macros in tk.h which are needed by Tk as fallback, which might be removed from future tcl.h versions.
-rw-r--r--generic/tk.h27
1 files changed, 26 insertions, 1 deletions
diff --git a/generic/tk.h b/generic/tk.h
index 1594dc9..aa9cd22 100644
--- a/generic/tk.h
+++ b/generic/tk.h
@@ -20,7 +20,32 @@
#if (TCL_MAJOR_VERSION != 8) || (TCL_MINOR_VERSION < 6)
# error Tk 8.6 must be compiled with tcl.h from Tcl 8.6 or better
#endif
-
+
+#ifndef CONST84
+# define CONST84 const
+# define CONST84_RETURN const
+#endif
+#ifndef CONST86
+# define CONST86 CONST84
+#endif
+#ifndef EXTERN
+# define EXTERN extern TCL_STORAGE_CLASS
+#endif
+
+/*
+ * Utility macros: STRINGIFY takes an argument and wraps it in "" (double
+ * quotation marks), JOIN joins two arguments.
+ */
+
+#ifndef STRINGIFY
+# define STRINGIFY(x) STRINGIFY1(x)
+# define STRINGIFY1(x) #x
+#endif
+#ifndef JOIN
+# define JOIN(a,b) JOIN1(a,b)
+# define JOIN1(a,b) a##b
+#endif
+
/*
* For C++ compilers, use extern "C"
*/