https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&feed=atom&action=history
Amarok/Development/DebuggingHowTo - Revision history
2024-03-28T19:55:42Z
Revision history for this page on the wiki
MediaWiki 1.40.2
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=41700&oldid=prev
Mamarok: /* Debugging an already running instance of Amarok */ adding more precision about the meaning of 'pidof amarok'
2015-02-24T21:26:37Z
<p><span dir="auto"><span class="autocomment">Debugging an already running instance of Amarok: </span> adding more precision about the meaning of 'pidof amarok'</span></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 21:26, 24 February 2015</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l108">Line 108:</td>
<td colspan="2" class="diff-lineno">Line 108:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> gdb `which amarok` -p `pidof amarok`</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> gdb `which amarok` -p `pidof amarok`</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> (gdb) thread apply all bt</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> (gdb) thread apply all bt</div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">where 'pidof amarok' needs to be replaced by the PID number of the Amarok process. You can see the PID number of processes for example by using the command "top" in a separate konsole.</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>You will then get a backtrace, which you should submit in your bug report.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>You will then get a backtrace, which you should submit in your bug report.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
</table>
Mamarok
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37905&oldid=prev
Strohel: /* Gentoo */
2014-05-17T13:50:02Z
<p><span dir="auto"><span class="autocomment">Gentoo</span></span></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 13:50, 17 May 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l29">Line 29:</td>
<td colspan="2" class="diff-lineno">Line 29:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>The <code>debug</code> use-flag only enables debugging assertions and is useful mainly for people that want to actively help with Amarok development.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>The <code>debug</code> use-flag only enables debugging assertions and is useful mainly for people that want to actively help with Amarok development.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>See also the Gentoo guide [http://wiki.gentoo.org/wiki/Project:Quality_Assurance/<del style="font-weight: bold; text-decoration: none;">BacktracesHow </del>to get meaningful backtraces] for more details about debug builds on Gentoo.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>See also the Gentoo guide [http://wiki.gentoo.org/wiki/Project:Quality_Assurance/<ins style="font-weight: bold; text-decoration: none;">Backtraces </ins>to get meaningful backtraces] for more details about debug builds on Gentoo.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>== Debug Output ==</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>== Debug Output ==</div></td></tr>
</table>
Strohel
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37904&oldid=prev
Strohel: /* Gentoo */
2014-05-17T13:48:42Z
<p><span dir="auto"><span class="autocomment">Gentoo</span></span></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 13:48, 17 May 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l20">Line 20:</td>
<td colspan="2" class="diff-lineno">Line 20:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>=== Gentoo ===</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>=== Gentoo ===</div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, <del style="font-weight: bold; text-decoration: none;">do the </del>following:</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, <ins style="font-weight: bold; text-decoration: none;">please ensure that you have </ins>following <ins style="font-weight: bold; text-decoration: none;">options in <code>make.conf</code></ins>:</div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;"> FEATURES</del>="<del style="font-weight: bold; text-decoration: none;">nostrip</del>" <del style="font-weight: bold; text-decoration: none;">emerge media</del>-<del style="font-weight: bold; text-decoration: none;">sound/amarok</del></div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"> CXXFLAGS</ins>="<ins style="font-weight: bold; text-decoration: none;">... -ggdb ...</ins>" <ins style="font-weight: bold; text-decoration: none;"> # or: </ins>-<ins style="font-weight: bold; text-decoration: none;">g</ins></div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;">In addition, make sure the <tt>CFLAGS</tt> contain either <tt>-g</tt> </del>or <del style="font-weight: bold; text-decoration: none;"><tt>-ggdb</tt> and it </del>is preferred to not include flags like <<del style="font-weight: bold; text-decoration: none;">tt</del>>-fomit-frame-pointer</<del style="font-weight: bold; text-decoration: none;">tt</del>><del style="font-weight: bold; text-decoration: none;">. You can also use </del><<del style="font-weight: bold; text-decoration: none;">tt</del>><del style="font-weight: bold; text-decoration: none;">FEATURES="splitdebug"</del></<del style="font-weight: bold; text-decoration: none;">tt</del>> <del style="font-weight: bold; text-decoration: none;">instead of <tt>nostrip</tt>, but don't have both at the same time</del>.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"> FEATURES="splitdebug" # </ins>or<ins style="font-weight: bold; text-decoration: none;">: nostrip</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">It </ins>is preferred to not include flags like <<ins style="font-weight: bold; text-decoration: none;">code</ins>>-fomit-frame-pointer</<ins style="font-weight: bold; text-decoration: none;">code</ins>> <ins style="font-weight: bold; text-decoration: none;">in </ins><<ins style="font-weight: bold; text-decoration: none;">code</ins>><ins style="font-weight: bold; text-decoration: none;">CXXFLAGS</ins></<ins style="font-weight: bold; text-decoration: none;">code</ins>>.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;">For the best backtraces, </del>you <del style="font-weight: bold; text-decoration: none;">should set similar <tt></del>USE<<del style="font-weight: bold; text-decoration: none;">/tt</del>> <del style="font-weight: bold; text-decoration: none;">flags (as well as the <tt>nostrip</del></<del style="font-weight: bold; text-decoration: none;">tt</del>> <del style="font-weight: bold; text-decoration: none;">option) </del>for <del style="font-weight: bold; text-decoration: none;">kdelibs and Qt 4</del>.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">Note that </ins>you <ins style="font-weight: bold; text-decoration: none;">do '''not''' need to have</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"> </ins>USE<ins style="font-weight: bold; text-decoration: none;">=debug</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">The </ins><<ins style="font-weight: bold; text-decoration: none;">code</ins>><ins style="font-weight: bold; text-decoration: none;">debug</ins></<ins style="font-weight: bold; text-decoration: none;">code</ins>> <ins style="font-weight: bold; text-decoration: none;">use-flag only enables debugging assertions and is useful mainly </ins>for <ins style="font-weight: bold; text-decoration: none;">people that want to actively help with Amarok development</ins>.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>See also the Gentoo guide <del style="font-weight: bold; text-decoration: none;">"</del>[http://wiki.gentoo.org/wiki/Project:Quality_Assurance/BacktracesHow to get meaningful backtraces <del style="font-weight: bold; text-decoration: none;">in Gentoo</del>]<del style="font-weight: bold; text-decoration: none;">" </del>for more details about debug builds on Gentoo.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>See also the Gentoo guide [http://wiki.gentoo.org/wiki/Project:Quality_Assurance/BacktracesHow to get meaningful backtraces] for more details about debug builds on Gentoo.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>== Debug Output ==</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>== Debug Output ==</div></td></tr>
</table>
Strohel
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37903&oldid=prev
Strohel: Debugging Hangs
2014-05-17T13:43:04Z
<p>Debugging Hangs</p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 13:43, 17 May 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l106">Line 106:</td>
<td colspan="2" class="diff-lineno">Line 106:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> (gdb) thread apply all bt</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> (gdb) thread apply all bt</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>You will then get a backtrace, which you should submit in your bug report.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>You will then get a backtrace, which you should submit in your bug report.</div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">== Debugging Hangs ==</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">Amarok is a multi-threaded application, effort is taken to do potentially blocking operations in background threads so that the UI is responsive. A bug in code may cause that the UI thread is unnecessarily blocked or a complete hang may occur. Please take steps below to debug these situations.</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"># Install debug symbols for Amarok and its dependencies as shown above.</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"># Prepare 2 terminal windows (tabs). Terminal 1 will be used to launch Amarok with debugging output, terminal 2 will be used to catch a backtrace.</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"># In terminal 2 prepare '''(do not yet execute)''' following command: <code>gdb --ex "set height 0" --ex "thread apply all bt 15" --ex "detach" --ex "q" -p $(pidof amarok)</code></ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"># Start Amarok with debugging output in terminal 1: <code>amarok --debug --nofork</code></ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"># Wait for the hang to occur or trigger it. Once it occurs, run the command prepared in terminal 2.</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"># Paste (do not attach) the backtrace from terminal 2 into a bug report, include also last screen or 2 of the debugging output prior to the crash from terminal 1 (please do not paste whole debugging log unless instructed). Also include usual info like steps to reproduce and version.</ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"># (Optional) Recreate the hang and backtrace multiple times and compare the backtrace of Thread 1 from different runs. Mention on the bug whether they are the same or not.</ins></div></td></tr>
</table>
Strohel
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37426&oldid=prev
Mamarok: /* Gentoo */ more editing
2014-04-18T16:04:07Z
<p><span dir="auto"><span class="autocomment">Gentoo: </span> more editing</span></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 16:04, 18 April 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l22">Line 22:</td>
<td colspan="2" class="diff-lineno">Line 22:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> FEATURES="nostrip" emerge media-sound/amarok</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> FEATURES="nostrip" emerge media-sound/amarok</div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> contain either <tt>-g</tt> or <tt>-ggdb</tt> and it is preferred to not include flags like <tt>-fomit-frame-pointer</tt>. You can also use FEATURES="splitdebug" instead of nostrip, but don't have both at the same time.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> contain either <tt>-g</tt> or <tt>-ggdb</tt> and it is preferred to not include flags like <tt>-fomit-frame-pointer</tt>. You can also use <ins style="font-weight: bold; text-decoration: none;"><tt></ins>FEATURES="splitdebug"<ins style="font-weight: bold; text-decoration: none;"></tt> </ins>instead of <ins style="font-weight: bold; text-decoration: none;"><tt></ins>nostrip<ins style="font-weight: bold; text-decoration: none;"></tt></ins>, but don't have both at the same time.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td></tr>
</table>
Mamarok
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37425&oldid=prev
Mamarok: /* Gentoo */ minor formatting
2014-04-18T16:03:00Z
<p><span dir="auto"><span class="autocomment">Gentoo: </span> minor formatting</span></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 16:03, 18 April 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l22">Line 22:</td>
<td colspan="2" class="diff-lineno">Line 22:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> FEATURES="nostrip" emerge media-sound/amarok</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> FEATURES="nostrip" emerge media-sound/amarok</div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> contain either -g or -ggdb and it is preferred to not include flags like <tt>-fomit-frame-pointer</tt>. You can also use FEATURES="splitdebug" instead of nostrip, but don't have both at the same time.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> contain either <ins style="font-weight: bold; text-decoration: none;"><tt></ins>-g<ins style="font-weight: bold; text-decoration: none;"></tt> </ins>or <ins style="font-weight: bold; text-decoration: none;"><tt></ins>-ggdb<ins style="font-weight: bold; text-decoration: none;"></tt> </ins>and it is preferred to not include flags like <tt>-fomit-frame-pointer</tt>. You can also use FEATURES="splitdebug" instead of nostrip, but don't have both at the same time.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td></tr>
</table>
Mamarok
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37424&oldid=prev
Mamarok: /* Gentoo */ correct URL instead of a redirect
2014-04-18T15:59:24Z
<p><span dir="auto"><span class="autocomment">Gentoo: </span> correct URL instead of a redirect</span></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 15:59, 18 April 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l26">Line 26:</td>
<td colspan="2" class="diff-lineno">Line 26:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>See also the Gentoo guide "[http://<del style="font-weight: bold; text-decoration: none;">www</del>.gentoo.org/<del style="font-weight: bold; text-decoration: none;">proj</del>/<del style="font-weight: bold; text-decoration: none;">en</del>/<del style="font-weight: bold; text-decoration: none;">qa/backtraces.xml How </del>to get meaningful backtraces in Gentoo]" for more details about debug builds on Gentoo.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>See also the Gentoo guide "[http://<ins style="font-weight: bold; text-decoration: none;">wiki</ins>.gentoo.org/<ins style="font-weight: bold; text-decoration: none;">wiki</ins>/<ins style="font-weight: bold; text-decoration: none;">Project:Quality_Assurance</ins>/<ins style="font-weight: bold; text-decoration: none;">BacktracesHow </ins>to get meaningful backtraces in Gentoo]" for more details about debug builds on Gentoo.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>== Debug Output ==</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>== Debug Output ==</div></td></tr>
</table>
Mamarok
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37423&oldid=prev
Mamarok: /* Gentoo */ more corrections on the Gentoo build flags
2014-04-18T15:58:40Z
<p><span dir="auto"><span class="autocomment">Gentoo: </span> more corrections on the Gentoo build flags</span></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 15:58, 18 April 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l22">Line 22:</td>
<td colspan="2" class="diff-lineno">Line 22:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> FEATURES="nostrip" emerge media-sound/amarok</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div> FEATURES="nostrip" emerge media-sound/amarok</div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> <del style="font-weight: bold; text-decoration: none;">are reasonable </del>and <del style="font-weight: bold; text-decoration: none;">do </del>not include <tt>-fomit-frame-pointer</tt>.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> <ins style="font-weight: bold; text-decoration: none;">contain either -g or -ggdb </ins>and <ins style="font-weight: bold; text-decoration: none;">it is preferred to </ins>not include <ins style="font-weight: bold; text-decoration: none;">flags like </ins><tt>-fomit-frame-pointer</tt><ins style="font-weight: bold; text-decoration: none;">. You can also use FEATURES="splitdebug" instead of nostrip, but don't have both at the same time</ins>.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.</div></td></tr>
</table>
Mamarok
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=37422&oldid=prev
Mamarok: editing the Gentoo section with correct information
2014-04-18T15:55:55Z
<p>editing the Gentoo section with correct information</p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 15:55, 18 April 2014</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l21">Line 21:</td>
<td colspan="2" class="diff-lineno">Line 21:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>=== Gentoo ===</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>=== Gentoo ===</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>If installing from ebuild, do the following:</div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;"> mkdir -p /etc/portage</del></div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"> </ins>FEATURES="nostrip" emerge media-sound/amarok</div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;"> echo "media-sound/amarok debug" >> /etc/portage/package.use</del></div></td><td colspan="2" class="diff-side-added"></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;"> </del>FEATURES="nostrip" emerge media-sound/amarok</div></td><td colspan="2" class="diff-side-added"></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> are reasonable and do not include <tt>-fomit-frame-pointer</tt>.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>In addition, make sure the <tt>CFLAGS</tt> are reasonable and do not include <tt>-fomit-frame-pointer</tt>.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
</table>
Mamarok
https://community.kde.org/index.php?title=Amarok/Development/DebuggingHowTo&diff=27806&oldid=prev
Mayankmadan: Created page with "Category:Amarok Category:Development Category:Development Normally, Amarok is expected to run correctly. The release versions have gone through betas and have been..."
2012-12-11T16:54:15Z
<p>Created page with "<a href="/Category:Amarok" title="Category:Amarok">Category:Amarok</a> <a href="/Category:Development" title="Category:Development">Category:Development</a> <a href="/Category:Development" title="Category:Development">Category:Development</a> Normally, Amarok is expected to run correctly. The release versions have gone through betas and have been..."</p>
<p><b>New page</b></p><div>[[Category:Amarok]] [[Category:Development]]<br />
[[Category:Development]]<br />
Normally, Amarok is expected to run correctly. The release versions have gone through betas and have been tested by many people; they rarely need debugging. In contrast, versions released in beta, along with versions taken straight from GIT, are quite likely to crash at some point. These crashes (and other bugs) are a lot easier to fix if the Developers know what the cause is. Enter debugging.<br />
<br />
<br />
== Preparing for Debugging ==<br />
In order to effectively debug Amarok, you need the debug symbols both for the program itself and for kdelibs and Qt. If compiling from source, then you need to notify the compiler to keep the debug symbols (by means of certain compiler flags). If you are using your distribution's binary packages, then you need to install the associated "debugging" packages.<br />
<br />
=== Compiling from source ===<br />
If you are compiling Amarok from source, then you need to tell the compiler to include the debug symbols in the build (they are discarded by default). When running cmake, include the flag '''<tt>-DCMAKE_BUILD_TYPE=debugfull</tt>'''. See [[2.0_Development_HowTo|here]] for more information about compilation.<br />
<br />
=== Using distribution packages ===<br />
If you are using your distribution's binary packages, they will often provide debugging information in a separate package. For example, if Amarok is contained in the <tt>amarok</tt> package, there will usually be an '''<tt>amarok-debug</tt>''' or '''<tt>amarok-dbg</tt>''' package, which you should install.<br />
<br />
In addition to Amarok's debug packages, you should install the '''kdelibs''' and '''Qt''' debug packages (most likely <tt>kdelibs-debug</tt> or <tt>kdelibs-dbg</tt> and <tt>qt-debug</tt>, <tt>qt4-debug</tt>, <tt>qt-dbg</tt> or <tt>qt4-dbg</tt>). These will provide additional debugging symbols, making your backtraces more valuable.<br />
<br />
These debugging packages may be contained in a separate repository that is not enabled by default. See your distribution's documentation for more information.<br />
<br />
Installing these packages will not slow Amarok down in any way. They will not have any effect until you actually try to debug Amarok in GDB, at which time they will turn a backtrace from a useless string of text and numbers into something developers can use to find and fix the problem.<br />
<br />
=== Gentoo ===<br />
If installing from ebuild, do the following:<br />
mkdir -p /etc/portage<br />
echo "media-sound/amarok debug" >> /etc/portage/package.use<br />
FEATURES="nostrip" emerge media-sound/amarok<br />
In addition, make sure the <tt>CFLAGS</tt> are reasonable and do not include <tt>-fomit-frame-pointer</tt>.<br />
<br />
For the best backtraces, you should set similar <tt>USE</tt> flags (as well as the <tt>nostrip</tt> option) for kdelibs and Qt 4.<br />
<br />
See also the Gentoo guide "[http://www.gentoo.org/proj/en/qa/backtraces.xml How to get meaningful backtraces in Gentoo]" for more details about debug builds on Gentoo.<br />
<br />
== Debug Output ==<br />
<br />
When Amarok is built in debug mode, it can produce a lot of console output about what it is doing. This can be useful for tracking down errors, but it slows Amarok down significantly, and so is disabled by default.<br />
<br />
To generate debugging output (e.g., if asked by a developer), you should quit Amarok completely ('''Quit''' on the Amarok menu, or right-click the tray icon and choose '''Quit'''), then run the following in a terminal:<br />
amarok --debug<br />
You should soon see a flood of debugging output. This output (usually the last 50 or so lines after reproducing a problem) can be attached (as a text file) to a bug report (as appropriate).<br />
<br />
Note: simply installing your distribution's associated debugging packages will NOT allow you to get debugging output of this form. However, it will allow you produce useful backtraces (see below).<br />
<br />
== Getting a Backtrace ==<br />
A backtrace is a list of the things that the program tried to do before it crashed. As it is likely that one of these things caused the crash, the backtrace is an invaluable tool to developers.<br />
<br />
=== GDB ===<br />
GDB ([http://www.gnu.org/software/gdb/ GNU's Debugger]) is a debugging tool that can be used to provide a backtrace. It comes prepackaged for many distributions, and can be installed that way, or can be compiled and installed from source. If you wish to use the binary provided by your distribution, the package is often called "gdb" and can be installed with your distribution's package management tool (<tt>apt-get</tt> for Debian/Ubuntu, <tt>yum</tt> for Redhat, etc.).<br />
<br />
Once GDB is installed, it can be run on Amarok:<br />
gdb amarok<br />
(In Amarok 2, there is no separate <tt>amarokapp</tt> binary any more, so you can debug against <tt>amarok</tt> directly.)<br />
<br />
You should see some info like this:<br />
Copyright 2004 Free Software Foundation, Inc.<br />
GDB is free software, covered by the GNU General Public License, and you are<br />
welcome to change it and/or distribute copies of it under certain conditions.<br />
Type &quot;show copying&quot; to see the conditions.<br />
There is absolutely no warranty for GDB. Type &quot;show warranty&quot; for details.<br />
This GDB was configured as &quot;i686-pc-linux-gnu&quot;...Using host libthread_db library &quot;/lib/libthread_db.so.1&quot;.<br />
(gdb)<br />
<br />
By default, KDE applications detach from the spawned shell. However, when this happens, GDB is unable to track the application. To prevent this behavior (called "forking"), KDE applications come with a '''<tt>--nofork</tt>''' flag. This flag needs to be set prior to running Amarok:<br />
(gdb) set args --nofork<br />
<br />
Amarok can now be started by:<br />
(gdb) run<br />
<br />
Now, try to repeat whatever originally caused Amarok to crash. At the point of the crash, GDB will freeze Amarok. Go back to the console GDB is running in, and type<br />
(gdb) bt<br />
<br />
This will cause GDB to output a backtrace. Note that it references specific functions, files, and line numbers. This backtrace should be attached to an associated bug report. If instead of something like the following you see lots of question marks, you likely do not have all of the necessary debugging symbols installed.<br />
Program received signal SIGSEGV, Segmentation fault.<br />
[Switching to Thread -1236346144 (LWP 1654)]<br />
0xb6f6179b in QString::latin1ToUnicode () from /usr/lib/libqt-mt.so.3<br />
(gdb) bt<br />
#0 0xb6f6179b in QString::latin1ToUnicode () from /usr/lib/libqt-mt.so.3<br />
#1 0xb6f62056 in QString::QString () from /usr/lib/libqt-mt.so.3<br />
#2 0xb50adb6a in HelixConfigDialog (this=0x881aea8, engine=0x86924a8, p=0x0) at helix-configdialog.cpp:215<br />
#3 0xb50a7acc in HelixEngine::configure (this=0x86924a8) at helix-engine.cpp:96<br />
#4 0x080c0177 in AmarokConfigDialog::soundSystemChanged (this=0x88a3660) at configdialog.cpp:307<br />
#5 0x080bfe34 in AmarokConfigDialog::updateWidgets (this=0x88a3660) at configdialog.cpp:235<br />
#6 0xb7684399 in KConfigDialog::show () from /usr/lib/libkdeui.so.4<br />
#7 0x0808f051 in App::slotConfigAmarok (this=0xbffff960, page=@0xbfffed20) at app.cpp:788<br />
#8 0x0808fc0d in App::qt_invoke (this=0xbffff960, _id=20, _o=0xbfffedb0) at app.moc:108<br />
#9 0xb6cae067 in QObject::activate_signal () from /usr/lib/libqt-mt.so.3<br />
#10 0xb6cadeae in QObject::activate_signal () from /usr/lib/libqt-mt.so.3<br />
#11 0xb754d88b in KAction::activated () from /usr/lib/libkdeui.so.4<br />
#12 0xb754cffa in KAction::slotActivated () from /usr/lib/libkdeui.so.4<br />
#13 0xb754d2be in KAction::slotButtonClicked () from /usr/lib/libkdeui.so.4<br />
#14 0xb754dba1 in KAction::qt_invoke () from /usr/lib/libkdeui.so.4<br />
#15 0xb6cae067 in QObject::activate_signal () from /usr/lib/libqt-mt.so.3<br />
#16 0xb75f7bc5 in KToolBarButton::buttonClicked () from /usr/lib/libkdeui.so.4<br />
#17 0xb75f63ba in KToolBarButton::mouseReleaseEvent () from /usr/lib/libkdeui.so.4<br />
#18 0xb6ce17e9 in QWidget::event () from /usr/lib/libqt-mt.so.3<br />
#19 0xb6c56370 in QApplication::internalNotify () from /usr/lib/libqt-mt.so.3<br />
#20 0xb6c55ac7 in QApplication::notify () from /usr/lib/libqt-mt.so.3<br />
#21 0xb7270ab5 in KApplication::notify () from /usr/lib/libkdecore.so.4<br />
#22 0xb6bef12f in QETWidget::translateMouseEvent () from /usr/lib/libqt-mt.so.3<br />
#23 0xb6bece1c in QApplication::x11ProcessEvent () from /usr/lib/libqt-mt.so.3<br />
#24 0xb6c02ec2 in QEventLoop::processEvents () from /usr/lib/libqt-mt.so.3<br />
#25 0xb6c6774c in QEventLoop::enterLoop () from /usr/lib/libqt-mt.so.3<br />
#26 0xb6c6760e in QEventLoop::exec () from /usr/lib/libqt-mt.so.3<br />
#27 0xb6c5657b in QApplication::exec () from /usr/lib/libqt-mt.so.3<br />
#28 0x081a6e55 in main (argc=1, argv=0xbffffae4) at main.cpp:92<br />
<br />
==== Debugging an already running instance of Amarok ====<br />
It can be quite difficult to reproduce some bugs, such that it is easier to simply debug when Amarok crashes initially. To do this, try the following in a terminal when Amarok crashes:<br />
gdb `which amarok` -p `pidof amarok`<br />
(gdb) thread apply all bt<br />
You will then get a backtrace, which you should submit in your bug report.</div>
Mayankmadan