[RFA] Allow binutils compilation for mingw64 with --enable-targets=all
Kai Tietz
ktietz70@googlemail.com
Sat Mar 26 08:48:00 GMT 2011
More information about the Binutils mailing list
Sat Mar 26 08:48:00 GMT 2011
- Previous message (by thread): [RFA] Allow binutils compilation for mingw64 with --enable-targets=all
- Next message (by thread): [RFA] Allow binutils compilation for mingw64 with --enable-targets=all
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
2011/3/25 Pierre Muller <pierre.muller@ics-cnrs.unistra.fr>: > Trying to compile Binutils with --enable-targets=all > for mingw64 leads to this error: > x86_64-w64-mingw32-gcc -DHAVE_CONFIG_H -I. -I../../src/binutils -I. > -I../../src > /binutils -I../bfd -I../../src/binutils/../bfd > -I../../src/binutils/../include - > I./../intl -DLOCALEDIR="\"/usr/local/share/locale\"" > -Dbin_dummy_emulation=bin_v > anilla_emulation -W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow > -Wn > o-format -Werror -gstabs+ -O0 -D__USE_MINGW_ACCESS -MT coffdump.o -MD -MP > -MF .d > eps/coffdump.Tpo -c -o coffdump.o ../../src/binutils/coffdump.c > cc1: warnings being treated as errors > ../../src/binutils/coffdump.c: In function 'dump_coff_scope': > ../../src/binutils/coffdump.c:368:37: error: cast from pointer to integer of > dif > ferent size > make[2]: *** [coffdump.o] Error 1 > > > The patch below fixes that compilation error. > > > > Pierre Muller > GDB pascal language maintainer > > 2011-03-25 Pierre Muller <muller@ics.u-strasbg.fr> > > * coffdump.c (dump_coff_scope): Use double typecast for pointer P > to allow compilation for all targets. > > Index: coffdump.c > =================================================================== > RCS file: /cvs/src/src/binutils/coffdump.c,v > retrieving revision 1.18 > diff -u -p -r1.18 coffdump.c > --- coffdump.c 5 Jul 2007 16:54:45 -0000 1.18 > +++ coffdump.c 25 Mar 2011 21:34:07 -0000 > @@ -365,7 +365,7 @@ dump_coff_scope (struct coff_scope *p) > if (p) > { > tab (1); > - printf ("List of blocks %lx ",(unsigned long) p); > + printf ("List of blocks %" BFD_VMA_FMT "x ",(bfd_vma) (uintptr_t) p); > > if (p->sec) > printf( " %s %x..%x", p->sec->name,p->offset, p->offset + p->size > -1); > > I can't approve this. Yes, thanks for catching this. But is it really necessary to do the uintptr_t cast before the final bfd_vma cast? bfd_vma should be always >= sizeof (void *), isn't it? Kai
- Previous message (by thread): [RFA] Allow binutils compilation for mingw64 with --enable-targets=all
- Next message (by thread): [RFA] Allow binutils compilation for mingw64 with --enable-targets=all
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list