]> arthur.barton.de Git - netdata.git/blobdiff - build/subst.inc
build: generate proper systemd service file
[netdata.git] / build / subst.inc
diff --git a/build/subst.inc b/build/subst.inc
new file mode 100644 (file)
index 0000000..18743ab
--- /dev/null
@@ -0,0 +1,10 @@
+.in:
+       if sed \
+               -e 's#[@]localstatedir_POST@#$(localstatedir)#g' \
+               -e 's#[@]sbindir_POST@#$(sbindir)#g' \
+               $< > $@.tmp; then \
+               mv "$@.tmp" "$@"; \
+       else \
+               rm -f "$@.tmp"; \
+               false; \
+       fi