From 40cf82c2cb7587fa602cce77e31b5c76207ca620 Mon Sep 17 00:00:00 2001 From: Tim Edwards Date: Tue, 7 Mar 2023 09:00:39 -0500 Subject: [PATCH] Slightly modified the fix from the last commit to allow an empty string for the setup file to be the "trivial default" previously used in case of the setup file not being found. Put a newline around the setup file messages so that they stand out from the rest of the initial output information. --- tcltk/netgen.tcl.in | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tcltk/netgen.tcl.in b/tcltk/netgen.tcl.in index 3540412..7fff096 100644 --- a/tcltk/netgen.tcl.in +++ b/tcltk/netgen.tcl.in @@ -479,8 +479,12 @@ proc netgen::lvs { name1 name2 {setupfile setup.tcl} {logfile comp.out} args} { netgen::compare assign "$fnum1 $cell1" "$fnum2 $cell2" - if {[file exists $setupfile]} { - puts stdout "Reading setup file $setupfile" + if {$setupfile == ""} { + puts stdout "\nNo setup file specified. Using trivial default setup.\n" + netgen::permute default ;# transistors and resistors + netgen::property default + } elseif {[file exists $setupfile]} { + puts stdout "\nReading setup file $setupfile\n" # Instead of sourcing the setup file, run each line so we can # catch individual errors and not let them halt the LVS process set perrors 0 @@ -508,10 +512,10 @@ proc netgen::lvs { name1 name2 {setupfile setup.tcl} {logfile comp.out} args} { puts stdout "Warning: There were errors reading the setup file" } } elseif {[string first nosetup $setupfile] < 0} { - puts stderr "Error: Setup file $setupfile does not exist." + puts stderr "\nError: Setup file $setupfile does not exist.\n" return } else { - puts stderr "No setup file specified. Continuing without a setup." + puts stderr "\nNo setup file specified. Continuing without a setup.\n" } if {[string first nolog $logfile] < 0} {