2015-04-14 04:28:56 -04:00
|
|
|
INSTDIR = $(shell iverilog-vpi --install-dir)
|
|
|
|
|
|
|
|
CFLAGS = -Wall -O2 $(CFLAGS_$@)
|
|
|
|
VPI_CFLAGS := $(shell iverilog-vpi --cflags)
|
2012-03-06 09:51:09 -05:00
|
|
|
|
2012-03-04 15:27:02 -05:00
|
|
|
OBJ=ipc.o main.o
|
|
|
|
|
|
|
|
all: migensim.vpi
|
|
|
|
|
|
|
|
%.o: %.c
|
2015-04-14 04:28:56 -04:00
|
|
|
$(CC) $(CFLAGS) $(VPI_CFLAGS) -c $(INCDIRS) -o $@ $<
|
2012-03-04 15:27:02 -05:00
|
|
|
|
|
|
|
migensim.vpi: $(OBJ)
|
2015-04-14 04:28:56 -04:00
|
|
|
iverilog-vpi --name=migensim $^
|
2012-03-04 15:27:02 -05:00
|
|
|
|
2012-03-06 09:51:09 -05:00
|
|
|
install: migensim.vpi
|
|
|
|
install -m755 -t $(INSTDIR) $^
|
|
|
|
|
2012-03-04 15:27:02 -05:00
|
|
|
clean:
|
|
|
|
rm -f $(OBJ)
|
|
|
|
rm -f migensim.vpi
|
|
|
|
|
2012-03-06 09:51:09 -05:00
|
|
|
.PHONY: install clean
|