diff --git a/Fix-11ae2be95d-tip-389-branch-string-range-errors-wi.patch b/Fix-11ae2be95d-tip-389-branch-string-range-errors-wi.patch deleted file mode 100644 index bdc2bfb1c4f0dfb3613946af7b8577e947777bfa..0000000000000000000000000000000000000000 --- a/Fix-11ae2be95d-tip-389-branch-string-range-errors-wi.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 7fff40c678507ffe82b3c65f1a0277a6da0b906e Mon Sep 17 00:00:00 2001 -From: "jan.nijtmans" -Date: Fri, 12 Jan 2018 10:03:58 +0000 -Subject: [PATCH 0837/1800] Fix [11ae2be95d]: tip-389 branch: string range - errors with code points greater than U+FFFF - ---- - generic/tclExecute.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/generic/tclExecute.c b/generic/tclExecute.c -index f2cda0ca8..63281a85e 100644 ---- a/generic/tclExecute.c -+++ b/generic/tclExecute.c -@@ -5445,7 +5445,7 @@ TEBCresume( - valuePtr->bytes+index, 1); - } else { - char buf[TCL_UTF_MAX] = ""; -- Tcl_UniChar ch = Tcl_GetUniChar(valuePtr, index); -+ int ch = Tcl_GetUniChar(valuePtr, index); - - /* - * This could be: Tcl_NewUnicodeObj((const Tcl_UniChar *)&ch, 1) -@@ -5453,7 +5453,7 @@ TEBCresume( - * practical use. - */ - -- length = Tcl_UniCharToUtf(ch, buf); -+ length = (ch != -1) ? Tcl_UniCharToUtf(ch, buf) : 0; - objResultPtr = Tcl_NewStringObj(buf, length); - } - --- -2.19.1 - diff --git a/Fix-error-message-for-min-math-functions-to-for-for-.patch b/Fix-error-message-for-min-math-functions-to-for-for-.patch deleted file mode 100644 index 08b59dc8b1e0a68db7c9d4e0d5b5e4a818eb0303..0000000000000000000000000000000000000000 --- a/Fix-error-message-for-min-math-functions-to-for-for-.patch +++ /dev/null @@ -1,88 +0,0 @@ -From a965b9b2624fefd1087fca8505ba3b486772ee70 Mon Sep 17 00:00:00 2001 -From: "jan.nijtmans" -Date: Mon, 20 Nov 2017 10:15:59 +0000 -Subject: [PATCH 0718/1800] Fix error-message for min/math functions: "to" -> - "for", for consistancy with the error-messages for other math functions. - ---- - library/init.tcl | 4 ++-- - tests/expr-old.test | 20 ++++++++++++++++---- - 2 files changed, 18 insertions(+), 6 deletions(-) - -diff --git a/library/init.tcl b/library/init.tcl -index 87d9f14da..13a4300c3 100644 ---- a/library/init.tcl -+++ b/library/init.tcl -@@ -79,7 +79,7 @@ namespace eval tcl { - proc min {args} { - if {![llength $args]} { - return -code error \ -- "too few arguments to math function \"min\"" -+ "too few arguments for math function \"min\"" - } - set val Inf - foreach arg $args { -@@ -95,7 +95,7 @@ namespace eval tcl { - proc max {args} { - if {![llength $args]} { - return -code error \ -- "too few arguments to math function \"max\"" -+ "too few arguments for math function \"max\"" - } - set val -Inf - foreach arg $args { -diff --git a/tests/expr-old.test b/tests/expr-old.test -index 3adfb635f..8c159b2bb 100644 ---- a/tests/expr-old.test -+++ b/tests/expr-old.test -@@ -1159,8 +1159,8 @@ test expr-old-40.2 {min math function} -body { - expr {min(0.0)} - } -result 0.0 - test expr-old-40.3 {min math function} -body { -- list [catch {expr {min()}} msg] $msg --} -result {1 {too few arguments to math function "min"}} -+ expr {min()} -+} -returnCodes error -result {too few arguments for math function "min"} - test expr-old-40.4 {min math function} -body { - expr {min(wide(-1) << 30, 4.5, -10)} - } -result [expr {wide(-1) << 30}] -@@ -1170,6 +1170,12 @@ test expr-old-40.5 {min math function} -body { - test expr-old-40.6 {min math function} -body { - expr {min(300, "0xFF")} - } -result 255 -+test expr-old-40.7 {min math function} -body { -+ expr min(1[string repeat 0 10000], 1e300) -+} -result 1e+300 -+test expr-old-40.8 {min math function} -body { -+ expr {min(0, "a")} -+} -returnCodes error -match glob -result * - - test expr-old-41.1 {max math function} -body { - expr {max(0)} -@@ -1178,8 +1184,8 @@ test expr-old-41.2 {max math function} -body { - expr {max(0.0)} - } -result 0.0 - test expr-old-41.3 {max math function} -body { -- list [catch {expr {max()}} msg] $msg --} -result {1 {too few arguments to math function "max"}} -+ expr {max()} -+} -returnCodes error -result {too few arguments for math function "max"} - test expr-old-41.4 {max math function} -body { - expr {max(wide(1) << 30, 4.5, -10)} - } -result [expr {wide(1) << 30}] -@@ -1189,6 +1195,12 @@ test expr-old-41.5 {max math function} -body { - test expr-old-41.6 {max math function} -body { - expr {max(200, "0xFF")} - } -result 255 -+test expr-old-41.7 {max math function} -body { -+ expr max(1[string repeat 0 10000], 1e300) -+} -result 1[string repeat 0 10000] -+test expr-old-41.8 {max math function} -body { -+ expr {max(0, "a")} -+} -returnCodes error -match glob -result * - - # Special test for Pentium arithmetic bug of 1994: - --- -2.19.1 - diff --git a/Improved-overflow-prevention-1.patch b/Improved-overflow-prevention-1.patch deleted file mode 100644 index 9e69e5b30ba30bffa255e6627bfaebecb8936d58..0000000000000000000000000000000000000000 --- a/Improved-overflow-prevention-1.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 5dfa918023df4ec9c5cbd4fe567ee509328f8d4f Mon Sep 17 00:00:00 2001 -From: dgp -Date: Mon, 5 Feb 2018 13:33:21 +0000 -Subject: [PATCH 0878/1800] Improved overflow prevention. - ---- - generic/tclStringObj.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c -index ae75e449e..8437555ed 100644 ---- a/generic/tclStringObj.c -+++ b/generic/tclStringObj.c -@@ -140,8 +140,8 @@ GrowStringBuffer( - objPtr->bytes = NULL; - } - if (flag == 0 || stringPtr->allocated > 0) { -- attempt = 2 * needed; -- if (attempt >= 0) { -+ if (needed <= INT_MAX / 2) { -+ attempt = 2 * needed; - ptr = attemptckrealloc(objPtr->bytes, attempt + 1); - } - if (ptr == NULL) { --- -2.19.1 - diff --git a/Improved-overflow-prevention-2.patch b/Improved-overflow-prevention-2.patch deleted file mode 100644 index 1f58714a47b1e3aa284251f3518583fac39c82a9..0000000000000000000000000000000000000000 --- a/Improved-overflow-prevention-2.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 183dadc7fae0994a33901a7246989d2605f5c70c Mon Sep 17 00:00:00 2001 -From: dgp -Date: Mon, 5 Feb 2018 13:41:26 +0000 -Subject: [PATCH 0879/1800] Improved overflow prevention. - ---- - generic/tclStringObj.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c -index 8437555ed..c3a0192d8 100644 ---- a/generic/tclStringObj.c -+++ b/generic/tclStringObj.c -@@ -190,8 +190,8 @@ GrowUnicodeBuffer( - * Subsequent appends - apply the growth algorithm. - */ - -- attempt = 2 * needed; -- if (attempt >= 0 && attempt <= STRING_MAXCHARS) { -+ if (needed <= STRING_MAXCHARS / 2) { -+ attempt = 2 * needed; - ptr = stringAttemptRealloc(stringPtr, attempt); - } - if (ptr == NULL) { --- -2.19.1 - diff --git a/fix-exec-test-error.patch b/fix-exec-test-error.patch deleted file mode 100644 index 72936fa6e0a6fac1f91d6521250c613267b7255f..0000000000000000000000000000000000000000 --- a/fix-exec-test-error.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 6abda12a6aea301b037341b4c7c6ff1fe84920f9 Mon Sep 17 00:00:00 2001 -From: chenzhen -Date: Tue, 6 Aug 2019 08:05:04 -0400 -Subject: [PATCH] fix exec test error - -reason: fix exec test error - -Signed-off-by: chenzhen ---- - tests/exec.test | 1 - - 1 file changed, 1 deletion(-) - -diff --git a/tests/exec.test b/tests/exec.test -index cd29171..c718b2f 100644 ---- a/tests/exec.test -+++ b/tests/exec.test -@@ -17,7 +17,6 @@ - package require tcltest 2 - namespace import -force ::tcltest::* - --package require tcltests - - # All tests require the "exec" command. - # Skip them if exec is not defined. --- -2.19.1 - diff --git a/tcl-8.6.10-autopath.patch b/tcl-8.6.12-autopath.patch similarity index 65% rename from tcl-8.6.10-autopath.patch rename to tcl-8.6.12-autopath.patch index f5ac0ba94489fdfcba9abd29acfc468a91c40816..4a14dd30e3b92752c93a13431110e3b5fe8b596a 100644 --- a/tcl-8.6.10-autopath.patch +++ b/tcl-8.6.12-autopath.patch @@ -1,5 +1,5 @@ diff --git a/library/auto.tcl b/library/auto.tcl -index a7a8979..892c2c4 100644 +index 7d23b6e..3c7717b 100644 --- a/library/auto.tcl +++ b/library/auto.tcl @@ -81,6 +81,13 @@ proc tcl_findLibrary {basename version patch initScript enVarName varName} { @@ -17,39 +17,39 @@ index a7a8979..892c2c4 100644 # Tcl library as well as allowing loading of libraries added to the # auto_path that is not relative to the core library or binary paths. diff --git a/library/init.tcl b/library/init.tcl -index 5cda0d9..ffeb301 100644 +index edf6bd5..fa37bcc 100644 --- a/library/init.tcl +++ b/library/init.tcl -@@ -47,16 +47,11 @@ if {![info exists auto_path]} { - } +@@ -52,16 +52,11 @@ if {![info exists auto_path]} { namespace eval tcl { - variable Dir -- foreach Dir [list $::tcl_library [file dirname $::tcl_library]] { -+ foreach Dir [list $::tcl_library] { - if {$Dir ni $::auto_path} { - lappend ::auto_path $Dir - } - } -- set Dir [file join [file dirname [file dirname \ -- [info nameofexecutable]]] lib] -- if {$Dir ni $::auto_path} { -- lappend ::auto_path $Dir -- } - catch { - foreach Dir $::tcl_pkgPath { + if {![interp issafe]} { + variable Dir +- foreach Dir [list $::tcl_library [file dirname $::tcl_library]] { ++ foreach Dir [list $::tcl_library] { if {$Dir ni $::auto_path} { + lappend ::auto_path $Dir + } + } +- set Dir [file join [file dirname [file dirname \ +- [info nameofexecutable]]] lib] +- if {$Dir ni $::auto_path} { +- lappend ::auto_path $Dir +- } + if {[info exists ::tcl_pkgPath]} { catch { + foreach Dir $::tcl_pkgPath { + if {$Dir ni $::auto_path} { diff --git a/unix/configure.in b/unix/configure.in -index 0d3f426..13ce9db 100755 +index c73f368..5c57692 100644 --- a/unix/configure.in +++ b/unix/configure.in @@ -866,9 +866,9 @@ if test "$FRAMEWORK_BUILD" = "1" ; then test -z "$TCL_MODULE_PATH" && \ TCL_MODULE_PATH="~/Library/Tcl /Library/Tcl" elif test "$prefix/lib" != "$libdir"; then -- test -z "$TCL_PACKAGE_PATH" && TCL_PACKAGE_PATH="${libdir} ${prefix}/lib ${TCL_PACKAGE_PATH}" +- test -z "$TCL_PACKAGE_PATH" && TCL_PACKAGE_PATH="{${libdir}} {${prefix}/lib} ${TCL_PACKAGE_PATH}" + test -z "$TCL_PACKAGE_PATH" && TCL_PACKAGE_PATH="${libdir}/tcl8.6 ${prefix}/share/tcl8.6 ${libdir}/tk8.6 ${prefix}/share/tk8.6 ${TCL_PACKAGE_PATH}" else -- test -z "$TCL_PACKAGE_PATH" && TCL_PACKAGE_PATH="${prefix}/lib ${TCL_PACKAGE_PATH}" +- test -z "$TCL_PACKAGE_PATH" && TCL_PACKAGE_PATH="{${prefix}/lib} ${TCL_PACKAGE_PATH}" + test -z "$TCL_PACKAGE_PATH" && TCL_PACKAGE_PATH="${libdir}/tcl8.6 ${prefix}/share/tcl8.6 ${libdir}/tk8.6 ${prefix}/share/tk8.6 ${TCL_PACKAGE_PATH}" fi diff --git a/tcl-8.6.10-conf.patch b/tcl-8.6.12-conf.patch similarity index 74% rename from tcl-8.6.10-conf.patch rename to tcl-8.6.12-conf.patch index 6dfa386edd27939310c4e98379e30af423d7068d..6e90fcb762c43ac5597b0e052bf610243c7e7980 100644 --- a/tcl-8.6.10-conf.patch +++ b/tcl-8.6.12-conf.patch @@ -1,8 +1,8 @@ diff --git a/unix/tcl.m4 b/unix/tcl.m4 -index 0e146e4..180fff1 100644 +index f3d08ec..ed12cda 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 -@@ -1410,12 +1410,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ +@@ -1382,7 +1382,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ # get rid of the warnings. #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES" @@ -11,8 +11,11 @@ index 0e146e4..180fff1 100644 DL_OBJS="tclLoadDl.o" DL_LIBS="-ldl" LDFLAGS="$LDFLAGS -Wl,--export-dynamic" +@@ -1398,7 +1398,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ + esac + AS_IF([test $doRpath = yes], [ -- CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}']) +- CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"']) + CC_SEARCH_FLAGS='']) LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} AS_IF([test "`uname -m`" = "alpha"], [CFLAGS="$CFLAGS -mieee"]) diff --git a/tcl-core8.6.10-src.tar.gz b/tcl-core8.6.12-src.tar.gz similarity index 44% rename from tcl-core8.6.10-src.tar.gz rename to tcl-core8.6.12-src.tar.gz index 1c32f7d9db9380ec329fc4f20f839cb3202b1493..4fbdfc3a488ec4be3773450d66d14908803e20bc 100644 Binary files a/tcl-core8.6.10-src.tar.gz and b/tcl-core8.6.12-src.tar.gz differ diff --git a/tcl.spec b/tcl.spec index 71078e1f41a2b8241bc448ff0ea4dbbd83667846..1e7a259ad10e341f44d7989336dec3dee4ba667f 100644 --- a/tcl.spec +++ b/tcl.spec @@ -1,8 +1,8 @@ %define MAJOR 8.6 Name: tcl -Version: 8.6.10 -Release: 3 +Version: 8.6.12 +Release: 1 Epoch: 1 Summary: The Tool Command Language implementation License: BSD @@ -14,18 +14,13 @@ Provides: tcl(abi) = %{MAJOR} Obsoletes: tcl-tcldict <= %{version} Provides: tcl-tcldict = %{version} -Patch0: tcl-8.6.10-autopath.patch -Patch1: tcl-8.6.10-conf.patch +Patch0: tcl-8.6.12-autopath.patch +Patch1: tcl-8.6.12-conf.patch Patch2: tcl-8.6.10-hidden.patch Patch3: tcl-8.6.10-tcltests-path-fix.patch Patch4: stay-out-of-internals-when-nice-interfaces-are-avail.patch Patch5: oops.patch -Patch6: Fix-error-message-for-min-math-functions-to-for-for-.patch -Patch7: Fix-11ae2be95d-tip-389-branch-string-range-errors-wi.patch -Patch8: Improved-overflow-prevention-1.patch -Patch9: Improved-overflow-prevention-2.patch -Patch10: fix-exec-test-error.patch -Patch11: File-not-found-should-be-ignored-silently.patch +Patch6: File-not-found-should-be-ignored-silently.patch %description Tcl(Tool Command Language) provides a powerful platform for creating integration applications @@ -127,6 +122,12 @@ make test %{_mandir}/mann/* %changelog +* Thu Apr 21 2022 zoulin - 1:8.6.12-1 +- Type:enhancement +- ID:NA +- SUG:NA +- DESC:update to 8.6.12 + * Fri May 28 2021 yangzhuangzhuang - 1:8.6.10-3 - Type:bugfix - ID:NA