acst

Tracks changes and corruption in files using xattr-based checksums.
git clone https://noxz.tech/git/acst.git
acst

Makefile
1.POSIX:
2
3include config.mk
4
5SRC = acst.c sha256.c
6OBJ = ${SRC:.c=.o}
7
8all: options acst
9
10options:
11	@echo build options:
12	@echo "CFLAGS  = ${CFLAGS}"
13	@echo "CC      = ${CC}"
14
15.c.o:
16	${CC} ${CFLAGS} -c $<
17
18${OBJ}: config.mk
19
20acst: ${OBJ}
21	${CC} -o $@ ${OBJ}
22
23clean:
24	rm -f acst ${OBJ}
25
26install: all
27	mkdir -v -p ${DESTDIR}${PREFIX}/bin
28	cp -v acst ${DESTDIR}${PREFIX}/bin
29	chmod 755 ${DESTDIR}${PREFIX}/bin/acst
30	mkdir -v -p ${DESTDIR}${MANPREFIX}/man1
31	sed "s/VERSION/${VERSION}/g" < acst.1 > ${DESTDIR}${MANPREFIX}/man1/acst.1
32	chmod 644 ${DESTDIR}${MANPREFIX}/man1/acst.1
33
34uninstall:
35	rm -f ${DESTDIR}${PREFIX}/bin/acst
36	rm -f ${DESTDIR}${MANPREFIX}/man1/acst.1
37
38test: acst
39	@./test
40
41.PHONY: all install clean test