summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2021-01-21 15:54:02 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2021-01-21 15:54:02 (GMT)
commit14ab9ebc5587ac72f4563e25cfbb4da049802c14 (patch)
tree54a455d7e8946c606c1df44076bebaafdd57aa08
parent0befd21328e7c588add11917de378e0915012ad3 (diff)
parent2e5746d60c48acffe82b3838e5ce5b56203ea0c2 (diff)
downloadtcl-14ab9ebc5587ac72f4563e25cfbb4da049802c14.zip
tcl-14ab9ebc5587ac72f4563e25cfbb4da049802c14.tar.gz
tcl-14ab9ebc5587ac72f4563e25cfbb4da049802c14.tar.bz2
Fix [8c025f8f0d]: Run-time error on tcl 8.6.11 32 bits (from cross-compile Centos6.9 64-bits)
-rw-r--r--generic/tcl.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/generic/tcl.h b/generic/tcl.h
index 3232734..cab5c53 100644
--- a/generic/tcl.h
+++ b/generic/tcl.h
@@ -332,6 +332,15 @@ typedef long LONG;
# undef HAVE_STRUCT_STAT64
#endif /* __APPLE__ */
+/* Cross-compiling 32-bit on a 64-bit platform? Then our
+ * configure script does the wrong thing. Correct that here.
+ */
+#if defined(__GNUC__) && !defined(_WIN32) && !defined(__LP64__)
+# undef TCL_WIDE_INT_IS_LONG
+# undef TCL_WIDE_INT_TYPE
+# define TCL_WIDE_INT_TYPE long long
+#endif
+
/*
* Define Tcl_WideInt to be a type that is (at least) 64-bits wide, and define
* Tcl_WideUInt to be the unsigned variant of that type (assuming that where