Le 13 déc. 2012 à 22:32, Basile Starynkevitch <
bas...@starynkevitch.net> a écrit :
> On Thu, Dec 13, 2012 at 10:13:47PM +0100, Romain Geissler wrote:
>> Hi
>>
>> Le 13 déc. 2012 à 21:47, Basile Starynkevitch <
bas...@starynkevitch.net> a écrit :
>>> So I really want to have a cc1 which is compiled with -g -O2; it is the cc1 of the distribution.
>>>
>>> The point is that getting a cc1 with debugging information in Debian (or Mandriva/Maegis) is not simple (at least to me). See my suggestion on
http://lists.debian.org/debian-gcc/2012/12/msg00049.html
>>
>> A debug package is indeed a good suggestion. But right know to solve your problem ASAP, why don't you just build gcc with the -g flag?
>
>
> Actually, I found the bug on my MELT branch which is built with CFLAGS='-O -g'
>
> But really, I believe that for all GCC plugin developers, having a debug variant of gcc (& cc1 & cc1plus ....) should be helpful. This is not specific to MELT.
Yeah sure, and i don't know why package delivered in Linux distros like Debian don't always come with there -dbg counter part (ie stripped elf binaries containing all DWARF debug information, that GDB is able to combine to the regular binary).
> Requiring GCC plugin developers to compile the GCC compiler themselves is
> IMHO sort-of defeating the plugin idea….
In the very particular case of GCC, i think that compiling it by yourself is inevitable, at least it was at the time i used it.
> (Actually, I tend to believe that any free software which has plugins -i.e. which use dlopen against external shared objects- should be packaged in debug variants. It is not only libraries which should have -as they already do on Debian- a debug variant, it is every software accepting plugins).
Softwares that aren't plugin-aware deserve debug symbols as much as softwares that loads plugins: you'ill be glad to have them when your process core dump'ed even if it didn't dlopen some file. You can also remove the "free" part of your assertion, i investigate core dumps generated by proprietary software every days, and believe me, debug symbols are welcomed too in proprietary binaries. It's simple, any ELF-distributed software should come with both --strip-debug and --keep-only-debug ELF files, with a --build-id to uniquely identify a given binary and help GDB to find the right corresponding debug symbol ELF file.
R