diff --git a/Makefile b/Makefile index 2938c76..8ef0567 100755 --- a/Makefile +++ b/Makefile @@ -403,7 +403,7 @@ EXTRA_CFLAGS += -DRTW_USE_CFG80211_STA_EVENT SUBARCH := $(shell uname -m | sed -e s/i.86/i386/ | sed -e s/ppc/powerpc/ | sed -e s/armv.l/arm/) ARCH ?= $(SUBARCH) CROSS_COMPILE ?= -KVER := $(shell uname -r) +KVER ?= $(if $(KERNELRELEASE),$(KERNELRELEASE),$(shell uname -r)) KSRC := /lib/modules/$(KVER)/build MODDESTDIR := /lib/modules/$(KVER)/kernel/drivers/net/wireless/ INSTALL_PREFIX :=