1include $(top_srcdir)/config/Shellcheck.am 2 3pkgdatadir = $(datadir)/@PACKAGE@ 4 5dist_pkgdata_SCRIPTS = \ 6 zimport.sh \ 7 zfs.sh \ 8 zfs-tests.sh \ 9 zloop.sh \ 10 zfs-helpers.sh 11 12EXTRA_SCRIPTS = \ 13 commitcheck.sh \ 14 common.sh.in \ 15 dkms.mkconf \ 16 dkms.postbuild \ 17 kmodtool \ 18 make_gitrev.sh \ 19 man-dates.sh \ 20 paxcheck.sh \ 21 mancheck.sh 22 23EXTRA_DIST = \ 24 cstyle.pl \ 25 enum-extract.pl \ 26 zfs2zol-patch.sed \ 27 zol2zfs-patch.sed \ 28 $(EXTRA_SCRIPTS) 29 30SHELLCHECKSCRIPTS = $(EXTRA_SCRIPTS) 31SHELLCHECK_OPTS = --enable=all 32 33define EXTRA_ENVIRONMENT 34 35# Only required for in-tree use 36export INTREE="yes" 37export GDB="libtool --mode=execute gdb" 38export LDMOD=/sbin/insmod 39 40export CMD_DIR=@abs_top_builddir@/cmd 41export UDEV_RULE_DIR=@abs_top_builddir@/udev/rules.d 42export ZEDLET_ETC_DIR=$$CMD_DIR/zed/zed.d 43export ZEDLET_LIBEXEC_DIR=$$CMD_DIR/zed/zed.d 44export ZPOOL_SCRIPT_DIR=$$CMD_DIR/zpool/zpool.d 45export ZPOOL_SCRIPTS_PATH=$$CMD_DIR/zpool/zpool.d 46export ZPOOL_COMPAT_DIR=$$CMD_DIR/zpool/compatibility.d 47export CONTRIB_DIR=@abs_top_builddir@/contrib 48export LIB_DIR=@abs_top_builddir@/lib 49export SYSCONF_DIR=@abs_top_builddir@/etc 50 51export INSTALL_UDEV_DIR=@udevdir@ 52export INSTALL_UDEV_RULE_DIR=@udevruledir@ 53export INSTALL_MOUNT_HELPER_DIR=@mounthelperdir@ 54export INSTALL_SYSCONF_DIR=@sysconfdir@ 55export INSTALL_PYTHON_DIR=@pythonsitedir@ 56 57export KMOD_SPL=@abs_top_builddir@/module/spl/spl.ko 58export KMOD_ZAVL=@abs_top_builddir@/module/avl/zavl.ko 59export KMOD_ZNVPAIR=@abs_top_builddir@/module/nvpair/znvpair.ko 60export KMOD_ZUNICODE=@abs_top_builddir@/module/unicode/zunicode.ko 61export KMOD_ZCOMMON=@abs_top_builddir@/module/zcommon/zcommon.ko 62export KMOD_ZLUA=@abs_top_builddir@/module/lua/zlua.ko 63export KMOD_ICP=@abs_top_builddir@/module/icp/icp.ko 64export KMOD_ZFS=@abs_top_builddir@/module/zfs/zfs.ko 65export KMOD_FREEBSD=@abs_top_builddir@/module/openzfs.ko 66export KMOD_ZZSTD=@abs_top_builddir@/module/zstd/zzstd.ko 67endef 68 69export EXTRA_ENVIRONMENT 70 71all-local: 72 -$(SED) -e '\|^export BIN_DIR=|s|$$|@abs_top_builddir@/bin|' \ 73 -e '\|^export SBIN_DIR=|s|$$|@abs_top_builddir@/bin|' \ 74 -e '\|^export LIBEXEC_DIR=|s|$$|@abs_top_builddir@/bin|' \ 75 -e '\|^export ZTS_DIR=|s|$$|@abs_top_srcdir@/tests|' \ 76 -e '\|^export SCRIPT_DIR=|s|$$|@abs_top_srcdir@/scripts|' \ 77 $(abs_top_srcdir)/scripts/common.sh.in >common.sh 78 -echo "$$EXTRA_ENVIRONMENT" >>common.sh 79 80clean-local: 81 -$(RM) common.sh 82 83install-data-hook: 84 -$(SED) -e '\|^export BIN_DIR=|s|$$|@bindir@|' \ 85 -e '\|^export SBIN_DIR=|s|$$|@sbindir@|' \ 86 -e '\|^export LIBEXEC_DIR=|s|$$|@zfsexecdir@|' \ 87 -e '\|^export ZTS_DIR=|s|$$|@datadir@/@PACKAGE@|' \ 88 -e '\|^export SCRIPT_DIR=|s|$$|@datadir@/@PACKAGE@|' \ 89 $(abs_top_srcdir)/scripts/common.sh.in \ 90 >$(DESTDIR)$(datadir)/@PACKAGE@/common.sh 91