1 |
Nikos Chantziaras skrev: |
2 |
> On 09/06/2009 11:22 AM, Erik wrote: |
3 |
>> Nikos Chantziaras skrev: |
4 |
>>> On 09/06/2009 09:43 AM, Erik wrote: |
5 |
>>>> I have emerged glibc with "debug -glibc-omitfp" and restarted the |
6 |
>>>> system. But when I execute "valgrind |
7 |
>>>> /usr/lib/mozilla-firefox/firefox" I |
8 |
>>>> only see things like this: |
9 |
>>>> Invalid read of size 4 |
10 |
>>>> at 0x4018620: (within /lib/ld-2.9.so) |
11 |
>>>> |
12 |
>>>> No filename:linenumber here. What does it take to get debug symbols |
13 |
>>>> from |
14 |
>>>> /lib/ld-2.9.so? |
15 |
>>> |
16 |
>>> Don't emerge with "debug -glibc-omitfp". Emerge with "splitdebug" in |
17 |
>>> FEATURES. |
18 |
>> Done: |
19 |
>> Conditional jump or move depends on uninitialised value(s) |
20 |
>> at 0x400C0AC: _dl_relocate_object (in /lib/ld-2.9.so) |
21 |
>> |
22 |
>> Now it at least shows the function name. But still no |
23 |
>> filename:linenumber. Maybe I need "debug" for that after all? |
24 |
> |
25 |
> Just "-g" in CFLAGS. |
26 |
|
27 |
Ok, I added this to /etc/portage/env/sys-libs/glibc-2.9_p20081201-r2: |
28 |
pre_pkg_setup() { |
29 |
if ! hasq -g $CFLAGS ; then |
30 |
elog "Adding -g to CFLAGS for $PN-$PV to locate errors |
31 |
reported by Valgrind." |
32 |
CFLAGS="$CFLAGS -g" |
33 |
fi |
34 |
} |
35 |
|
36 |
|
37 |
Then I emerged glibc. It printed the elog message that I added and |
38 |
included -g in the compile commands. Then I restarted the system. But |
39 |
still no filename:linenumber in Valgrind. |