#Auto generated by Edalize

TARGET   := {{ name }}

all: $(TARGET).fasm

{% for xdc in constr %}
XDCS += --xdc {{ xdc }}
{% endfor %}

{{ name }}.json: {{ name }}.mk
	$(EDALIZE_LAUNCHER) $(MAKE) -f $<

{{ name }}.fasm: {{ name }}.json
	$(EDALIZE_LAUNCHER) nextpnr-{{ arch }} --chipdb {{ chipdb }} $(XDCS) --json {{ name }}.json --write {{ name }}.routed.json --fasm {{ name }}.fasm --log nextpnr.log {{ additional_options }}

clean:
	$(EDALIZE_LAUNCHER) rm -f $(TARGET).fasm $(TARGET).routed.json
