get-otp/makefile

23 lines
501 B
Makefile
Raw Normal View History

2020-10-08 16:14:27 -05:00
EXE = cbc-file
2020-10-08 22:10:17 -05:00
LDLIBS = -lbearssl -largon2
OPT = -O2
CFLAGS = -std=c99 $(OPT) -Wall -Wextra -Werror=implicit -pedantic
2020-10-08 16:14:27 -05:00
2020-10-08 22:25:20 -05:00
SCRIPT = get-otp encrypt-otp
2020-10-08 16:14:27 -05:00
all: $(EXE) $(SCRIPT)
2020-10-08 22:25:20 -05:00
get-otp: get-otp.in
encrypt-otp: encrypt-otp.in
%: %.in
2020-10-08 16:14:27 -05:00
sed -e 's|@PREFIX@|$(PREFIX)|' $^ > $@
install: all
mkdir -p $(DESTDIR)$(PREFIX)/bin
install -Dm755 cbc-file $(DESTDIR)$(PREFIX)/bin/
2020-10-08 16:14:27 -05:00
install -Dm755 get-otp $(DESTDIR)$(PREFIX)/bin/
2020-10-08 22:25:20 -05:00
install -Dm755 encrypt-otp $(DESTDIR)$(PREFIX)/bin/
clean:
rm -f $(EXE) $(SCRIPT)