On Monday, March 23, 2015 at 3:17:00 AM UTC-4, Shyam D wrote:
>
> Machine Details :
>
> Linux beaglebone 3.8.13-bone47 armv7l GNU/Linux
>
>
> Problem Details: 
>
> In a attempt to write out-of-tree modules on beagle bone black(as intree 
> modules require me to compile/flash them again and again ), i have logged 
> in to beagle bone black revc through ssh client, which gives me a command 
> line interface via putty, as in general out-of-tree module development, i 
> have tried to compile module with the following make file 
>
> ifneq ($(KERNELRELEASE),)
> # kbuild part of makefile
>         obj-m  := module.o
>
>         #module-objs := module.o
> else
> # normal makefile
>         KDIR ?= /lib/modules/$(shell uname -r)/build
>         PWD  := $(shell pwd)
> default:
>         $(MAKE) -C $(KDIR) M=$(PWD) modules
>
> endif
>
>
> resulting an error 
>
> root@beaglebone:~/lddgeek# make
> make -C /lib/modules/3.8.13-bone47/build M=/root/lddgeek modules
> make: *** /lib/modules/3.8.13-bone47/build: No such file or directory.  Stop.
> make: *** [default] Error 2
>
>
> but when i parse to the path of KDIR i did not find build folder as we 
> find it in an normal ubuntu installed on x86 
>
> if i have to develop drivers/modules out-of-tree on a Beagle how could i 
> do that? 
>
> Thank you 
> Shyam
>

You need to install the kernel headers, then run "make scripts" in the 
headers directory:  

root@beaglebone:/#  apt-get install linux-headers-`uname -r` 
root@beaglebone:/#  cd /lib/modules/`uname -r`/build
root@beaglebone:/#  make scripts

Once competed, your make of the out of source kernel module should get past 
that initial error.

frank

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beagleboard+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to