X-Git-Url: http://pileus.org/git/?p=lackey;a=blobdiff_plain;f=makefile;h=ce82c84d434401e28ec17441bdcaafe6733bb5ff;hp=ec91b830da4a2d8d1e50e99f47a53a7bd851aa82;hb=d45541aeb31a0e34a2a43df0e112f1f720f80abf;hpb=a8c24ecfdee86b9ea9c35469f717fa3cf1b9b6ab diff --git a/makefile b/makefile index ec91b83..ce82c84 100644 --- a/makefile +++ b/makefile @@ -1,5 +1,5 @@ # lackey - curses calendar program -# See COPYING file for copyright and license details. +# See COPYING file for license details. -include config.mk @@ -11,19 +11,19 @@ MANPREFIX ?= $(PREFIX)/share/man # Compiler GCC ?= gcc CFLAGS ?= -Wall --std=c99 -CPPFLAGS ?= -Isrc LDFLAGS ?= -lncursesw -lical # Sources PROG ?= lackey -PROG_SRC ?= main view date cal util +PROG_SRC ?= main util args conf date cal view print daemon TEST ?= test -TEST_SRC ?= test date cal util -VIEWS ?= day week month year events todo settings help +TEST_SRC ?= test util conf date cal daemon +VIEWS ?= day week month year events todo settings help edit CALS ?= dummy ical -# For ncursesw -CPPFLAGS += $(strip $(shell pkg-config --cflags ncursesw)) +# Objects +views/%.o cals/%.o: CFLAGS += -Isrc +src/view.o views/%.o: CFLAGS += $(strip $(shell pkg-config --cflags ncursesw)) # Targets all: $(PROG) @@ -57,7 +57,7 @@ $(PROG): $(PROG_SRC:%=src/%.o) $(VIEWS:%=views/%.o) $(CALS:%=cals/%.o) $(TEST): $(TEST_SRC:%=src/%.o) $(CALS:%=cals/%.o) $(GCC) $(CFLAGS) -o $@ $+ $(LDFLAGS) -%.o: %.c $(wildcard src/*.h) makefile - $(GCC) $(CFLAGS) $(CPPFLAGS) -c -o $@ $< +%.o: %.c $(wildcard src/*.h makefile config.mk) + $(GCC) $(CFLAGS) -c -o $@ $< .PHONY: all clean dist install uninstall