# gramscii - simple editor for ASCII box-and-arrow charts .POSIX: include config.mk SRC = main.c draw.c screen.c files.c lineset.c INC = config.h gramscii.h arg.h DISTFILES = ${SRC} ${INC} Makefile config.mk README.md Changelog all: options gramscii options: @echo "-+- build options -+-" @echo "PREFIX = ${PREFIX}" @echo "CFLAGS = ${CFLAGS}" @echo "LDFLAGS = ${LDFLAGS}" @echo "CC = ${CC}" @echo "-+-+-+-+-+-+-+-+-+-+-" gramscii: ${SRC} ${INC} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ ${SRC} clean: @echo cleaning @rm -f gramscii install: all @echo installing executable to ${DESTDIR}${BINDIR} @mkdir -p "${DESTDIR}${BINDIR}" @cp -f gramscii "${DESTDIR}${BINDIR}" @chmod 755 "${DESTDIR}${BINDIR}/gramscii" @echo installing manpage to "${DESTDIR}${MANDIR}/man1" @mkdir -p "${DESTDIR}${MANDIR}/man1" @cp -f gramscii.1 "${DESTDIR}${MANDIR}/man1" @chmod 644 "${DESTDIR}${MANDIR}/man1/gramscii.1" uninstall: @echo removing executable file from ${DESTDIR}${BINDIR} @rm -f "${DESTDIR}${BINDIR}/gramscii" @echo removing manpage from "${DESTDIR}${MANDIR}/man1" @rm -f "${DESTDIR}${MANDIR}/man1/gramscii.1" dist: clean @echo "making a tarball" @mkdir -p ./gramscii-${VERSION} @rm -rf ./gramscii-${VERSION}/* @cp -R ${DISTFILES} ./gramscii-${VERSION}/ @tar -cf gramscii-${VERSION}.tar ./gramscii-${VERSION} @gzip gramscii-${VERSION}.tar @rm -rf gramscii-${VERSION}