Upstream-Status: Inappropriate [embedded specific]

lttng-modules: replace KERNELDIR with KERNEL_SRC

Since lttng-modules uses the default way of module.bbclass to
build and install lttng-modules, we do this replacement for
it as-is.

Signed-off-by: Zumeng Chen <zumeng.chen@windriver.com>

Index: git/Makefile
===================================================================
--- git.orig/Makefile
+++ git/Makefile
@@ -62,19 +62,19 @@ obj-m += lib/
 endif # CONFIG_TRACEPOINTS
 
 else # KERNELRELEASE
-	KERNELDIR ?= /lib/modules/$(shell uname -r)/build
+	KERNEL_SRC ?= /lib/modules/$(shell uname -r)/build
 	PWD := $(shell pwd)
 	CFLAGS = $(EXTCFLAGS)
 
 default:
-	$(MAKE) -C $(KERNELDIR) M=$(PWD) modules
+	$(MAKE) -C $(KERNEL_SRC) M=$(PWD) modules
 
 modules_install:
-	$(MAKE) -C $(KERNELDIR) M=$(PWD) modules_install
+	$(MAKE) -C $(KERNEL_SRC) M=$(PWD) modules_install
 
 clean:
-	$(MAKE) -C $(KERNELDIR) M=$(PWD) clean
+	$(MAKE) -C $(KERNEL_SRC) M=$(PWD) clean
 
 %.i: %.c
-	$(MAKE) -C $(KERNELDIR) M=$(PWD) $@
+	$(MAKE) -C $(KERNEL_SRC) M=$(PWD) $@
 endif # KERNELRELEASE
Index: git/probes/Makefile
===================================================================
--- git.orig/probes/Makefile
+++ git/probes/Makefile
@@ -231,18 +231,18 @@ endif
 endif
 
 else
-	KERNELDIR ?= /lib/modules/$(shell uname -r)/build
+	KERNEL_SRC ?= /lib/modules/$(shell uname -r)/build
 	PWD := $(shell pwd)
 	CFLAGS = $(EXTCFLAGS)
 
 default:
-	$(MAKE) -C $(KERNELDIR) M=$(PWD) modules
+	$(MAKE) -C $(KERNEL_SRC) M=$(PWD) modules
 
 modules_install:
-	$(MAKE) -C $(KERNELDIR) M=$(PWD) modules_install
+	$(MAKE) -C $(KERNEL_SRC) M=$(PWD) modules_install
 	/sbin/depmod -a
 
 clean:
-	$(MAKE) -C $(KERNELDIR) M=$(PWD) clean
+	$(MAKE) -C $(KERNEL_SRC) M=$(PWD) clean
 
 endif
