瀏覽代碼

Makefile has target "test". Add reference output for test.

master
Ian Piumarta 3 年之前
父節點
當前提交
1bcc24f34f
共有 1 個檔案被更改,包括 5 行新增1 行删除
  1. +5
    -1
      Makefile

+ 5
- 1
Makefile 查看文件

@ -5,6 +5,10 @@ MAIN = ccmeta
all : $(MAIN)
test : all .FORCE
./$(MAIN) < $(MAIN)-test.txt > $(MAIN)-test.out
diff $(MAIN)-test.ref $(MAIN)-test.out
$(MAIN) : $(MAIN).c object.c buffer.h
$(CC) $(CFLAGS) -o $@ $@.c $(LDLIBS)
@ -15,7 +19,7 @@ $(MAIN) : $(MAIN).c object.c buffer.h
mv $@.new $@
tidy : .FORCE
rm -f *~
rm -f *~ $(MAIN)-test.out
clean : .FORCE
rm -f $(MAIN) $(MAIN).c

Loading…
取消
儲存