Makefile (450B)
1 CPPFLAGS = -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=700L 2 CFLAGS = -std=c99 -pedantic -Wall -Os 3 4 SRC = thy.c 5 OBJ = ${SRC:.c=.o} 6 7 all: thy 8 9 .c.o: 10 ${CC} -c ${CPPFLAGS} ${CFLAGS} $< 11 12 thy: ${OBJ} 13 ${CC} -o $@ ${OBJ} ${LDFLAGS} 14 15 clean: 16 rm -f thy ${OBJ} 17 18 install: all 19 mkdir -p ${DESTDIR}${PREFIX}/bin 20 cp -f thy ${DESTDIR}${PREFIX}/bin 21 chmod 755 ${DESTDIR}${PREFIX}/bin/thy 22 23 uninstall: 24 rm -f ${DESTDIR}${PREFIX}/bin/thy 25 26 .PHONY: all clean install uninstall