summaryrefslogtreecommitdiff
path: root/passes/techmap/Makefile.inc
blob: b49259a8a83b15a354c1d19a38757891331a519e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
OBJS += passes/techmap/techmap.o
OBJS += passes/techmap/simplemap.o
OBJS += passes/techmap/dfflibmap.o
OBJS += passes/techmap/libparse.o

ifneq ($(SMALL),1)
OBJS += passes/techmap/iopadmap.o
OBJS += passes/techmap/hilomap.o
OBJS += passes/techmap/extract.o
endif

GENFILES += passes/techmap/techmap.inc

passes/techmap/techmap.inc: techlibs/common/techmap.v
	$(P) echo "// autogenerated from $<" > $@.new
	$(Q) echo "static char stdcells_code[] = {" >> $@.new
	$(Q) od -v -td1 -An $< | $(SED) -e 's/[0-9][0-9]*/&,/g' >> $@.new
	$(Q) echo "0};" >> $@.new
	$(Q) mv $@.new $@

passes/techmap/techmap.o: passes/techmap/techmap.inc

TARGETS += yosys-filterlib
GENFILES += passes/techmap/filterlib.o

yosys-filterlib: passes/techmap/filterlib.o
	$(P) $(CXX) -o yosys-filterlib $(LDFLAGS) $^ $(LDLIBS)