The following will solve the problem:
obj-m += Hello.o
all:
    $(MAKE) -C $(KERNELDIR) M=$(PWD)  modules
install:





On 9 February 2010 16:17, chungae9ri <chungae...@gmail.com> wrote:

>  Hi all
> I put my  module src files of helloworld into vendor/xxx/modules and I
> want to add my driver modules into android but I can't build it.
> this is my Makefile, it's simple
>
> obj-m += Hello.o
> modules:
> <tab>    $(MAKE) -C $(KERNELDIR) M=$(PWD) ARCH=$(ARCH) CROSS_COMPILE=$
> (CROSS_COMPILE) modules
>
>
> when I "make modules" the following error occurs
>
>  ERROR : kernel configuration is invalid.
>               include/linux/autoconf.h or include/config/auto.conf
> are missing.
>               Run 'make oldconfig && make prepare' on kernel src to
> fix it.
>
>  CC [M]  /media/slave2/work/xxx/LINUX/android/vendor/xxx/modules/
> Hello.o
> cc1: error: include/linux/autoconf.h: No such file or directory
> In file included from include/linux/prefetch.h:14,
>                 from include/linux/list.h:6,
>                 from include/linux/module.h:9,
>                 from /media/slave2/work/xxx/LINUX/android/vendor/xxx/
> modules/Hello.c:1:
> /media/slave2/work/xxx/LINUX/android/kernel/arch/arm/include/asm/
> processor.h:109:5: error: "__LINUX_ARM_ARCH__" is not defined
> In file included from /media/slave2/work/xxx/LINUX/android/kernel/arch/
> arm/include/asm/system.h:6,
>                 from include/linux/list.h:7,
>                 from include/linux/module.h:9,
>                 from /media/slave2/work/xxx/LINUX/android/vendor/xxx/
> modules/Hello.c:1:
> /media/slave2/work/xxx/LINUX/android/kernel/arch/arm/include/asm/
> memory.h:18:25: error: mach/memory.h: No such file or directory
> In file included from /media/slave2/work/xxx/LINUX/android/kernel/arch/
> arm/include/asm/system.h:6,
>                 from include/linux/list.h:7,
>
> How can I fix this?
>
> --
> unsubscribe: 
> android-porting+unsubscr...@googlegroups.com<android-porting%2bunsubscr...@googlegroups.com>
> website: http://groups.google.com/group/android-porting
>

-- 
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-porting

Reply via email to