@@ -153,6 +153,9 @@ def getFullVersion():
153
153
def getDeptargetTuple ():
154
154
return tuple ([int (n ) for n in DEPTARGET .split ('.' )[0 :2 ]])
155
155
156
+ def getBuildTuple ():
157
+ return tuple ([int (n ) for n in platform .mac_ver ()[0 ].split ('.' )[0 :2 ]])
158
+
156
159
def getTargetCompilers ():
157
160
target_cc_map = {
158
161
'10.4' : ('gcc-4.0' , 'g++-4.0' ),
@@ -192,6 +195,13 @@ def getTargetCompilers():
192
195
def internalTk ():
193
196
return getDeptargetTuple () >= (10 , 6 )
194
197
198
+ # Do we use 8.6.8 when building our own copy
199
+ # of Tcl/Tk or a modern version.
200
+ # We use the old version when buildin on
201
+ # old versions of macOS due to build issues.
202
+ def useOldTk ():
203
+ return getBuildTuple () < (10 , 15 )
204
+
195
205
196
206
def tweak_tcl_build (basedir , archList ):
197
207
with open ("Makefile" , "r" ) as fp :
@@ -245,11 +255,26 @@ def library_recipes():
245
255
])
246
256
247
257
if internalTk ():
258
+ if useOldTk ():
259
+ tcl_tk_ver = '8.6.8'
260
+ tcl_checksum = '81656d3367af032e0ae6157eff134f89'
261
+
262
+ tk_checksum = '5e0faecba458ee1386078fb228d008ba'
263
+ tk_patches = ['tk868_on_10_8_10_9.patch' ]
264
+
265
+ else :
266
+ tcl_tk_ver = '8.6.10'
267
+ tcl_checksum = '97c55573f8520bcab74e21bfd8d0aadc'
268
+
269
+
8000
tk_checksum = '602a47ad9ecac7bf655ada729d140a94'
270
+ tk_patches = [ ]
271
+
272
+
248
273
result .extend ([
249
274
dict (
250
- name = "Tcl 8.6.8" ,
251
- url = "ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tcl8.6.8 -src.tar.gz" ,
252
- checksum = '81656d3367af032e0ae6157eff134f89' ,
275
+ name = "Tcl %s" % ( tcl_tk_ver ,) ,
276
+ url = "ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tcl%s -src.tar.gz" % ( tcl_tk_ver ,) ,
277
+ checksum = tcl_checksum ,
253
278
buildDir = "unix" ,
254
279
configure_pre = [
255
280
'--enable-shared' ,
@@ -264,12 +289,10 @@ def library_recipes():
264
289
},
265
290
),
266
291
dict (
267
- name = "Tk 8.6.8" ,
268
- url = "ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tk8.6.8-src.tar.gz" ,
269
- checksum = '5e0faecba458ee1386078fb228d008ba' ,
270
- patches = [
271
- "tk868_on_10_8_10_9.patch" ,
272
- ],
292
+ name = "Tk %s" % (tcl_tk_ver ,),
293
+ url = "ftp://ftp.tcl.tk/pub/tcl//tcl8_6/tk%s-src.tar.gz" % (tcl_tk_ver ,),
294
+ checksum = tk_checksum ,
295
+ patches = tk_patches ,
273
296
buildDir = "unix" ,
274
297
configure_pre = [
275
298
'--enable-aqua' ,
0 commit comments