@@ -34,7 +34,7 @@ export PDK?=sky130A
34
34
export PDKPATH? =$(PDK_ROOT ) /$(PDK )
35
35
36
36
.PHONY : setup
37
- setup : check_dependencies install-mcw install-frigate pdk-with-volare setup-cocotb
37
+ setup : check_dependencies install-mgmt install-frigate pdk-with-volare setup-cocotb
38
38
39
39
.PHONY : check_dependencies
40
40
check_dependencies :
@@ -59,8 +59,8 @@ install-volare:
59
59
./venv/bin/$(PYTHON_BIN ) -m pip install --upgrade --no-cache-dir volare
60
60
61
61
# Include mgmt
62
- .PHONY : install-mcw
63
- install-mcw :
62
+ .PHONY : install-mgmt
63
+ install-mgmt :
64
64
if [ -d " $( MGMT_ROOT) " ]; then\
65
65
MAKE_DIR=" $( PWD) " ; \
66
66
echo " Updating $( MGMT_ROOT) " ; \
@@ -117,13 +117,12 @@ echo-var:
117
117
118
118
119
119
# Harden with Openlane2
120
- OPENLANE2_TAG ?= 2.3.3
120
+ OPENLANE2_TAG ?= 2.3.5
121
121
OPENLANE2_IMAGE_NAME ?= efabless/openlane:$(OPENLANE2_TAG )
122
122
OPENLANE2_RUN_TAG = $(shell date '+% y_% m_% d_% H_% M')
123
123
OPENLANE2_USE_NIX ?= 1
124
124
ROOTLESS ?= 0
125
125
USER_ARGS = -u $$(id -u $$USER ) :$$(id -g $$USER )
126
- designs = $(shell cd $(PROJECT_ROOT ) /openlane && find * -maxdepth 0 -type d)
127
126
current_design = null
128
127
129
128
ifeq ($(ROOTLESS ) , 1)
@@ -182,21 +181,29 @@ list:
182
181
@echo $(designs )
183
182
184
183
# export PYTHONPATH=$(PROJECT_ROOT)/openlane_plugin_Frigate:\$$PYTHONPATH
185
- .PHONY : $(designs )
186
- $(designs ) : export current_design=$@
187
- $(designs ) : % : $(PROJECT_ROOT ) /openlane/% /config.yaml
188
- # $(current_design)
189
- @rm -rf $(PROJECT_ROOT ) /openlane/$* /runs/$(OPENLANE2_RUN_TAG )
190
- ifeq ($(current_design ) ,user_project_wrapper)
191
- openlane_args += $(PROJECT_ROOT)/openlane/$(current_design)/fixed_dont_change/fixed_config.yaml
192
- endif
193
-
184
+ designs = $(shell cd $(PROJECT_ROOT ) /openlane && find * -maxdepth 0 -type d ! -name "user_project_wrapper")
194
185
ifeq ($(OPENLANE2_USE_NIX ) ,1)
195
- nix develop --command openlane $(openlane_args) $(openlane_extra_args)
186
+ openlane_cmd = nix develop --command openlane $(openlane_args ) $(openlane_extra_args )
196
187
else
197
- $(PROJECT_ROOT)/openlane2-venv/bin/python3 -m openlane $(docker_mounts) $(openlane_extra_args) --dockerized $(openlane_args) $(openlane_extra_args)
188
+ openlane_cmd = $(PROJECT_ROOT ) /openlane2-venv/bin/python3 -m openlane $(docker_mounts ) $(openlane_extra_args ) --dockerized $(openlane_args ) $(openlane_extra_args )
198
189
endif
199
- @sh $(PROJECT_ROOT)/openlane/copy_views.sh $(PROJECT_ROOT) $* $(OPENLANE2_RUN_TAG)
190
+
191
+ define run_openlane
192
+ rm -rf $(PROJECT_ROOT ) /openlane/$* /runs/$(OPENLANE2_RUN_TAG )
193
+ $(openlane_cmd ) $1
194
+ endef
195
+
196
+ .PHONY : user_project_wrapper
197
+ user_project_wrapper : % : $(PROJECT_ROOT ) /openlane/user_project_wrapper/config.yaml
198
+ $(call run_openlane,$(PROJECT_ROOT ) /openlane/user_project_wrapper/fixed_config.yaml)
199
+ # $(openlane_cmd) $(PROJECT_ROOT)/openlane/user_project_wrapper/fixed_config.yaml -c "step"=Frigate.CustomApplyDEFTemplate
200
+ sh $(PROJECT_ROOT)/openlane/copy_views.sh $(PROJECT_ROOT) $* $(OPENLANE2_RUN_TAG)
201
+
202
+ .PHONY : $(designs )
203
+ $(designs ) : export current_design=$@
204
+ $(designs ) : % : $(PROJECT_ROOT ) /openlane/% /config.yaml
205
+ $(call run_openlane)
206
+ sh $(PROJECT_ROOT ) /openlane/copy_views.sh $(PROJECT_ROOT ) $* $(OPENLANE2_RUN_TAG )
200
207
201
208
.PHONY : harden
202
209
harden : $(designs )
0 commit comments