Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > Why does Apple include Tcl/tk in OS X?

Why does Apple include Tcl/tk in OS X?
Thread Tools
Mac Enthusiast
Join Date: Nov 1999
Location: Milkyway Galaxy
Status: Offline
Reply With Quote
Oct 14, 2001, 03:54 AM
 
Hello, I was just curious as to why Apple includes the TCL toolkit in every installation of OS X? I am/was fimiliar with TCL back when I toyed with Linux, so I know what it is and what you can do.

Has Apple ported TCL to Quartz or something?

Also, the installation is of an older TCL (8.3), is it wise to download a later version of Tcl/Tk?

thanx
Death To Extremists!
     
Professional Poster
Join Date: Mar 2000
Location: London, UK
Status: Offline
Reply With Quote
Oct 14, 2001, 03:35 PM
 
tcl doesn't have a UI, tk is the UI toolkit, and yes, Apple has just about ported tk to run on Aqua, but it depends on TCL/TK 8.4 so they're waiting until that's out of alpha before shipping it. See here: http://www.opensource.apple.com/bugs/X/Tcl/2781056.html
     
Posting Junkie
Join Date: Nov 1999
Status: Offline
Reply With Quote
Oct 15, 2001, 01:07 PM
 
Tcl is very nice for some things. It's particularly great for making human-readable config files (that's what it was made for, in fact), and it's also pretty good for making servers that you telnet into. Plus you get the awesome expect, though I don't think that has been ported to OSX yet.

Tk is really important, though. The reason is that Tcl isn't the only language that uses it for GUI's; Perl and Python can both use it too, as well as several others. So it gives GUI bindings to many more languages.

Granted, this could also be done via OSA, which could theoretically give these languages full access to Cocoa. But Tk is more portable, which is a plus for cross-platform apps as well as existing Unix-based Tk programs.
Fight your friends! Play AnimeVersus today!
You are in Soviet Russia. It is dark. Grue is likely to be eaten by YOU!
     
Professional Poster
Join Date: Mar 2000
Location: London, UK
Status: Offline
Reply With Quote
Oct 15, 2001, 01:39 PM
 
I think that there is a package for expect in Fink... Or there has been one submitted, or something like that
     
Mac Enthusiast
Join Date: Nov 1999
Location: Milkyway Galaxy
Status: Offline
Reply With Quote
Oct 15, 2001, 03:32 PM
 
thanks for the info.

but _why_ does Apple want to include tcl in the first place is my question.their are a few other cool languages that i'd like to see pre-compiled and ready for DarwinPPC/OS X besides the usual (perl, phy, python,etc)

Any ideas?
Death To Extremists!
     
Forum Regular
Join Date: Mar 2001
Location: Iowa City, IA
Status: Offline
Reply With Quote
Oct 15, 2001, 03:54 PM
 
You can't use Tk by itself. It depends on Tcl for its runtime, and specifically for event handling. Even if you're doing your coding in Python, or Perl, and using Tk for the interface, you need Tcl in the background.

Besides, it's a popular scripting/RAD environment in the UNIX world. Why not include it?
James

"I grew up. Then I got better." - Sea Wasp
     
Mac Enthusiast
Join Date: Feb 2001
Location: Rochester, uk
Status: Offline
Reply With Quote
Oct 19, 2001, 09:32 AM
 
expect?
All words are lies. Including these ones.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 04:16 PM.
All contents of these forums © 1995-2009 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.4 © 2000-2009, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2