Make modules modules_install problem.

Dear forum,

I am trying to compile and install a kernel module in my Debian 3.8.13-bone67 / Xenomai environment.
The compile runs fine, but the “modules modules_install” causes a warning due to a wrong path (see below).
The path is correct except for the 3.8.13+ which should have been 3.8.13-bone67
I am running a very simple makefile (maybe too simple?).

Please advice.

Best regards
Terje Froysa

Makefile:

debian@beaglebone:~/gps_test$ cat Makefile
obj-m := rtgps_1pps.o

KSRC := /lib/modules/$(shell uname -r)/source
EXTRA_CFLAGS := -I$(KSRC)/include/xenomai -I$(KSRC)/include/xenomai/posix -I$(KSRC)/arch/arm/mach-omap2

all:
make -C $(KSRC) $(EXTRA_CFLAGS) M=pwd modules modules_install
clean:
make -C $(KSRC) M=pwd clean

Output:

debian@beaglebone:~/gps_test$ sudo make
make -C /lib/modules/3.8.13-bone67/source -I/lib/modules/3.8.13-bone67/source/include/xenomai -I/lib/modules/3.8.13-bone67/source/include/xenomai/posix -I/lib/modules/3.8.13-bone67/source/arch/arm/mach-omap2 M=pwd modules modules_install
make[1]: Entering directory /home/debian/disk/bb-kernel/KERNEL' Building modules, stage 2. MODPOST 1 modules INSTALL /home/debian/gps_test/rtgps_1pps.ko DEPMOD **3.8.13+** WARNING: could not open /lib/modules/**3.8.13+**/modules.order: No such file or directory WARNING: could not open /lib/modules/3.8.13+/modules.builtin: No such file or directory make[1]: Leaving directory /home/debian/disk/bb-kernel/KERNEL’

Adding to my observations:
By inspecting the bb-kernel/tools/local_install.sh I found that the 3.8.13+ probably stems from the file ./KERNEL/include/generated/utsrelease.h
The script sets the KERNEL_UTS to 3.8.13+ by extracting the parameter from the utsrelease.h

As the kernel version is distributed as 3.8.13-bone67, this seem to be a flaw in the kernel build/install system?