Skip to content

Commit 309540e

Browse files
committed
flow: preserve OPENROAD_EXE/OPENSTA_EXE origin across sub-makes
`export OPENROAD_EXE := $(OPENROAD_EXE)` rebinds the variable to origin "file", which puts it on the UNSET_VARIABLES_NAMES list that UNSET_AND_MAKE clears before invoking a sub-make. In sub-make the variable is gone and the `?=` fallback resolves to the in-tree `tools/install/OpenROAD/bin/openroad` path that does not exist in a Bazel sandbox, so every stage invoked via UNSET_AND_MAKE (floorplan, place, route, final) fails with "openroad: No such file or directory". Using a bare `export` preserves the original origin (environment when bazel-orfs supplies it, file when the local default fills in) so the env value survives the UNSET_VARS step and sub-makes see the right binary. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
1 parent 16015c8 commit 309540e

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

flow/scripts/variables.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@ else
9292
OPENSTA_EXE ?= $(abspath $(FLOW_HOME)/../tools/install/OpenROAD/bin/sta)
9393
endif
9494

95-
export OPENROAD_EXE := $(OPENROAD_EXE)
96-
export OPENSTA_EXE := $(OPENSTA_EXE)
95+
export OPENROAD_EXE
96+
export OPENSTA_EXE
9797

9898
OPENROAD_IS_VALID := $(if $(OPENROAD_EXE),$(shell test -x $(OPENROAD_EXE) && echo "true"),)
9999

0 commit comments

Comments
 (0)