Kernel build error with IMX53 QSB

cancel
Showing results for 
Search instead for 
Did you mean: 

Kernel build error with IMX53 QSB

514 Views
Swamy
Contributor III
Hi,

I am trying to build the kernel module, I am using linux-2.6.35.3 headers for compilation. I am getting following error. Request you to please guide,

cc1: error: unrecognized command line option "-mlittle-endian"
cc1: error: unrecognized command line option "-mapcs"
cc1: error: unrecognized command line option "-mno-sched-prolog"
cc1: error: unrecognized command line option "-mabi=apcs-gnu"


Regards,
Swamy
Labels (1)
0 Kudos
4 Replies

117 Views
rlorriaux
Contributor I

Here is how you build a kernel without the sources - just the headers:

http://www.cyberciti.biz/tips/build-linux-kernel-module-against-installed-kernel-source-tree.html

The procedure can be easily adapted to the mx5 kernel.

 

Daiane Angolini said:

"__LINUX_ARM_ARCH__" is not defined

Did you configure your source code? 

 

I don´t know how to build a module without the kernel source code, although it looks like it´s a configuration missing error...

0 Kudos

117 Views
daiane_angolini
NXP Employee
NXP Employee
"__LINUX_ARM_ARCH__" is not defined

Did you configure your source code? 

 

I don´t know how to build a module without the kernel source code, although it looks like it´s a configuration missing error...

0 Kudos

117 Views
Swamy
Contributor III

Hi,

Thanks for your reply,

I tried your command, I am getting this error (attached file). Please suggest.

 

  ERROR: Kernel configuration is invalid.
         include/generated/autoconf.h or include/config/auto.conf are missing.
         Run 'make oldconfig && make prepare' on kernel src to fix it.


  WARNING: Symbol version dump /home/lucid/ltib/rpm/BUILD/linux-2.6.35.3/Module.symvers
           is missing; modules will have no dependencies and modversions.

Regards,

Swamy

0 Kudos

117 Views
rlorriaux
Contributor I

Did you set up your cross-compilation correctly?

You need to set the CROSS_COMPILE=[toolchain prefix] and ARCH=arm when you compile, e.g.

make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- -j6

Also, your cross-compiler needs to be in the PATH.

0 Kudos