aewl

annotate Makefile @ 11:ea9c08ec4b48

added gridsel to gridwm
author Anselm R. Garbe <garbeam@wmii.de>
date Tue, 11 Jul 2006 13:21:57 +0200
parents 7066ff2fe8bc
children 00d4d52b231f
rev   line source
garbeam@0 1 # gridwm - grid window manager
garbeam@0 2 # (C)opyright MMVI Anselm R. Garbe
garbeam@0 3
garbeam@0 4 include config.mk
garbeam@0 5
garbeam@8 6 WMSRC = bar.c client.c cmd.c draw.c event.c key.c util.c wm.c
garbeam@2 7 WMOBJ = ${WMSRC:.c=.o}
garbeam@4 8 MENSRC = menu.c draw.c util.c
garbeam@3 9 MENOBJ = ${MENSRC:.c=.o}
garbeam@11 10 SELSRC = gridsel.c util.c
garbeam@11 11 SELOBJ = ${SELSRC:.c=.o}
garbeam@5 12 MAN1 = gridwm.1 gridmenu.1
garbeam@11 13 BIN = gridwm gridmenu gridsel
garbeam@0 14
garbeam@11 15 all: config gridwm gridmenu gridsel
garbeam@0 16 @echo finished
garbeam@0 17
garbeam@1 18 config:
garbeam@1 19 @echo gridwm build options:
garbeam@1 20 @echo "LIBS = ${LIBS}"
garbeam@1 21 @echo "CFLAGS = ${CFLAGS}"
garbeam@1 22 @echo "LDFLAGS = ${LDFLAGS}"
garbeam@1 23 @echo "CC = ${CC}"
garbeam@1 24
garbeam@0 25 .c.o:
garbeam@0 26 @echo CC $<
garbeam@0 27 @${CC} -c ${CFLAGS} $<
garbeam@0 28
garbeam@3 29 ${WMOBJ}: wm.h draw.h config.h util.h
garbeam@3 30
garbeam@3 31 gridmenu: ${MENOBJ}
garbeam@3 32 @echo LD $@
garbeam@3 33 @${CC} -o $@ ${MENOBJ} ${LDFLAGS}
garbeam@0 34
garbeam@2 35 gridwm: ${WMOBJ}
garbeam@0 36 @echo LD $@
garbeam@2 37 @${CC} -o $@ ${WMOBJ} ${LDFLAGS}
garbeam@0 38
garbeam@11 39 gridsel: ${SELOBJ}
garbeam@11 40 @echo LD $@
garbeam@11 41 @${CC} -o $@ ${SELOBJ} ${LDFLAGS}
garbeam@11 42
garbeam@0 43 clean:
garbeam@3 44 rm -f gridwm gridmenu *.o core
garbeam@1 45
garbeam@1 46 dist: clean
garbeam@1 47 mkdir -p gridwm-${VERSION}
garbeam@3 48 cp -R Makefile README LICENSE config.mk *.h *.c ${MAN} gridwm-${VERSION}
garbeam@1 49 tar -cf gridwm-${VERSION}.tar gridwm-${VERSION}
garbeam@1 50 gzip gridwm-${VERSION}.tar
garbeam@1 51 rm -rf gridwm-${VERSION}
garbeam@1 52
garbeam@1 53 install: all
garbeam@1 54 @mkdir -p ${DESTDIR}${PREFIX}/bin
garbeam@1 55 @cp -f ${BIN} ${DESTDIR}${PREFIX}/bin
garbeam@1 56 @echo installed executable files to ${DESTDIR}${PREFIX}/bin
garbeam@1 57 @mkdir -p ${DESTDIR}${MANPREFIX}/man1
garbeam@1 58 @cp -f ${MAN1} ${DESTDIR}${MANPREFIX}/man1
garbeam@1 59 @echo installed manual pages to ${DESTDIR}${MANPREFIX}/man1
garbeam@1 60
garbeam@1 61 uninstall:
garbeam@1 62 for i in ${BIN}; do \
garbeam@1 63 rm -f ${DESTDIR}${PREFIX}/bin/`basename $$i`; \
garbeam@1 64 done
garbeam@1 65 for i in ${MAN1}; do \
garbeam@1 66 rm -f ${DESTDIR}${MANPREFIX}/man1/`basename $$i`; \
garbeam@1 67 done