Changes between Version 5 and Version 6 of compile_all_old


Ignore:
Timestamp:
Jun 7, 2018, 2:22:42 PM (6 years ago)
Author:
Bayard Gildas
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • compile_all_old

    v5 v6  
    1515
    1616If you have to debug surprising segfaults (you know what I mean, do you? :D ) you will need to compile your code in debug mode (see below).
    17 Then you'll have to activate the core dump generation with
     17Then you'll have to activate the core dump generation (in each terminal) with
    1818{{{
    1919$ ulimit -c unlimited
    2020}}}
    21 Then when your program crashes, it will generate a "core" file. Use gdb with your binary as the first parameter (again, compiled in debug mode) and the core file as the second parameter.
     21To be sure that the kernel will generate those migthy core file you should issue this command
     22{{{
     23echo core > /proc/sys/kernel/core_pattern (en sudo)
     24}}}
     25Then when your program crashes, it will generate a "core" file. Use gdb with your binary as the first parameter (again, compiled in debug mode) and the core file as the second parameter (use your cross compiled gdb in case of cross development, arm-poky...-gdb for instance to debug an arm code from your PC).
    2226It should load your program symbols. Then the "bt" command will show the backtrace, which is the sequence of function calls that resulted in the crash, allowing you to know exactly where is the problem.
     27
    2328
    2429== Full framework ==