aboutsummaryrefslogtreecommitdiffstats
path: root/etc/init.d/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'etc/init.d/Makefile.am')
-rw-r--r--etc/init.d/Makefile.am39
1 files changed, 4 insertions, 35 deletions
diff --git a/etc/init.d/Makefile.am b/etc/init.d/Makefile.am
index f97459803..9285a995a 100644
--- a/etc/init.d/Makefile.am
+++ b/etc/init.d/Makefile.am
@@ -1,38 +1,7 @@
-initdir = $(DEFAULT_INIT_DIR)
-init_SCRIPTS = zfs-import zfs-mount zfs-share zfs-zed
-
-initconfdir = $(DEFAULT_INITCONF_DIR)
+include $(top_srcdir)/config/Substfiles.am
-EXTRA_DIST = \
- zfs-share.in \
- zfs-import.in \
- zfs-mount.in \
- zfs-zed.in \
- README.md
+EXTRA_DIST += README.md
-$(init_SCRIPTS):%:%.in Makefile
- -(if [ -e /etc/debian_version ]; then \
- NFS_SRV=nfs-kernel-server; \
- else \
- NFS_SRV=nfs; \
- fi; \
- if [ -e /sbin/openrc-run ]; then \
- SHELL=/sbin/openrc-run; \
- else \
- SHELL=/bin/sh; \
- fi; \
- $(SED) \
- -e 's,@bindir\@,$(bindir),g' \
- -e 's,@sbindir\@,$(sbindir),g' \
- -e 's,@udevdir\@,$(udevdir),g' \
- -e 's,@udevruledir\@,$(udevruledir),g' \
- -e 's,@sysconfdir\@,$(sysconfdir),g' \
- -e 's,@initconfdir\@,$(initconfdir),g' \
- -e 's,@initdir\@,$(initdir),g' \
- -e 's,@runstatedir\@,$(runstatedir),g' \
- -e "s,@SHELL\@,$$SHELL,g" \
- -e "s,@NFS_SRV\@,$$NFS_SRV,g" \
- $< >'$@'; \
- chmod +x '$@')
+init_SCRIPTS = zfs-import zfs-mount zfs-share zfs-zed
-CLEANFILES = $(init_SCRIPTS)
+SUBSTFILES += $(init_SCRIPTS)