summaryrefslogtreecommitdiff
path: root/package/tcl/patches
diff options
context:
space:
mode:
Diffstat (limited to 'package/tcl/patches')
-rw-r--r--package/tcl/patches/patch-unix_configure33
-rw-r--r--package/tcl/patches/patch-unix_tclUnixTime_c39
2 files changed, 72 insertions, 0 deletions
diff --git a/package/tcl/patches/patch-unix_configure b/package/tcl/patches/patch-unix_configure
new file mode 100644
index 000000000..393c2b45e
--- /dev/null
+++ b/package/tcl/patches/patch-unix_configure
@@ -0,0 +1,33 @@
+--- tcl8.5.8.orig/unix/configure 2009-11-13 19:38:45.000000000 +0100
++++ tcl8.5.8/unix/configure 2011-01-13 16:22:59.000000000 +0100
+@@ -7968,9 +7968,6 @@ fi
+ LD_SEARCH_FLAGS=""
+ LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH"
+
+-cat >>confdefs.h <<\_ACEOF
+-#define MAC_OSX_TCL 1
+-_ACEOF
+
+ PLAT_OBJS='${MAC_OSX_OBJS}'
+ PLAT_SRCS='${MAC_OSX_SRCS}'
+@@ -17646,11 +17643,6 @@ _ACEOF
+
+
+ cat >>confdefs.h <<\_ACEOF
+-#define TCL_LOAD_FROM_MEMORY 1
+-_ACEOF
+-
+-
+-cat >>confdefs.h <<\_ACEOF
+ #define TCL_WIDE_CLICKS 1
+ _ACEOF
+
+@@ -18817,7 +18809,7 @@ HTML_DIR='$(DISTDIR)/html'
+ # AIX remembers this path and will attempt to use it at run-time to look
+ # up the Tcl library.
+
+-if test "`uname -s`" = "Darwin" ; then
++if test "Linux" = "Darwin" ; then
+
+ if test "`uname -s`" = "Darwin" ; then
+ echo "$as_me:$LINENO: checking how to package libraries" >&5
diff --git a/package/tcl/patches/patch-unix_tclUnixTime_c b/package/tcl/patches/patch-unix_tclUnixTime_c
new file mode 100644
index 000000000..e0334126f
--- /dev/null
+++ b/package/tcl/patches/patch-unix_tclUnixTime_c
@@ -0,0 +1,39 @@
+--- tcl8.5.8.orig/unix/tclUnixTime.c 2008-04-14 19:49:59.000000000 +0200
++++ tcl8.5.8/unix/tclUnixTime.c 2011-01-13 15:59:00.000000000 +0100
+@@ -164,12 +164,6 @@ TclpGetWideClicks(void)
+
+ (*tclGetTimeProcPtr) (&time, tclTimeClientData);
+ now = (Tcl_WideInt) (time.sec*1000000 + time.usec);
+- } else {
+-#ifdef MAC_OSX_TCL
+- now = (Tcl_WideInt) (mach_absolute_time() & INT64_MAX);
+-#else
+-#error Wide high-resolution clicks not implemented on this platform
+-#endif
+ }
+
+ return now;
+@@ -200,23 +194,6 @@ TclpWideClicksToNanoseconds(
+
+ if (tclGetTimeProcPtr != NativeGetTime) {
+ nsec = clicks * 1000;
+- } else {
+-#ifdef MAC_OSX_TCL
+- static mach_timebase_info_data_t tb;
+- static uint64_t maxClicksForUInt64;
+-
+- if (!tb.denom) {
+- mach_timebase_info(&tb);
+- maxClicksForUInt64 = UINT64_MAX / tb.numer;
+- }
+- if ((uint64_t) clicks < maxClicksForUInt64) {
+- nsec = ((uint64_t) clicks) * tb.numer / tb.denom;
+- } else {
+- nsec = ((long double) (uint64_t) clicks) * tb.numer / tb.denom;
+- }
+-#else
+-#error Wide high-resolution clicks not implemented on this platform
+-#endif
+ }
+
+ return nsec;