You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

44 lines
1.0 KiB

PREFIX ?= /usr/local
MANPREFIX ?= ${PREFIX}/man
RELEASE = 5.0
CPPFLAGS += -DRELEASE=\"${RELEASE}\"
all: versioncheck entr
test: entr_spec entr
@echo "Running unit tests"
@./entr_spec
gcc-lint: clean
@CPPFLAGS="-std=c89 -pedantic -Wall -Wpointer-arith -Wbad-function-cast" make test
regress:
@echo "Running functional tests"
@./system_test.sh
entr: entr.c ${EXTRA_SRC}
${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} ${EXTRA_SRC} entr.c -o $@
entr_spec: entr_spec.c entr.c ${EXTRA_SRC}
${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} ${EXTRA_SRC} entr_spec.c -o $@
clean:
rm -f entr entr_spec *.o
distclean: clean
rm -f Makefile
install: entr
@mkdir -p ${DESTDIR}${PREFIX}/bin
@mkdir -p ${DESTDIR}${MANPREFIX}/man1
install entr ${DESTDIR}${PREFIX}/bin
install -m 644 entr.1 ${DESTDIR}${MANPREFIX}/man1
uninstall:
rm ${DESTDIR}${PREFIX}/bin/entr
rm ${DESTDIR}${MANPREFIX}/man1/entr.1
versioncheck:
@head -n3 NEWS | egrep -q "^= Next Release: ${RELEASE}|^== ${RELEASE}: "
.PHONY: all test gcc-lint regress clean distclean install uninstall versioncheck