diff --git a/src/xschem.tcl b/src/xschem.tcl index 89243e62..f8987930 100644 --- a/src/xschem.tcl +++ b/src/xschem.tcl @@ -5920,7 +5920,13 @@ proc rel_sym_path {symbol} { if {$name eq {} } { # no known lib, so return full path set name ${symbol} + if {[file dirname $name] eq $curr_dirname} { + # remove path if file is in pwd + set name [file tail $name] + } + } + return $name }