baum
view Makefile @ 10:0e15841ae111
s/list/stack/g because thats what it is
author | meillo@marmaro.de |
---|---|
date | Sat, 09 Feb 2008 16:49:29 +0100 |
parents | 2f71d692d4f9 |
children | 3c64b5ac821b |
line source
1 # common makefile
3 # program
4 PROGRAM = baum
5 SRC = baum.c actions.c
6 OBJ = ${SRC:.c=.o}
7 DEP = baum.h actions.h
9 # compile env
10 CC = gcc
11 LD = ${CC}
12 DEBUG = -g
13 CFLAGS = -Wall -c ${DEBUG}
14 LFLAGS = -Wall ${DEBUG}
16 ####
18 all: options ${PROGRAM}
20 options:
21 @echo build options:
22 @echo "CC = ${CC}"
23 @echo "LD = ${LD}"
24 @echo "CFLAGS = ${CFLAGS}"
25 @echo "LFLAGS = ${LFLAGS}"
26 @echo
28 .cpp.o:
29 $(CC) $(CFLAGS) $<
31 ${OBJ}: ${DEP}
33 ${PROGRAM}: ${OBJ}
34 $(LD) $(LFLAGS) ${OBJ} -o $@
36 debug: all
37 gdb ${PROGRAM}
39 strip: ${PROGRAM}
40 @echo stripping ${PROGRAM}
41 @strip ${PROGRAM}
43 tar: clean
44 @echo creating archive
45 @tar -czvf ${PROGRAM}.tar.gz *
47 clean:
48 @echo cleaning
49 @rm -f ${PROGRAM} ${OBJ}
51 .PHONY: all options debug strip tar clean