mirror of https://github.com/YosysHQ/icestorm.git
30 lines
533 B
Makefile
30 lines
533 B
Makefile
PROJ = example
|
|
PIN_DEF = iceblink.pcf
|
|
DEVICE = hx1k
|
|
|
|
all: $(PROJ).rpt $(PROJ).bin
|
|
|
|
%.blif: %.v
|
|
yosys -p 'synth_ice40 -top top -blif $@' $<
|
|
|
|
%.asc: $(PIN_DEF) %.blif
|
|
arachne-pnr -d $(subst hx,,$(subst lp,,$(DEVICE))) -o $@ -p $^ -P vq100
|
|
|
|
%.bin: %.asc
|
|
icepack $< $@
|
|
|
|
%.rpt: %.asc
|
|
icetime -d $(DEVICE) -mtr $@ $<
|
|
|
|
prog: $(PROJ).bin
|
|
iCEburn.py -e -v -w $<
|
|
|
|
sudo-prog: $(PROJ).bin
|
|
@echo 'Executing prog as root!!!'
|
|
iCEburn.py -e -v -w $<
|
|
|
|
clean:
|
|
rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
|
|
|
|
.PHONY: all prog clean
|