phoned/configure.tcl

30 lines
743 B
Tcl
Raw Normal View History

2005-06-27 16:47:37 -04:00
#!/usr/local/bin/tclsh8.4
# Sets up configuration stuff
2005-06-27 17:05:51 -04:00
# $Amigan: phoned/configure.tcl,v 1.2 2005/06/27 21:05:51 dcp1990 Exp $
if {$argc < 2} {
puts stderr "Usage: configure.tcl prefix testing"
2005-06-27 16:47:37 -04:00
exit -1
}
set prefix [lindex $argv 0]
2005-06-27 17:05:51 -04:00
set testing [lindex $argv 1]
2005-06-27 16:47:37 -04:00
puts [list Prefix is [set prefix]...]
puts Configuring.
set xf [open "xfone/paths.tcl" w]
2005-06-27 17:05:51 -04:00
if {!$testing} {
puts $xf {# Generated by configure.tcl}
puts $xf [list set prefix $prefix]
puts $xf {set lib [set prefix]/lib/phoned
2005-06-27 16:47:37 -04:00
set udom_lib [set lib]/udom.so
}
2005-06-27 17:05:51 -04:00
} else {
puts $xf {# TESTING...generated by configure.tcl}
puts $xf [list set pfx [pwd]]
puts $xf {set lib [set pfx]/lib/tcl
set udom_lib [set lib]/udom.so
}
}
2005-06-27 16:47:37 -04:00
close $xf
#for lack of touch...
close [open .config w]