** If you get a panic - "not syncing: Attempted to kill init!" it can be for many different reasons. Try setting CONFIG_DEBUG_USER=y in your .config and pass 'user_debug=255' in the kernel command line. That will give you a more verbose output about why user space programs crash. Thanks to Daniel Mack on the linux-arm-kernel mailing list for this tip.

** If you get a panic - "not syncing: Attempted to kill init!" it can be for many different reasons. Try setting CONFIG_DEBUG_USER=y in your .config and pass 'user_debug=255' in the kernel command line. That will give you a more verbose output about why user space programs crash. Thanks to Daniel Mack on the linux-arm-kernel mailing list for this tip.

−

=== gdb tips - running gdb with gdbserver===

+

=== gdb tips - target debugging with gdbserver===

In order to debug an ethernet connected target system from a host we could use gdbserver.

In order to debug an ethernet connected target system from a host we could use gdbserver.

Line 176:

Line 176:

break main

break main

continue

continue

−

−

=== gdb tips - get element size ===

=== gdb tips - get element size ===

Revision as of 15:11, 27 October 2011

This page has information about developing Embedded Linux, including links to toolchains, debuggers and other development tools. Also, it has links to pages with debugging tips.

QtCreator is an nice IDE which has code completion, remote deployment (with version 2.3) and Outline view. It also has an VIm mode. Its menus are much cleaner than these from Eclipse and its easier to get started with this ide than Eclipse for that very reason.

Podcasts

[2] - Timesys LinuxLink Radio. (Despite the name, it's has nothing to do with the older Linux Link podcast, and it's not on the radio. No longer updates on a regular schedule, but the archives are available.)

Code Style Tips

Debugging Tips

If you get a panic - "not syncing: Attempted to kill init!" it can be for many different reasons. Try setting CONFIG_DEBUG_USER=y in your .config and pass 'user_debug=255' in the kernel command line. That will give you a more verbose output about why user space programs crash. Thanks to Daniel Mack on the linux-arm-kernel mailing list for this tip.

gdb tips - target debugging with gdbserver

In order to debug an ethernet connected target system from a host we could use gdbserver.

Initial preparations:

Copy gdbserver to target (if not there already)

Change file permissions to execute

Make sure libthread_db is installed in target /lib.

(libthread_db is found in <gcc_toolchain_path>/arm-none-linux-gnueabi/libc/usr/lib/libthread_db.so)

Run gdbserver on target

gdbserver :4000 <application>

Gdbserver could also be run in multiprocess mode where applications are started or processes connected to remotely, on the fly.