ib_srpt: Fix MOFED build

This commit is contained in:
Bart Van Assche
2016-12-17 04:39:12 -08:00
parent 1567392211
commit 0fdb98e5d5

View File

@@ -66,8 +66,7 @@ ifeq ($(OFED_FLAVOR),MOFED)
# <linux/compat-2.6.h>, include that header file explicitly.
OFED_KERNEL_DIR:=/usr/src/ofa_kernel/default
OFED_VERS=$(shell rpm -q --qf '%{version}\n' mlnx-ofa_kernel-devel 2>/dev/null)
CKVER:=$(shell echo "$(KVER)" | sed 's/^\(\(2\.6\|[3-9]\)\.[0-9]*\).*/\1/')
OFED_CFLAGS:=-I$(OFED_KERNEL_DIR)/include -include "linux/compat-$(CKVER).h"
OFED_CFLAGS:=-I$(OFED_KERNEL_DIR)/include -include "linux/compat-2.6.h"
OFED_CFLAGS+=-DMOFED_MAJOR=$(shell echo $(OFED_VERS) | cut -f1 -d.)
OFED_CFLAGS+=-DMOFED_MINOR=$(shell echo $(OFED_VERS) | cut -f2 -d.)
else