From 8b5ed3f32ed77b67044b7097376e845be518cdc2 Mon Sep 17 00:00:00 2001 From: stefan schippers Date: Fri, 19 Jul 2024 15:13:38 +0200 Subject: [PATCH] symbols picked up from CWD are saved in parent design without absolute paths even if the CWD is not in XSCHEM_LIBRARY_PATH list of places. --- src/xschem.tcl | 6 ++++++ 1 file changed, 6 insertions(+) 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 }