File: Makefile

package info (click to toggle)
openvpn-systemd-resolved 1.3.0-5
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 308 kB
  • sloc: sh: 706; makefile: 35
file content (36 lines) | stat: -rw-r--r-- 1,079 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
PREFIX ?= /etc/openvpn/scripts

SRC = update-systemd-resolved
DEST = $(DESTDIR)$(PREFIX)/$(SRC)

.PHONY: all install info

all: install info

install:
	@install -Dm750 $(SRC) $(DEST)
	@install -Dm644 $(SRC).conf $(DEST).conf

info:
	@printf 'Successfully installed %s to %s.\n' $(SRC) $(DEST)
	@echo
	@echo   'Now would be a good time to update /etc/nsswitch.conf:'
	@echo
	@echo   '  # Use systemd-resolved first, then fall back to /etc/resolv.conf'
	@echo   '  hosts: files resolve dns myhostname'
	@echo   '  # Use /etc/resolv.conf first, then fall back to systemd-resolved'
	@echo   '  hosts: files dns resolve myhostname'
	@echo
	@echo   'You should also update your OpenVPN configuration:'
	@echo
	@printf '  setenv PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin\n'
	@echo   '  script-security 2'
	@printf '  up %s\n' $(DEST)
	@echo   '  up-restart'
	@printf '  down %s\n' $(DEST)
	@echo   '  down-pre'
	@echo
	@printf 'or pass --config %s.conf\n' $(DEST)
	@echo 'in addition to any other --config arguments to your openvpn command.'
test:
	@./run-tests