aboutsummaryrefslogtreecommitdiffstats
path: root/tests/zfs-tests/include
diff options
context:
space:
mode:
authorAntonio Russo <[email protected]>2018-06-07 12:59:59 -0400
committerBrian Behlendorf <[email protected]>2018-06-07 09:59:59 -0700
commit39042f97365c0e677e5e77ded90372526422afdf (patch)
treefeaf6e681cc3b9bd677bfd442b4e54e14c1b8a33 /tests/zfs-tests/include
parentfba33c3819761487a75c8f1307482959105a6269 (diff)
Tunable directory for zfs runtime scripts
zpool and zed place scripts in subdirectories of libexecdir. Some distributions locate architecture independent scripts in other locations (e.g. Debian). To avoid these paths getting out of sync, centralize the definitions. Build zfs-test's default.cfg by Makefile. Use the new directory logic building tests/zfs-tests/include/default.cfg.in. Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Antonio Russo <[email protected]> Closes #7597
Diffstat (limited to 'tests/zfs-tests/include')
-rw-r--r--tests/zfs-tests/include/Makefile.am10
-rw-r--r--tests/zfs-tests/include/default.cfg.in4
2 files changed, 9 insertions, 5 deletions
diff --git a/tests/zfs-tests/include/Makefile.am b/tests/zfs-tests/include/Makefile.am
index 52e1c0a9f..41e105287 100644
--- a/tests/zfs-tests/include/Makefile.am
+++ b/tests/zfs-tests/include/Makefile.am
@@ -2,13 +2,19 @@ pkgdatadir = $(datadir)/@PACKAGE@/zfs-tests/include
dist_pkgdata_DATA = \
blkdev.shlib \
commands.cfg \
- default.cfg \
libtest.shlib \
math.shlib \
properties.shlib \
zpool_script.shlib
-EXTRA_DIST=default.cfg.in
+EXTRA_DIST = default.cfg.in
+
+nodist_pkgdata_DATA = default.cfg
+
+$(nodist_pkgdata_DATA): %: %.in
+ -$(SED) -e 's,@zfsexecdir\@,$(zfsexecdir),g' \
+ -e 's,@sysconfdir\@,$(sysconfdir),g' \
+ $< >'$@'
distclean-local::
-$(RM) default.cfg
diff --git a/tests/zfs-tests/include/default.cfg.in b/tests/zfs-tests/include/default.cfg.in
index 90d1d8bd6..e1e2a7e91 100644
--- a/tests/zfs-tests/include/default.cfg.in
+++ b/tests/zfs-tests/include/default.cfg.in
@@ -33,10 +33,8 @@
. $STF_SUITE/include/libtest.shlib
# ZFS Directories
-export prefix=@prefix@
-export exec_prefix=@exec_prefix@
export ZEDLET_ETC_DIR=${ZEDLET_ETC_DIR:-@sysconfdir@/zfs/zed.d}
-export ZEDLET_LIBEXEC_DIR=${ZEDLET_LIBEXEC_DIR:-@libexecdir@/zfs/zed.d}
+export ZEDLET_LIBEXEC_DIR=${ZEDLET_LIBEXEC_DIR:-@zfsexecdir@/zed.d}
export ZPOOL_SCRIPT_DIR=${ZPOOL_SCRIPT_DIR:-@sysconfdir@/zfs/zpool.d}
# Define run length constants