mirror of
https://gitlab.com/shorewall/code.git
synced 2024-11-22 15:43:30 +01:00
daa016d2a3
Signed-off-by: Tuomo Soini <tis@foobar.fi>
24 lines
468 B
Makefile
24 lines
468 B
Makefile
#
|
|
# Shorewall6 -- /etc/shorewall6/Makefile
|
|
#
|
|
# Reload Shorewall6 if config files are updated.
|
|
|
|
SWBIN ?= /sbin/shorewall6 -q
|
|
CONFDIR ?= /etc/shorewall6
|
|
SWSTATE ?= $(shell $(SWBIN) show vardir)/firewall
|
|
|
|
.PHONY: clean
|
|
|
|
$(SWSTATE): $(CONFDIR)/*
|
|
@$(SWBIN) save >/dev/null; \
|
|
RESULT=$$($(SWBIN) reload 2>&1); \
|
|
if [ $$? -eq 0 ]; then \
|
|
$(SWBIN) save >/dev/null; \
|
|
else \
|
|
echo "$${RESULT}" >&2; \
|
|
false; \
|
|
fi
|
|
|
|
clean:
|
|
@rm -f $(CONFDIR)/*~ $(CONFDIR)/.*~
|