2013-02-17 20:10:17 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
PROG=$0
|
|
|
|
|
|
|
|
pkgcfg=/etc/sysconfig/zfs
|
|
|
|
|
|
|
|
while getopts "n:v:c:f:" opt; do
|
|
|
|
case $opt in
|
|
|
|
n) pkgname=$OPTARG ;;
|
|
|
|
v) pkgver=$OPTARG ;;
|
|
|
|
c) pkgcfg=$OPTARG ;;
|
|
|
|
f) filename=$OPTARG ;;
|
|
|
|
esac
|
|
|
|
done
|
|
|
|
|
|
|
|
if [ -z "${pkgname}" -o -z "${pkgver}" -o -z "${filename}" ]; then
|
|
|
|
echo "Usage: $PROG -n <pkgname> -v <pkgver> -c <pkgcfg> -f <filename>"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
cat >${filename} <<EOF
|
|
|
|
PACKAGE_NAME="${pkgname}"
|
|
|
|
PACKAGE_VERSION="${pkgver}"
|
|
|
|
PACKAGE_CONFIG="${pkgcfg}"
|
|
|
|
PRE_BUILD="configure
|
|
|
|
--prefix=/usr
|
|
|
|
--with-config=kernel
|
2013-03-20 22:15:05 +00:00
|
|
|
--with-linux=\${kernel_source_dir}
|
|
|
|
--with-linux-obj=\${kernel_source_dir}
|
2014-10-13 17:35:01 +00:00
|
|
|
--with-spl=\${source_tree}/spl-\${PACKAGE_VERSION}
|
2013-02-17 20:10:17 +00:00
|
|
|
--with-spl-obj=\${dkms_tree}/spl/\${PACKAGE_VERSION}/\${kernelver}/\${arch}
|
|
|
|
--with-spl-timeout=300
|
2017-12-07 08:43:13 +00:00
|
|
|
\$(
|
|
|
|
[[ -n \"\${ICP_ROOT}\" ]] && \\
|
|
|
|
{
|
|
|
|
echo --with-qat=\"\${ICP_ROOT}\"
|
|
|
|
}
|
|
|
|
)
|
2013-02-17 20:10:17 +00:00
|
|
|
\$(
|
|
|
|
[[ -r \${PACKAGE_CONFIG} ]] \\
|
|
|
|
&& source \${PACKAGE_CONFIG} \\
|
|
|
|
&& shopt -q -s extglob \\
|
|
|
|
&& \\
|
|
|
|
{
|
|
|
|
if [[ \${ZFS_DKMS_ENABLE_DEBUG,,} == @(y|yes) ]]
|
|
|
|
then
|
|
|
|
echo --enable-debug
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
)
|
|
|
|
"
|
2014-10-09 17:22:59 +00:00
|
|
|
POST_BUILD="scripts/dkms.postbuild
|
2013-02-17 20:10:17 +00:00
|
|
|
-n \${PACKAGE_NAME}
|
|
|
|
-v \${PACKAGE_VERSION}
|
|
|
|
-a \${arch}
|
|
|
|
-k \${kernelver}
|
|
|
|
-t \${dkms_tree}
|
|
|
|
"
|
2013-03-20 18:01:48 +00:00
|
|
|
BUILD_DEPENDS[0]="spl"
|
2013-02-17 20:10:17 +00:00
|
|
|
AUTOINSTALL="yes"
|
|
|
|
REMAKE_INITRD="no"
|
|
|
|
MAKE[0]="make"
|
|
|
|
STRIP[0]="\$(
|
|
|
|
[[ -r \${PACKAGE_CONFIG} ]] \\
|
|
|
|
&& source \${PACKAGE_CONFIG} \\
|
|
|
|
&& shopt -q -s extglob \\
|
|
|
|
&& [[ \${ZFS_DKMS_DISABLE_STRIP,,} == @(y|yes) ]] \\
|
|
|
|
&& echo -n no
|
|
|
|
)"
|
|
|
|
STRIP[1]="\${STRIP[0]}"
|
|
|
|
STRIP[2]="\${STRIP[0]}"
|
|
|
|
STRIP[3]="\${STRIP[0]}"
|
|
|
|
STRIP[4]="\${STRIP[0]}"
|
|
|
|
STRIP[5]="\${STRIP[0]}"
|
2016-10-06 17:31:42 +00:00
|
|
|
STRIP[6]="\${STRIP[0]}"
|
2013-02-17 20:10:17 +00:00
|
|
|
BUILT_MODULE_NAME[0]="zavl"
|
|
|
|
BUILT_MODULE_LOCATION[0]="module/avl/"
|
|
|
|
DEST_MODULE_LOCATION[0]="/extra/avl/avl"
|
|
|
|
BUILT_MODULE_NAME[1]="znvpair"
|
|
|
|
BUILT_MODULE_LOCATION[1]="module/nvpair/"
|
|
|
|
DEST_MODULE_LOCATION[1]="/extra/nvpair/znvpair"
|
|
|
|
BUILT_MODULE_NAME[2]="zunicode"
|
|
|
|
BUILT_MODULE_LOCATION[2]="module/unicode/"
|
|
|
|
DEST_MODULE_LOCATION[2]="/extra/unicode/zunicode"
|
|
|
|
BUILT_MODULE_NAME[3]="zcommon"
|
|
|
|
BUILT_MODULE_LOCATION[3]="module/zcommon/"
|
|
|
|
DEST_MODULE_LOCATION[3]="/extra/zcommon/zcommon"
|
|
|
|
BUILT_MODULE_NAME[4]="zfs"
|
|
|
|
BUILT_MODULE_LOCATION[4]="module/zfs/"
|
|
|
|
DEST_MODULE_LOCATION[4]="/extra/zfs/zfs"
|
Retire legacy test infrastructure
* Removed zpios kmod, utility, headers and man page.
* Removed unused scripts zpios-profile/*, zpios-test/*,
zpool-config/*, smb.sh, zpios-sanity.sh, zpios-survey.sh,
zpios.sh, and zpool-create.sh.
* Removed zfs-script-config.sh.in. When building 'make' generates
a common.sh with in-tree path information from the common.sh.in
template. This file and sourced by the test scripts and used
for in-tree testing, it is not included in the packages. When
building packages 'make install' uses the same template to
create a new common.sh which is appropriate for the packaging.
* Removed unused functions/variables from scripts/common.sh.in.
Only minimal path information and configuration environment
variables remain.
* Removed unused scripts from scripts/ directory.
* Remaining shell scripts in the scripts directory updated to
cleanly pass shellcheck and added to checked scripts.
* Renamed tests/test-runner/cmd/ to tests/test-runner/bin/ to
match install location name.
* Removed last traces of the --enable-debug-dmu-tx configure
options which was retired some time ago.
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #6509
2017-08-16 00:26:38 +00:00
|
|
|
BUILT_MODULE_NAME[5]="icp"
|
|
|
|
BUILT_MODULE_LOCATION[5]="module/icp/"
|
|
|
|
DEST_MODULE_LOCATION[5]="/extra/icp/icp"
|
2018-02-08 16:16:23 +00:00
|
|
|
BUILT_MODULE_NAME[6]="zlua"
|
|
|
|
BUILT_MODULE_LOCATION[6]="module/lua/"
|
|
|
|
DEST_MODULE_LOCATION[6]="/extra/lua/zlua"
|
2013-02-17 20:10:17 +00:00
|
|
|
EOF
|