Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpo-42361: Use Tcl/Tk 8.6.10 when building the installer on recent macOS #23293

Merged
merged 1 commit into from
Nov 22, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 32 additions & 9 deletions Mac/BuildScript/build-installer.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,9 @@ def getFullVersion():
def getDeptargetTuple():
return tuple([int(n) for n in DEPTARGET.split('.')[0:2]])

def getBuildTuple():
return tuple([int(n) for n in platform.mac_ver()[0].split('.')[0:2]])

def getTargetCompilers():
target_cc_map = {
'10.4': ('gcc-4.0', 'g++-4.0'),
Expand Down Expand Up @@ -192,6 +195,13 @@ def getTargetCompilers():
def internalTk():
return getDeptargetTuple() >= (10, 6)

# Do we use 8.6.8 when building our own copy
# of Tcl/Tk or a modern version.
# We use the old version when buildin on
# old versions of macOS due to build issues.
def useOldTk():
return getBuildTuple() < (10, 15)


def tweak_tcl_build(basedir, archList):
with open("Makefile", "r") as fp:
Expand Down Expand Up @@ -245,11 +255,26 @@ def library_recipes():
])

if internalTk():
if useOldTk():
tcl_tk_ver='8.6.8'
tcl_checksum='81656d3367af032e0ae6157eff134f89'

tk_checksum='5e0faecba458ee1386078fb228d008ba'
tk_patches = ['tk868_on_10_8_10_9.patch']

else:
tcl_tk_ver='8.6.10'
tcl_checksum='97c55573f8520bcab74e21bfd8d0aadc'

tk_checksum='602a47ad9ecac7bf655ada729d140a94'
tk_patches = [ ]


result.extend([
dict(
name="Tcl 8.6.8",
url="ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tcl8.6.8-src.tar.gz",
checksum='81656d3367af032e0ae6157eff134f89',
name="Tcl %s"%(tcl_tk_ver,),
url="ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tcl%s-src.tar.gz"%(tcl_tk_ver,),
checksum=tcl_checksum,
buildDir="unix",
configure_pre=[
'--enable-shared',
Expand All @@ -264,12 +289,10 @@ def library_recipes():
},
),
dict(
name="Tk 8.6.8",
url="ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tk8.6.8-src.tar.gz",
checksum='5e0faecba458ee1386078fb228d008ba',
patches=[
"tk868_on_10_8_10_9.patch",
],
name="Tk %s"%(tcl_tk_ver,),
url="ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tk%s-src.tar.gz"%(tcl_tk_ver,),
checksum=tk_checksum,
patches=tk_patches,
buildDir="unix",
configure_pre=[
'--enable-aqua',
Expand Down