mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-24 11:18:52 +03:00
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 <behlendorf1@llnl.gov> Signed-off-by: Arvind Sankar <nivedita@alum.mit.edu> Closes #10559
This commit is contained in:
committed by
Brian Behlendorf
parent
bdb518c13a
commit
38e2e9ce83
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -1,20 +1,9 @@
|
||||
include $(top_srcdir)/config/Substfiles.am
|
||||
|
||||
hooksdir = /usr/share/initramfs-tools/hooks
|
||||
|
||||
hooks_SCRIPTS = \
|
||||
zfs \
|
||||
zfsunlock
|
||||
|
||||
EXTRA_DIST = \
|
||||
zfs.in \
|
||||
zfsunlock.in
|
||||
|
||||
$(hooks_SCRIPTS):%:%.in Makefile
|
||||
-$(SED) -e 's,@sbindir\@,$(sbindir),g' \
|
||||
-e 's,@sysconfdir\@,$(sysconfdir),g' \
|
||||
-e 's,@udevdir\@,$(udevdir),g' \
|
||||
-e 's,@udevruledir\@,$(udevruledir),g' \
|
||||
-e 's,@mounthelperdir\@,$(mounthelperdir),g' \
|
||||
-e 's,@DEFAULT_INITCONF_DIR\@,$(DEFAULT_INITCONF_DIR),g' \
|
||||
$< >'$@'
|
||||
|
||||
CLEANFILES = $(hooks_SCRIPTS)
|
||||
SUBSTFILES += $(hooks_SCRIPTS)
|
||||
|
||||
@@ -12,7 +12,7 @@ COPY_EXEC_LIST="@sbindir@/zdb @sbindir@/zpool @sbindir@/zfs"
|
||||
COPY_EXEC_LIST="$COPY_EXEC_LIST @mounthelperdir@/mount.zfs @udevdir@/vdev_id"
|
||||
COPY_EXEC_LIST="$COPY_EXEC_LIST @udevdir@/zvol_id"
|
||||
COPY_FILE_LIST="/etc/hostid @sysconfdir@/zfs/zpool.cache"
|
||||
COPY_FILE_LIST="$COPY_FILE_LIST @DEFAULT_INITCONF_DIR@/zfs"
|
||||
COPY_FILE_LIST="$COPY_FILE_LIST @initconfdir@/zfs"
|
||||
COPY_FILE_LIST="$COPY_FILE_LIST @sysconfdir@/zfs/zfs-functions"
|
||||
COPY_FILE_LIST="$COPY_FILE_LIST @sysconfdir@/zfs/vdev_id.conf"
|
||||
COPY_FILE_LIST="$COPY_FILE_LIST @udevruledir@/60-zvol.rules"
|
||||
|
||||
Reference in New Issue
Block a user