Skip to content

Commit 6f3ab98

Browse files
zaniebindygreg
andauthored
Upgrade tcl/tk from 8.6.12 to 8.6.14 on Unix (#495)
Rebase of #313 to only apply to Unix. We'll handle Windows separately in #494. --------- Co-authored-by: Gregory Szorc <gregory.szorc@gmail.com>
1 parent 6a1b95d commit 6f3ab98

File tree

6 files changed

+46
-12
lines changed

6 files changed

+46
-12
lines changed

cpython-unix/build-cpython.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,7 @@ if [ "${PYBUILD_PLATFORM}" = "macos" ]; then
473473
# symbol.
474474
if [ -n "${PYTHON_MEETS_MAXIMUM_VERSION_3_9}" ]; then
475475
if [ "${TARGET_TRIPLE}" != "aarch64-apple-darwin" ]; then
476-
for symbol in clock_getres clock_gettime clock_settime faccessat fchmodat fchownat fdopendir fstatat futimens getentropy linkat mkdirat openat preadv pwritev readlinkat renameat symlinkat unlinkat utimensat; do
476+
for symbol in clock_getres clock_gettime clock_settime faccessat fchmodat fchownat fdopendir fstatat futimens getentropy linkat mkdirat openat preadv pwritev readlinkat renameat symlinkat unlinkat utimensat uttype; do
477477
CONFIGURE_FLAGS="${CONFIGURE_FLAGS} ac_cv_func_${symbol}=no"
478478
done
479479
fi
@@ -1083,7 +1083,7 @@ if [ -d "${TOOLS_PATH}/deps/lib/tcl8" ]; then
10831083
# Copy tcl/tk/tix resources needed by tkinter.
10841084
mkdir ${ROOT}/out/python/install/lib/tcl
10851085
# Keep this list in sync with tcl_library_paths.
1086-
for source in ${TOOLS_PATH}/deps/lib/{itcl4.2.2,tcl8,tcl8.6,thread2.8.7,tk8.6}; do
1086+
for source in ${TOOLS_PATH}/deps/lib/{itcl4.2.4,tcl8,tcl8.6,thread2.8.9,tk8.6}; do
10871087
cp -av $source ${ROOT}/out/python/install/lib/
10881088
done
10891089

cpython-unix/build.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -893,7 +893,7 @@ def build_cpython(
893893

894894
python_info["tcl_library_path"] = "install/lib"
895895
python_info["tcl_library_paths"] = [
896-
"itcl4.2.2",
896+
"itcl4.2.4",
897897
"tcl8",
898898
"tcl8.6",
899899
"thread2.8.7",

cpython-unix/extension-modules.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -689,6 +689,7 @@ _tkinter:
689689
- CoreGraphics
690690
- IOKit
691691
- QuartzCore
692+
- UniformTypeIdentifiers
692693

693694
_tokenize:
694695
minimum-python-version: "3.11"

cpython-windows/build.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@
114114
"_lzma": ["xz"],
115115
"_sqlite3": ["sqlite"],
116116
"_ssl": ["openssl"],
117-
"_tkinter": ["tcl", "tk", "tix"],
117+
"_tkinter": ["tcl-8612", "tk-8612", "tix"],
118118
"_uuid": ["uuid"],
119119
"zlib": ["zlib"],
120120
}
@@ -355,7 +355,7 @@ def hack_props(
355355
sqlite_version = DOWNLOADS["sqlite"]["version"]
356356
xz_version = DOWNLOADS["xz"]["version"]
357357
zlib_version = DOWNLOADS["zlib"]["version"]
358-
tcltk_commit = DOWNLOADS["tk-windows-bin"]["git_commit"]
358+
tcltk_commit = DOWNLOADS["tk-windows-bin-8612"]["git_commit"]
359359
mpdecimal_version = DOWNLOADS["mpdecimal"]["version"]
360360

361361
sqlite_path = td / ("sqlite-autoconf-%s" % sqlite_version)
@@ -1197,7 +1197,7 @@ def build_cpython(
11971197
bzip2_archive = download_entry("bzip2", BUILD)
11981198
sqlite_archive = download_entry("sqlite", BUILD)
11991199
tk_bin_archive = download_entry(
1200-
"tk-windows-bin", BUILD, local_name="tk-windows-bin.tar.gz"
1200+
"tk-windows-bin-8612", BUILD, local_name="tk-windows-bin.tar.gz"
12011201
)
12021202
xz_archive = download_entry("xz", BUILD)
12031203
zlib_archive = download_entry("zlib", BUILD)

pythonbuild/downloads.py

Lines changed: 30 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -309,10 +309,10 @@
309309
"version": "5.38.2.2",
310310
},
311311
"tcl": {
312-
"url": "https://prdownloads.sourceforge.net/tcl/tcl8.6.12-src.tar.gz",
313-
"size": 10353486,
314-
"sha256": "26c995dd0f167e48b11961d891ee555f680c175f7173ff8cb829f4ebcde4c1a6",
315-
"version": "8.6.12",
312+
"url": "https://prdownloads.sourceforge.net/tcl/tcl8.6.14-src.tar.gz",
313+
"size": 11627322,
314+
"sha256": "5880225babf7954c58d4fb0f5cf6279104ce1cd6aa9b71e9a6322540e1c4de66",
315+
"version": "8.6.14",
316316
"library_names": ["tcl8.6"],
317317
"licenses": ["TCL"],
318318
"license_file": "LICENSE.tcl.txt",
@@ -326,6 +326,31 @@
326326
"license_file": "LICENSE.tix.txt",
327327
},
328328
"tk": {
329+
"url": "https://prdownloads.sourceforge.net/tcl/tk8.6.14-src.tar.gz",
330+
"size": 4510695,
331+
"sha256": "8ffdb720f47a6ca6107eac2dd877e30b0ef7fac14f3a84ebbd0b3612cee41a94",
332+
"version": "8.6.14",
333+
"library_names": ["tk8.6"],
334+
"licenses": ["TCL"],
335+
"license_file": "LICENSE.tcl.txt",
336+
},
337+
"tk-windows-bin": {
338+
"url": "https://github.com/python/cpython-bin-deps/archive/c624cc881bd0e5071dec9de4b120cbe9985d8c14.tar.gz",
339+
"size": 9497943,
340+
"sha256": "9b8e77d55f40ceaedd140ccca0daa804f0d43346d5abfcead9b547b5590f82f8",
341+
"version": "8.6.14",
342+
"git_commit": "c624cc881bd0e5071dec9de4b120cbe9985d8c14",
343+
},
344+
"tcl-8612": {
345+
"url": "https://prdownloads.sourceforge.net/tcl/tcl8.6.12-src.tar.gz",
346+
"size": 10353486,
347+
"sha256": "26c995dd0f167e48b11961d891ee555f680c175f7173ff8cb829f4ebcde4c1a6",
348+
"version": "8.6.12",
349+
"library_names": ["tcl8.6"],
350+
"licenses": ["TCL"],
351+
"license_file": "LICENSE.tcl.txt",
352+
},
353+
"tk-8612": {
329354
"url": "https://prdownloads.sourceforge.net/tcl/tk8.6.12-src.tar.gz",
330355
"size": 4515393,
331356
"sha256": "12395c1f3fcb6bed2938689f797ea3cdf41ed5cb6c4766eec8ac949560310630",
@@ -334,7 +359,7 @@
334359
"licenses": ["TCL"],
335360
"license_file": "LICENSE.tcl.txt",
336361
},
337-
"tk-windows-bin": {
362+
"tk-windows-bin-8612": {
338363
"url": "https://github.com/python/cpython-bin-deps/archive/e3c3e9a2856124aa32b608632a52742d479eb7a9.tar.gz",
339364
"size": 6787654,
340365
"sha256": "01ad9c663659224e075d487cbc33ea2fed7a225593965b79bed92ca7f79b676f",

src/validation.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,10 @@ static ELF_ALLOWED_LIBRARIES_BY_TRIPLE: Lazy<HashMap<&'static str, Vec<&'static
238238
),
239239
("mips64el-unknown-linux-gnuabi64", vec![]),
240240
("ppc64le-unknown-linux-gnu", vec!["ld64.so.1", "ld64.so.2"]),
241-
("riscv64-unknown-linux-gnu", vec!["ld-linux-riscv64-lp64d.so.1", "libatomic.so.1"]),
241+
(
242+
"riscv64-unknown-linux-gnu",
243+
vec!["ld-linux-riscv64-lp64d.so.1", "libatomic.so.1"],
244+
),
242245
("s390x-unknown-linux-gnu", vec!["ld64.so.1"]),
243246
("x86_64-unknown-linux-gnu", vec!["ld-linux-x86-64.so.2"]),
244247
("x86_64_v2-unknown-linux-gnu", vec!["ld-linux-x86-64.so.2"]),
@@ -394,6 +397,11 @@ static DARWIN_ALLOWED_DYLIBS: Lazy<Vec<MachOAllowedDylib>> = Lazy::new(|| {
394397
max_compatibility_version: "1.0.0".try_into().unwrap(),
395398
required: true,
396399
},
400+
MachOAllowedDylib {
401+
name: "/System/Library/Frameworks/UniformTypeIdentifiers.framework/Versions/A/UniformTypeIdentifiers".to_string(),
402+
max_compatibility_version: "1.0.0".try_into().unwrap(),
403+
required: true,
404+
},
397405
MachOAllowedDylib {
398406
name: "/usr/lib/libedit.3.dylib".to_string(),
399407
max_compatibility_version: "2.0.0".try_into().unwrap(),

0 commit comments

Comments
 (0)