X-Git-Url: https://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=makefile;h=a0289cbfa0b298233a29fefad9bfac623b782a56;hb=9b560cbf082997fed089cbc24e994f94691fcd28;hp=d6be6c5a2e589ed8a74153be6199128b14957e42;hpb=b3babd5135c8683e68ce97cc76e0ec0487d4ee46;p=apply-default-acl.git diff --git a/makefile b/makefile index d6be6c5..a0289cb 100644 --- a/makefile +++ b/makefile @@ -1,7 +1,8 @@ CC = gcc -CFLAGS = -O2 -march=native -pipe +CFLAGS = -O2 -march=native -pipe -Wall LIBS = -lacl +BIN := reapply_default_acl SOURCES := $(shell find ./src -type f -name '*.c') HEADERS := $(shell find ./src -type f -name '*.h') OBJS := $(patsubst %.c, %.o, $(SOURCES)) @@ -9,9 +10,14 @@ OBJS := $(patsubst %.c, %.o, $(SOURCES)) %.o: %.c $(HEADERS) $(CC) $(CFLAGS) -c -o $@ $< -aclq: $(OBJS) +$(BIN): $(OBJS) $(CC) $(CFLAGS) $(LIBS) -o $@ $^ +.PHONY: clean test + clean: rm -f $(OBJS) - rm -f aclq + rm -f $(BIN) + +test: $(BIN) + ./run-tests.sh