5 # $4 : $kernel_source_dir
12 SERVER="--disable-server"
16 lustre-zfs|lustre-all)
18 if [ "$1" == "lustre-zfs" ]; then
19 LDISKFS="--disable-ldiskfs"
22 # ZFS and SPL are version locked
23 ZFS_VERSION=$(dkms status -m zfs -k $3 -a $5 2>/dev/null |
24 sed -e 's:zfs/::g' -e 's:,.*::g' | cut -d: -f1 |
26 if [ -z $ZFS_VERSION ] ; then
27 echo "zfs-dkms package must already be installed and built under DKMS control"
31 SERVER="--enable-server $LDISKFS \
32 --with-linux=$4 --with-linux-obj=$4 \
33 --with-spl=$(realpath $7/spl/${ZFS_VERSION}/source) \
34 --with-spl-obj=$(realpath $7/spl/kernel-$3-$5) \
35 --with-zfs=$(realpath $7/zfs/${ZFS_VERSION}/source) \
36 --with-zfs-obj=$(realpath $7/zfs/kernel-$3-$5)"
38 KERNEL_STUFF="--with-linux=$4 --with-linux-obj=$4"
42 SERVER="--enable-server --without-zfs --without-spl \
43 --with-linux=$4 --with-linux-obj=$4"
45 KERNEL_STUFF="--with-linux=$4 --with-linux-obj=$4"
49 PACKAGE_CONFIG="/etc/sysconfig/lustre"
51 [[ -r ${PACKAGE_CONFIG} ]] \
52 && source ${PACKAGE_CONFIG} \
53 && shopt -q -s extglob \
56 if [[ ${LUSTRE_DKMS_DISABLE_CDEBUG,,} == @(y|yes) ]]
58 echo --disable-libcfs-cdebug
60 if [[ ${LUSTRE_DKMS_DISABLE_TRACE,,} == @(y|yes) ]]
62 echo --disable-libcfs-trace
64 if [[ ${LUSTRE_DKMS_DISABLE_ASSERT,,} == @(y|yes) ]]
66 echo --disable-libcfs-assert
71 rpm -qa | grep krb5-devel >/dev/null
78 # run a configure pass to clean "--enable-dist" only effect and also to
79 # ensure local/on-target environment to be taken into account for
80 # dkms.mkconf script customizations and before next build/MAKE step
81 ./configure --prefix=/usr --enable-modules --disable-iokit --disable-snmp \
82 --disable-doc --disable-utils --disable-tests --disable-maintainer-mode \
83 $KERNEL_STUFF $GSS $SERVER $DKMS_CONFIG_OPTS \
84 --disable-manpages --disable-mpitests
87 echo "configure error, check $7/$1/$2/build/config.log"