From 393788a0396a86af92d3cea9dc475e6d79348926 Mon Sep 17 00:00:00 2001 From: Tim Edwards Date: Mon, 29 Jan 2018 13:24:54 -0500 Subject: [PATCH] Changed behavior of the "lvs" script so that the setup file can be specified as "nosetup" if the "lvs" command is being called interactively from a terminal or as part of a larger script where setup commands have been issued prior to running the "lvs" script. Similarly, the log file can be specified as "nolog" to prevent any log file from being generated. --- tcltk/netgen.tcl.in | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/tcltk/netgen.tcl.in b/tcltk/netgen.tcl.in index 4f449b5..2621f55 100644 --- a/tcltk/netgen.tcl.in +++ b/tcltk/netgen.tcl.in @@ -475,15 +475,22 @@ proc netgen::lvs { name1 name2 {setupfile setup.tcl} {logfile comp.out} args} { if {$perrors > 0} { puts stdout "Warning: There were errors reading the setup file" } - } else { + } elseif {[string first nosetup $setupfile] < 0} { netgen::permute default ;# transistors and resistors netgen::property default } - puts stdout "Comparison output logged to file $logfile" - netgen::log file $logfile - netgen::log start - netgen::log echo off + if {[string first nolog $logfile] < 0} { + puts stdout "Comparison output logged to file $logfile" + netgen::log file $logfile + + netgen::log start + netgen::log echo off + set dolog true + } else { + set dolog false + } + if {$dolist == 1} { set endval [netgen::compare -list hierarchical "$fnum1 $cell1" "$fnum2 $cell2"] } else { @@ -566,7 +573,9 @@ proc netgen::lvs { name1 name2 {setupfile setup.tcl} {logfile comp.out} args} { if {$properr != {}} { netgen::log put "The following cells had property errors: $properr\n" } - netgen::log end + if {$dolog} { + netgen::log end + } puts stdout "LVS Done." if {$dojson == 1} { netgen::convert_to_json $logfile $lvs_final