Posted to tcl by GPS at Tue Oct 23 21:58:40 GMT 2007view raw

  1. set dir [file dirname [info script]]
  2. set mach $::tcl_platform(machine)
  3. if {[string match -nocase i?86 $mach] || "intel" eq $mach || "Intel" eq $mach} {
  4. set mach i386
  5. }
  6.  
  7. set os [lindex [split $::tcl_platform(os)] 0]
  8. set d [file join $dir lib arch $mach $os]
  9. set ext [info sharedlibextension]
  10.  

Comments

Posted by patthoyts at Tue Oct 23 22:08:25 GMT 2007 [text] [code]

In 8.5 the platform command that was used in critcl got rolled into a core platform package: % list [package require platform] [platform::generic] [::platform::identify] 1.0.3 win32-ix86 win32-ix86