dsys2
annotate Makefile @ 0:34d90cd9ef9b
starting a new demosystem
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Sat, 20 Aug 2011 07:48:16 +0300 |
parents | |
children | 1705e550bd91 |
rev | line source |
---|---|
nuclear@0 | 1 src = $(wildcard src/*.c) |
nuclear@0 | 2 obj = $(src:.c=.o) |
nuclear@0 | 3 dep = $(obj:.o=.d) |
nuclear@0 | 4 |
nuclear@0 | 5 lib_a = libdsys2.a |
nuclear@0 | 6 |
nuclear@0 | 7 CC = gcc |
nuclear@0 | 8 AR = ar |
nuclear@0 | 9 CFLAGS = -pedantic -Wall -g |
nuclear@0 | 10 |
nuclear@0 | 11 $(lib_a): $(obj) |
nuclear@0 | 12 $(AR) rcs $@ $(obj) |
nuclear@0 | 13 |
nuclear@0 | 14 -include $(dep) |
nuclear@0 | 15 |
nuclear@0 | 16 %.d: %.c |
nuclear@0 | 17 @$(CPP) $(CFLAGS) -MM -MT $(@:.d=.o) $< >$@ |
nuclear@0 | 18 |
nuclear@0 | 19 .PHONY: clean |
nuclear@0 | 20 clean: |
nuclear@0 | 21 rm -f $(obj) $(bin) |
nuclear@0 | 22 |
nuclear@0 | 23 .PHONY: cleandep |
nuclear@0 | 24 cleandep: |
nuclear@0 | 25 rm -f $(dep) |