From b2e39e7146608d5b600127de9a3b2448f13f6218 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Sat, 6 Feb 2016 15:33:41 -0500 Subject: Stuff --- Makefile | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index a740bd1..dad9c4a 100644 --- a/Makefile +++ b/Makefile @@ -4,6 +4,8 @@ prefix = /usr/local bindir = $(prefix)/bin systemddir = $(prefix)/lib/systemd/system +sysconfdir = $(prefix)/etc +pkgconfdir = $(sysconfdir)/httpconnectd DESTDIR = Q = @ @@ -11,19 +13,20 @@ Q = @ MAKEFLAGS += -r vars = $(patsubst .var.%,%,$(filter .var.%,$^)) -build_targets = httpconnectd httpconnectd@.service httpconnectd.socket -install_targets = $(DESTDIR)$(bindir)/httpconnectd $(DESTDIR)$(systemddir)/httpconnectd@.service $(DESTDIR)$(systemddir)/httpconnectd.socket +build_targets = httpconnectd httpconnectd@.service httpconnectd.socket basicauth.conf-sample +install_targets = $(DESTDIR)$(bindir)/httpconnectd $(DESTDIR)$(systemddir)/httpconnectd@.service $(DESTDIR)$(systemddir)/httpconnectd.socket $(DESTDIR)$(pkgconfdir)/basicauth.conf-sample all: $(build_targets) install: $(install_targets) clean: - rm -f -- httpconnectd httpconnectd@.service + rm -f -- httpconnectd httpconnectd.sh httpconnectd@.service uninstall: rm -f -- $(install_targets) rmdir -p -- $(dir $(install_targets)) .PHONY: all install clean uninstall httpconnectd@.service: .var.bindir +httpconnectd.sh: .var.pkgconfdir ######################################################################## @@ -37,6 +40,8 @@ $(DESTDIR)$(bindir)/%: % install -Dm755 $< $@ $(DESTDIR)$(systemddir)/%: % install -Dm644 $< $@ +$(DESTDIR)$(pkgconfdir)/%: % + install -Dm644 $< $@ .var.%: FORCE $(Q)printf '%s' '$($*)' > .tmp$@ && { cmp -s .tmp$@ $@ && rm -f -- .tmp$@ || mv -Tf .tmp$@ $@; } || { rm -f -- .tmp$@; false; } -- cgit v1.2.3-2-g168b