Better cleanup rule.

This commit is contained in:
Ian Gulliver
2016-02-27 22:55:48 -08:00
parent 98c1a5c458
commit 9e591904ac

View File

@@ -18,7 +18,7 @@ OBJ_PROTO = adsb.pb-c.o
all: adsbus all: adsbus
clean: clean:
rm -rf *.o adsbus testout rm -rf *.o adsbus testout findings
%.o: %.c *.h %.o: %.c *.h
$(COMP) -c $(CFLAGS) $< -o $@ $(COMP) -c $(CFLAGS) $< -o $@
@@ -30,7 +30,8 @@ adsbus: adsbus.o $(OBJ_NETWORK) $(OBJ_PROTOCOL) $(OBJ_UTIL) $(OBJ_PROTO)
$(COMP) $(LDFLAGS) -o adsbus adsbus.o $(OBJ_NETWORK) $(OBJ_PROTOCOL) $(OBJ_UTIL) $(OBJ_PROTO) $(LIBS) $(COMP) $(LDFLAGS) -o adsbus adsbus.o $(OBJ_NETWORK) $(OBJ_PROTOCOL) $(OBJ_UTIL) $(OBJ_PROTO) $(LIBS)
fuzz: fuzz:
test -d findings || mkdir findings rm -rf findings
mkdir findings
$(MAKE) clean $(MAKE) clean
COMP=afl-clang $(MAKE) adsbus COMP=afl-clang $(MAKE) adsbus
afl-fuzz -i testcase/ -o findings/ ./adsbus --stdin --stdout=airspy_adsb --stdout=beast --stdout=json --stdout=proto --stdout=raw --stdout=stats afl-fuzz -i testcase/ -o findings/ ./adsbus --stdin --stdout=airspy_adsb --stdout=beast --stdout=json --stdout=proto --stdout=raw --stdout=stats