333 |
|
|
334 |
foreach dir $dirlist { |
foreach dir $dirlist { |
335 |
foreach initfile $filelist { |
foreach initfile $filelist { |
336 |
verbose "Looking for $type ${dir}/${initfile}" 1 |
verbose "Looking for $type ${dir}/${initfile}" 2 |
337 |
if [file exists ${dir}/${initfile}] { |
if [file exists ${dir}/${initfile}] { |
338 |
set found 1 |
set found 1 |
339 |
set error "" |
set error "" |
507 |
|
|
508 |
"--di*" { |
"--di*" { |
509 |
set cmdline_dir_to_run $optarg |
set cmdline_dir_to_run $optarg |
|
puts "cmdline_dir_to_run = $cmdline_dir_to_run" |
|
510 |
continue |
continue |
511 |
} |
} |
512 |
|
|
515 |
incr verbose |
incr verbose |
516 |
continue |
continue |
517 |
} |
} |
518 |
|
|
519 |
|
"[A-Z0-9_-.]*=*" { # process makefile style args like CC=gcc, etc... |
520 |
|
if [regexp "^(\[A-Z0-9_-\]+)=(.*)$" $option junk var val] { |
521 |
|
set $var $val |
522 |
|
verbose "$var is now $val" |
523 |
|
append makevars "set $var $val;" ;# FIXME: Used anywhere? |
524 |
|
unset junk var val |
525 |
|
} else { |
526 |
|
send_error "Illegal variable specification:\n" |
527 |
|
send_error "$option\n" |
528 |
|
} |
529 |
|
continue |
530 |
|
} |
531 |
|
|
532 |
} |
} |
533 |
} |
} |
534 |
verbose "Verbose level is $verbose" |
verbose "Verbose level is $verbose" |
565 |
# |
# |
566 |
proc lookfor_file { dir name } { |
proc lookfor_file { dir name } { |
567 |
foreach x ".. ../.. ../../.. ../../../.." { |
foreach x ".. ../.. ../../.. ../../../.." { |
568 |
verbose "$dir/$name" |
verbose "$dir/$name" 2 |
569 |
if [file exists $dir/$name] { |
if [file exists $dir/$name] { |
570 |
return $dir/$name; |
return $dir/$name; |
571 |
} |
} |
1159 |
continue |
continue |
1160 |
} |
} |
1161 |
|
|
|
"[A-Z0-9_-.]*=*" { # process makefile style args like CC=gcc, etc... |
|
|
if [regexp "^(\[A-Z0-9_-\]+)=(.*)$" $option junk var val] { |
|
|
set $var $val |
|
|
verbose "$var is now $val" |
|
|
append makevars "set $var $val;" ;# FIXME: Used anywhere? |
|
|
unset junk var val |
|
|
} else { |
|
|
send_error "Illegal variable specification:\n" |
|
|
send_error "$option\n" |
|
|
} |
|
|
continue |
|
|
} |
|
|
|
|
1162 |
"--he*" { # (--help) help text |
"--he*" { # (--help) help text |
1163 |
usage; |
usage; |
1164 |
exit 0 |
exit 0 |
1177 |
exit 1 |
exit 1 |
1178 |
} |
} |
1179 |
} |
} |
1180 |
|
|
1181 |
} |
} |
1182 |
|
|
1183 |
# |
# |