From: Ake Sandgren Date: Thu, 11 May 2023 06:48:32 +0000 (+0200) Subject: LU-16819 build: use mofed path based on target kernel X-Git-Tag: 2.15.64~181 X-Git-Url: https://git.whamcloud.com/gitweb?a=commitdiff_plain;h=0e9708016b9948676484d290326c1fe8a269eb80;p=fs%2Flustre-release.git LU-16819 build: use mofed path based on target kernel Instead of using "uname -r", which limits builds to the currently running kernel, use the target kernel which is available in LINUXRELEASE, if the directory is available. Building for a specific kernel is common practice when using DKMS. Test-Parameters: trivial Signed-off-by: Ake Sandgren Change-Id: Ifce912061a74fc5b7435cd940105190f0c3cd544 Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/50937 Reviewed-by: Andreas Dilger Reviewed-by: Shaun Tancheff Reviewed-by: Oleg Drokin Tested-by: jenkins Tested-by: Maloo --- diff --git a/lnet/autoconf/lustre-lnet.m4 b/lnet/autoconf/lustre-lnet.m4 index 9ab9d18..3a58fc9 100644 --- a/lnet/autoconf/lustre-lnet.m4 +++ b/lnet/autoconf/lustre-lnet.m4 @@ -105,8 +105,10 @@ case $with_o2ib in egrep "${O2IBDIR}$" | head -n1) if test -n "$O2IBDIR_PATH"; then + if test -d $O2IBDIR_PATH/${LINUXRELEASE}; then + O2IBDIR_PATH=$O2IBDIR_PATH/${LINUXRELEASE} + fi EXT_O2IBPATHS=$(find $O2IBDIR_PATH -name rdma_cm.h | - grep -F -e "$(uname -r)" -e default | sed -e 's/\/include\/rdma\/rdma_cm.h//') fi