Re: kernel compiling

Christian Eisendle <[email protected]>
Newsgroups gmane.linux.ports.arm.general
Message-ID <1241031891.6478.10.camel@christian>
Hi Alexei,

> Good afternoon.
> I wonder how I can compile the kernel having possibility of debugging it.
> It is well known that comfortable debug process require such compilation parameters as "-g -O0".
> But the Makefile contains only "-Os" and "-O2".
> Trying replace -O2 with -O0 I got an error at some stage of building:

AFAIK parts of the Kernel rely on inline functions and other compiler
specific features which are disabled when using -O0. Therefore, the
Kernel Makefile only allows either Os or O2. Of course it's possible to
compile particular modules using -O0.

Actually, these optimization flags still allows debugging, there might
only come up some strange side effects while stepping through the code.

Christian.


-------------------------------------------------------------------
List admin: http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm
FAQ:        http://www.arm.linux.org.uk/mailinglists/faq.php
Etiquette:  http://www.arm.linux.org.uk/mailinglists/etiquette.php
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.