Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Joel Brobecker <brobecker@adacore.com>
Cc: Hans-Peter Nilsson <hans-peter.nilsson@axis.com>,
	       gdb-patches@sourceware.org
Subject: Re: build error for mn10300-elf sim with your recent commit
Date: Fri, 15 Jun 2012 21:15:00 -0000	[thread overview]
Message-ID: <4FDBA5BC.8030300@redhat.com> (raw)
In-Reply-To: <20120615195238.GB18729@adacore.com>

On 06/15/2012 08:52 PM, Joel Brobecker wrote:

>> I'm confused.  Nothing outside of bfd should be including bfd/sysdep.h.
>> Is that what is happening?
> 
> Yep.
> 
> And for the record, I did try to compile without including sysdep.h,
> and it built just fine. But I am assuming that there are some hosts
> that this is going to break, and since I can't test the change on
> every single hosts out there...

Only one way to find out.  :-)

$ 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.

-- 
Pedro Alves


  reply	other threads:[~2012-06-15 21:15 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-15 18:46 Hans-Peter Nilsson
2012-06-15 18:56 ` Joel Brobecker
2012-06-15 19:15   ` Joel Brobecker
2012-06-15 19:39     ` Pedro Alves
2012-06-15 19:52       ` Joel Brobecker
2012-06-15 21:15         ` Pedro Alves [this message]
2012-06-16  4:56           ` Mike Frysinger
2012-06-16  5:09             ` Hans-Peter Nilsson
2012-06-17 18:57               ` Hans-Peter Nilsson
2012-06-17 23:34             ` Mike Frysinger
2012-06-18 18:39           ` Joel Brobecker
2012-06-15 20:37     ` Hans-Peter Nilsson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4FDBA5BC.8030300@redhat.com \
    --to=palves@redhat.com \
    --cc=brobecker@adacore.com \
    --cc=gdb-patches@sourceware.org \
    --cc=hans-peter.nilsson@axis.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox