CFLAGS+=-Wall -Wextra -pedantic -Os LDFLAGS+=-s PREFIX?=/usr/local jaildaemon: jaildaemon.c $(CC) -o $@ $< $(CFLAGS) $(LDFLAGS) install: jaildaemon install -o 0 -g 0 -m 0755 jaildaemon $(PREFIX)/bin install -o 0 -g 0 -m 0755 rc.d-jaildaemon $(PREFIX)/etc/rc.d/jaildaemon .PHONY: clean test clean: rm -f jaildaemon test: jaildaemon sudo sh ./jaildaemon.sh