gre-on-wg/Makefile

15 lines
437 B
Makefile

SCRIPT := gre-on-wg.sh
SCRIPT_NAME := $(SCRIPT:.sh=)
PREFIX ?= /usr/local
PREFIX_UNIT ?= /etc
install: install-bin install-unit
install-bin: $(SCRIPT)
install -D -m 0755 -o root -g root -T $< $(PREFIX)/bin/$(SCRIPT_NAME)
install-unit: gre-on-wg.target gre-on-wg@.service
install -D -m 0644 -o root -g root $^ $(PREFIX_UNIT)/systemd/system
install -m 0755 -o root -g root -d /etc/gre-on-wg
.PHONY: install install-bin install-unit