doorbell

annotate doorbelld/Makefile @ 5:f21ae31ef0e7

craptacular
author John Tsiombikas <nuclear@member.fsf.org>
date Tue, 15 Mar 2016 08:35:21 +0200
parents d3f2a2b19504
children
rev   line source
nuclear@2 1 src = $(wildcard src/*.c)
nuclear@2 2 obj = $(src:.c=.o)
nuclear@2 3 bin = doorbelld
nuclear@2 4
nuclear@2 5 CFLAGS = -pedantic -Wall -g
nuclear@2 6 LDFLAGS = -lwcam -lpthread
nuclear@2 7
nuclear@5 8 .PHONY: all
nuclear@5 9 all: .clang_complete $(bin)
nuclear@5 10
nuclear@2 11 $(bin): $(obj)
nuclear@2 12 $(CC) -o $@ $(obj) $(LDFLAGS)
nuclear@2 13
nuclear@5 14 .clang_complete:
nuclear@5 15 echo '-x c' >$@
nuclear@5 16 for i in $(CFLAGS); do echo $$i >>$@; done
nuclear@5 17
nuclear@2 18 .PHONY: clean
nuclear@2 19 clean:
nuclear@2 20 rm -f $(obj) $(bin)