diff options
author | Arvind Sankar <[email protected]> | 2020-07-11 19:35:58 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2020-07-14 17:33:44 -0700 |
commit | 38e2e9ce8327284b2d516874308300aa96102fe9 (patch) | |
tree | 0761f7f696e4da7888a0c99ffb3a91a63ecefdd4 /contrib/dracut | |
parent | bdb518c13abb9eca8d6f8f1d9e2096dc5163a9e7 (diff) |
Centralize variable substitution
A bunch of places need to edit files to incorporate the configured paths
i.e. bindir, sbindir etc. Move this logic into a common file.
Create arc_summary by copying arc_summary[23] as appropriate at build
time instead of install time.
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Arvind Sankar <[email protected]>
Closes #10559
Diffstat (limited to 'contrib/dracut')
-rw-r--r-- | contrib/dracut/02zfsexpandknowledge/Makefile.am | 17 | ||||
-rw-r--r-- | contrib/dracut/90zfs/Makefile.am | 27 |
2 files changed, 6 insertions, 38 deletions
diff --git a/contrib/dracut/02zfsexpandknowledge/Makefile.am b/contrib/dracut/02zfsexpandknowledge/Makefile.am index 11f2a84af..d31d389a0 100644 --- a/contrib/dracut/02zfsexpandknowledge/Makefile.am +++ b/contrib/dracut/02zfsexpandknowledge/Makefile.am @@ -1,18 +1,7 @@ +include $(top_srcdir)/config/Substfiles.am + pkgdracutdir = $(dracutdir)/modules.d/02zfsexpandknowledge pkgdracut_SCRIPTS = \ module-setup.sh -EXTRA_DIST = \ - module-setup.sh.in - -$(pkgdracut_SCRIPTS):%:%.in - -$(SED) -e 's,@bindir\@,$(bindir),g' \ - -e 's,@sbindir\@,$(sbindir),g' \ - -e 's,@datadir\@,$(datadir),g' \ - -e 's,@dracutdir\@,$(dracutdir),g' \ - -e 's,@udevdir\@,$(udevdir),g' \ - -e 's,@udevruledir\@,$(udevruledir),g' \ - -e 's,@sysconfdir\@,$(sysconfdir),g' \ - $< >'$@' - -CLEANFILES = $(pkgdracut_SCRIPTS) +SUBSTFILES += $(pkgdracut_SCRIPTS) diff --git a/contrib/dracut/90zfs/Makefile.am b/contrib/dracut/90zfs/Makefile.am index 645808e44..a4843827e 100644 --- a/contrib/dracut/90zfs/Makefile.am +++ b/contrib/dracut/90zfs/Makefile.am @@ -1,3 +1,5 @@ +include $(top_srcdir)/config/Substfiles.am + pkgdracutdir = $(dracutdir)/modules.d/90zfs pkgdracut_SCRIPTS = \ export-zfs.sh \ @@ -14,27 +16,4 @@ pkgdracut_DATA = \ zfs-snapshot-bootfs.service \ zfs-rollback-bootfs.service -EXTRA_DIST = \ - export-zfs.sh.in \ - module-setup.sh.in \ - mount-zfs.sh.in \ - parse-zfs.sh.in \ - zfs-generator.sh.in \ - zfs-load-key.sh.in \ - zfs-needshutdown.sh.in \ - zfs-lib.sh.in \ - zfs-env-bootfs.service.in \ - zfs-snapshot-bootfs.service.in \ - zfs-rollback-bootfs.service.in - -$(pkgdracut_SCRIPTS) $(pkgdracut_DATA) :%:%.in - -$(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,@systemdunitdir\@,$(systemdunitdir),g' \ - -e 's,@mounthelperdir\@,$(mounthelperdir),g' \ - $< >'$@' - -CLEANFILES = $(pkgdracut_SCRIPTS) $(pkgdracut_DATA) +SUBSTFILES += $(pkgdracut_SCRIPTS) $(pkgdracut_DATA) |