From 177e51dce83dc9c94947fbfa3a0035cc0c4c856f Mon Sep 17 00:00:00 2001 From: uvok Date: Wed, 24 Dec 2025 15:58:45 +0100 Subject: Adjst Makefile - add dependency - Make PROGRAM variable --- Makefile | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 607aa6a..f558ca1 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,9 @@ MAKEFLAGS += --no-builtin-rules MAKEFLAGS += --no-builtin-variables .SUFFIXES: -all: led.fs +PROGRAM ?= led + +all: $(PROGRAM).fs tangnano9k.cst: wget https://github.com/YosysHQ/apicula/raw/refs/heads/master/examples/tangnano9k.cst || \ @@ -20,7 +22,9 @@ tangnano9k.cst: || \ nextpnr-gowin --json $< --write $@ \ --device GW1NR-LV9QN88PC6/I5 --family GW1N-9C \ - --cst tangnano9k.cst + --cst tangnano9k.cst \ + --placed-svg $*.plc.svg \ + --routed-svg $*.rt.svg %.fs: %.pnr.json gowin_pack -d GW1N-9C -o $@ $< @@ -30,3 +34,6 @@ flash: led.fs clean: rm -rf *.json *.fs *.svg *.log + +led.fs: clkdiv.v + -- cgit v1.2.3