Remove duplicated list BUILD, derive one from the other - #392
Merged
maliberty merged 2 commits intoJul 23, 2026
Merged
Conversation
Signed-off-by: dsengupta0628 <dsengupta@precisioninno.com>
There was a problem hiding this comment.
Code Review
This pull request updates the BUILD file to dynamically derive the exported_tcl list from tcl_srcs by excluding specific standalone OpenSTA shell files (sta_only_tcl). This establishes tcl_srcs as the single source of truth and avoids manual maintenance of a duplicate list. There are no review comments, and I have no additional feedback to provide.
maliberty
approved these changes
Jul 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Long term maintainance for this fix: #391
spice/WriteSpice.tcl was never added to the Tcl lists in src/sta/BUILD, though CMake has it in both its encode lists (my slip while pulling upstream).
The SWIG glue (WriteSpice.i) is listed, so the C++ compiled - the Tcl command wrappers just never get registered.
The deeper issue though: src/sta/BUILD maintains two Tcl lists by hand.
tcl_srcs : encoded into the standalone OpenSTA binary
exported_tcl : re-exported via dbSta into the OpenROAD binary
exported_tcl is just tcl_srcs minus a few files OpenROAD replaces (Init.tcl, network/Link.tcl, verilog/Verilog.tcl).
Keeping two parallel lists in sync manually is kind of risky.
Potential fix for this long term- that will derive exported_tcl from tcl_srcs instead of maintaining it separately:
This makes tcl_srcs the single source of truth; any new command file flows to both binaries automatically unless explicitly excluded.
Set is identical to today; only ordering changes, which is safe (the two build systems already use different orders and both work).