From d5cee6ebf4e62f4f92c040cfaac33381e1c203b6 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Fri, 27 Aug 2021 17:58:27 +0000 Subject: [PATCH] Makefile: Make sure that $(KVER) and $(KDIR) are set These variables are needed for building Debian packages. git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@9496 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Makefile b/Makefile index c1495df45..7dee4f530 100644 --- a/Makefile +++ b/Makefile @@ -35,6 +35,11 @@ ifdef KDIR cat $(KDIR)/include/config/kernel.release 2>/dev/null || \ make -s -C $(KDIR) kernelversion)) endif +else + ifndef KVER + KVER=$(strip $(shell uname -r)) + endif + KDIR=/lib/modules/$(KVER)/build endif ifeq ($(QLA_32GBIT),no)