diff --git a/Makefile b/Makefile index 95b14a4..cf44a10 100644 --- a/Makefile +++ b/Makefile @@ -13,21 +13,21 @@ all: .PHONY: install install: sysreport # Make destination directories if needed - $(shell [ ! -d $(destconf) ] && mkdir -p $(destconf)) - $(shell [ ! -d $(destbin) ] && mkdir -p $(destbin)) - $(shell [ ! -d $(destman) ] && mkdir -p $(destman)) + $(shell [ ! -d "$(destconf)" ] && mkdir -p "$(destconf)") + $(shell [ ! -d "$(destbin)" ] && mkdir -p "$(destbin)") + $(shell [ ! -d "$(destman)" ] && mkdir -p "$(destman)") - install sysreport $(destbin) + install sysreport "$(destbin)" # Install and setup configuration file - install -m644 -T sysreporter.conf.sample $(destconf)/sysreporter.conf - @echo "export REPORTSDIR=\"$(confdir)/reports.d\"" >> $(destconf)/sysreporter.conf - @echo "export TEMPDIR=\"/tmp/sysreporter\"" >> $(destconf)/sysreporter.conf + install -m644 -T sysreporter.conf.sample "$(destconf)/sysreporter.conf" + @echo "export REPORTSDIR=\"$(confdir)/reports.d\"" >> "$(destconf)/sysreporter.conf" + @echo "export TEMPDIR=\"/tmp/sysreporter\"" >> "$(destconf)/sysreporter.conf" # Install and enable default reports - install -d $(destreportsdir) - install -m644 -D reports.d/* $(destreportsdir) - chmod +x $(destreportsdir)/3* + install -d "$(destreportsdir)" + install -m644 -D reports.d/* "$(destreportsdir)" + install -D reports.d/3* "$(destreportsdir)" # Install manpage - install -m644 sysreport.1 $(destman) + install -m644 sysreport.1 "$(destman)"