This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] fix PR symtab/15597


On Tue, 8 Oct 2013, Tom Tromey wrote:
> >>>>> "Tom" == Tom Tromey <tromey@redhat.com> writes:
>
> Tom> This patch fixes gdb PR symtab/15597.
> Tom> The bug is that the .gnu_debugaltlink section includes the build-id of
> Tom> the alt file, but gdb does not use it.
>
> I'm checking in an updated version of this patch now.
> The only change is to fix the patch for the objfile_name change in gdb.
> I rebuilt and regtested this on x86-64 Fedora 18.
>
> Tom
>
>     	* bfd-in2.h: Rebuild.

> diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
> index 41f7a68..67eb7da 100644
> --- a/bfd/bfd-in2.h
> +++ b/bfd/bfd-in2.h
> @@ -1067,7 +1067,8 @@ unsigned long bfd_calc_gnu_debuglink_crc32
>
>  char *bfd_get_debug_link_info (bfd *abfd, unsigned long *crc32_out);
>
> -char *bfd_get_alt_debug_link_info (bfd *abfd, unsigned long *crc32_out);
> +char *bfd_get_alt_debug_link_info (bfd * abfd, size_t *buildid_len,
> +    bfd_byte **buildid_out);

Sorry, but this broke many simulator builds; it's the first
size_t in bfd-in2.h and neither it nor all its clients include
stddef.h.  Could you consider using bfd_size_type instead?

Example, frv-elf:
...
gcc -DHAVE_CONFIG_H   -DWITH_DEFAULT_MODEL='"fr500"'  -DPROFILE=1 -DWITH_PROFILE=-1   -DWITH_ALIGNMENT=STRICT_ALIGNMENT  -DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN -DWITH_ENVIRONMENT=ALL_ENVIRONMENT  -DWITH_HW=1 -DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN -DDEFAULT_INLINE=0    -DWITH_SCACHE=16384          -I. -I/tmp/hpautotest-sim/src/sim/frv -I../common -I/tmp/hpautotest-sim/src/sim/frv/../common -I../../include -I/tmp/hpautotest-sim/src/sim/frv/../../include -I../../bfd -I/tmp/hpautotest-sim/src/sim/frv/../../bfd -I../../opcodes -I/tmp/hpautotest-sim/src/sim/frv/../../opcodes  -g -O2 -c -o cgen-utils.o -MT cgen-utils.o -MMD -MP -MF .deps/cgen-utils.Tpo /tmp/hpautotest-sim/src/sim/frv/../common/cgen-utils.c
In file included from /tmp/hpautotest-sim/src/sim/frv/../common/cgen-utils.c:21:0:
../../bfd/bfd.h:1070:48: error: unknown type name 'size_t'
make[3]: Leaving directory `/tmp/hpautotest-sim/frv-elf/sim/frv'
make[3]: *** [cgen-utils.o] Error 1
make[2]: Leaving directory `/tmp/hpautotest-sim/frv-elf/sim'
make[2]: *** [all] Error 1

Others (not exhaustive):
cris-elf, h8300-elf, iq2000-elf, m32r-elf, mips-elf, mn10300-elf

brgds, H-P
PS: how about that src-release patch?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]