build error for mn10300-elf sim with your recent commit
Mike Frysinger
vapier@gentoo.org
Sat Jun 16 04:56:00 GMT 2012
On Friday 15 June 2012 17:14:36 Pedro Alves wrote:
> $ cd sim
> $ find . -name "*.[hc]" | xargs grep sysdep.h
> ./d10v/interp.c:#include "sysdep.h"
> ./cr16/interp.c:#include "sysdep.h"
> ./moxie/interp.c:#include "sysdep.h"
> ./mcore/interp.c:#include "sysdep.h"
> ./sh64/sh-desc.c:#include "sysdep.h"
> ./mn10300/interp.c:#include "sysdep.h"
> ./microblaze/interp.c:#include "sysdep.h"
> ./cris/traps.c:/* From ld/sysdep.h. */
> ./cris/cris-desc.c:#include "sysdep.h"
>
> One's a comment. And,
>
> $ find . -name sysdep.h
> ./moxie/sysdep.h
> ./mcore/sysdep.h
> ./microblaze/sysdep.h
>
> So that leaves:
>
> ./d10v/interp.c:#include "sysdep.h"
> ./cr16/interp.c:#include "sysdep.h"
> ./sh64/sh-desc.c:#include "sysdep.h"
> ./mn10300/interp.c:#include "sysdep.h"
> ./cris/cris-desc.c:#include "sysdep.h"
>
> I don't see these ports really caring for hosts other than
> GNU/Linux and Windows.
>
> It is wrong to include bfd/sysdeps.h, practically as much as it
> is wrong to include bfd/config.h. bfd/sysdeps.h HAVE_FOOs depend on
> bfd's own autoconfigury, not the sim's.
>
> Consolidating all the commonality between all these sysdep.h files
> sound nice, though I'm not sure how much work that is.
i'd wager that it's more of a copy & paste error between seems. one of the
really old ones had an interp.c that included sysdep.h, and when someone
started a new port, they copied an existing one. the local sysdep.h wasn't
needed, but the build still worked, so no one looked further. the sim code
base isn't exactly a shining glory of how things should be done :).
i vote for deleting all sysdep.h inclusions where the port doesn't have a
local sysdep.h.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20120616/7d11caa9/attachment.sig>
More information about the Gdb-patches
mailing list