Mercurial > MadButterfly
diff src/Makefile @ 108:565b55508c8d
More dox
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Fri, 12 Sep 2008 13:58:30 +0800 |
parents | 3645e29e4986 |
children | 1d74eb3861b7 |
line wrap: on
line diff
--- a/src/Makefile Fri Sep 12 12:55:13 2008 +0800 +++ b/src/Makefile Fri Sep 12 13:58:30 2008 +0800 @@ -5,10 +5,28 @@ TESTCASE_OBJS = ${SRCS:C/(.*)\.c/testcase-\1.o/g} CFLAGS+= -Wall -I/usr/local/include `pkg-config --cflags cairo` LDFLAGS = `pkg-config --libs cairo` -BINS = testcase libmbfly.a X_main +BINS = libmbfly.a X_main +PREFIX?=/usr/local/ +HEADERS= X_supp.h animate.h mb.h mb_timer.h mb_types.h \ + observer.h paint.h redraw_man.h shapes.h tools.h +MKDIR?= mkdir -p all: $(BINS) +install: $(BINS) + $(INSTALL) -d ${PREFIX}include/mb +.for i in $(HEADERS) + $(INSTALL) -o root -m 0644 ${i} ${PREFIX}include/mb/ +.endfor + $(INSTALL) -o root libmbfly.a ${PREFIX}lib/ + +uninstall: +.for i in $(HEADERS) + rm -f ${PREFIX}include/mb/${i} +.endfor + rm -f ${PREFIX}lib/libmbfly.a + rmdir ${PREFIX}include/mb/ + testcase: testcase.o $(TESTCASE_OBJS) $(CC) $(LDFLAGS) -o $@ $(.ALLSRC) -L/usr/local/lib -lcunit