Changeset 6 for trunk/tcl/install


Ignore:
Timestamp:
Mar 23, 2005, 8:19:29 PM (20 years ago)
Author:
mmc
Message:

Fixed the Tcl library to mirror the API developed for XML
libraries on the Python side. The Tcl Rappture::library
now has methods like "children", "element", "put", etc.
One difference: On the Tcl side, the default -flavor for
element/children is "component", since that works better
in Tcl code. In Python, the default is flavor=object.

Also fixed the Tcl install script to install not just
the tcl/scripts library, but also the ../gui and ../lib
directories.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tcl/install

    r1 r6  
    4040set targetdir [file join $dir $package$version]
    4141
    42 mkindex scripts
    43 
    4442if {![file exists $targetdir]} {
    4543    puts "making directory $targetdir..."
     
    4745}
    4846
    49 foreach file [find .] {
     47set origdir [pwd]
     48foreach context {. ../gui} {
     49    cd $context
     50
     51    foreach file [find .] {
     52        set target [file join $targetdir $file]
     53        if {[file isdirectory $file]} {
     54            puts "making directory $target..."
     55            catch {file mkdir $target}
     56            file attributes $target -permissions ugo+rx
     57        } else {
     58            puts "installing $target..."
     59            file copy -force $file $target
     60            file attributes $target -permissions ugo+r
     61        }
     62    }
     63}
     64
     65cd ..
     66catch {file mkdir [file join $targetdir lib]}
     67foreach file [find ./lib] {
    5068    set target [file join $targetdir $file]
    5169    if {[file isdirectory $file]} {
     
    6078}
    6179
     80cd $origdir
     81
    6282set fid [open [file join $targetdir pkgIndex.tcl] w]
    6383puts $fid "# Tcl package index file"
     
    6989close $fid
    7090
     91mkindex [file join $targetdir scripts]
     92
    7193puts "== $package-$version INSTALLED"
Note: See TracChangeset for help on using the changeset viewer.