Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Hans-Peter Nilsson <hp@bitrange.com>
To: Mike Frysinger <vapier@gentoo.org>
Cc: gdb-patches@sourceware.org
Subject: Finalizing fix committed for "[PATCH] sim: make sure to include strsignal prototype"
Date: Sat, 24 Mar 2012 10:55:00 -0000	[thread overview]
Message-ID: <alpine.BSF.2.00.1203240534250.57633@dair.pair.com> (raw)
In-Reply-To: <alpine.BSF.2.00.1203230114540.31229@dair.pair.com>

On Fri, 23 Mar 2012, Hans-Peter Nilsson wrote:
> On Fri, 23 Mar 2012, Mike Frysinger wrote:
> > Before POSIX standardized strsignal(), old systems would hide the
> > prototype unless the normal extension defines were enabled.  So use
> > the AC_USE_SYSTEM_EXTENSIONS helper for that.
> >
> > Then make sure we include string.h ourselves in nrun.c rather than
> > relying on implicit includes via other sim headers.
> >
> > Signed-off-by: Mike Frysinger <vapier@gentoo.org>
> >
> > sim/common/:
> > 2012-03-23  Mike Frysinger  <vapier@gentoo.org>
> >
> > 	* acinclude.m4 (SIM_AC_COMMON): Call AC_USE_SYSTEM_EXTENSIONS.
> > 	* nrun.c: Include string.h/strings.h.
> > 	* aclocal.m4, config.in, configure: Regenerate.

This patch was missing the critical include of cconfig.h so you
should still have seen warnings about implicit declarations of
strsignal when testing.  On the other hand, I didn't notice the
missing piece when I reviewed, so as penance I tested and
committed the following for you.

Tested no regressions (some errors present for some targets but
none the worse) on i686-linux cross to (target+board)
cris-elf+cris-sim, frv-elf+frv-sim, sh64-elf+sh64-sim,
m32r-elf+m32r-sim mips-elf+mips-sim, v850-elf+v850-sim,
sh-elf+sh-sim, arm-elf+arm-sim.

I built and and started testing for bfin-elf+unix but got a lot
of assembly errors for values out-of-range (HEAD binutils,
perhaps the assembler isn't tested on a 32-bit host?) for
assembly-code tests and also apparently a compiler is not
optional as for cris-sim, but required, causing spurious errors.

FWIW, all sim tests fail linking for cr16-elf+cr16-sim, maybe my
locally added baseboard is out of date.

My sim autotester is happy again after this change; thankfully
it's ignorant of the multitude of missing-declaration warnings
exposed lately.  BTW the next week I'm not available for
reviewing, but I'd prefer to have a look at further patches if
there's more to come, particularly changes of general nature.

	* nrun.c: Add #ifdef HAVE_CONFIG_H and associated includes stanza
	missing in last change.

Index: nrun.c
===================================================================
RCS file: /cvs/src/src/sim/common/nrun.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -p -u -r1.17 -r1.18
--- nrun.c	24 Mar 2012 05:38:35 -0000	1.17
+++ nrun.c	24 Mar 2012 09:31:09 -0000	1.18
@@ -14,6 +14,12 @@ GNU General Public License for more deta
 You should have received a copy of the GNU General Public License
 along with this program.  If not, see <http://www.gnu.org/licenses/>.  */

+/* Need to be before general includes, to pick up e.g. _GNU_SOURCE.  */
+#ifdef HAVE_CONFIG_H
+#include "cconfig.h"
+#include "tconfig.h"
+#endif
+
 #include <signal.h>

 /* For strsignal.  */

brgds, H-P


  parent reply	other threads:[~2012-03-24 10:55 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-23  4:23 [PATCH] sim: make sure to include strsignal prototype Mike Frysinger
2012-03-23  4:35 ` Mike Frysinger
2012-03-23  5:24 ` Hans-Peter Nilsson
2012-03-23 15:43   ` Mike Frysinger
2012-03-23 22:12     ` Hans-Peter Nilsson
2012-03-23 22:43       ` Mike Frysinger
2012-03-24  5:34     ` Mike Frysinger
2012-03-24  4:12   ` Mike Frysinger
2012-03-24  5:53     ` Hans-Peter Nilsson
2012-03-24  6:12       ` Mike Frysinger
2012-03-24  6:49         ` Hans-Peter Nilsson
2012-03-24 18:18           ` Mike Frysinger
2012-03-24 10:55   ` Hans-Peter Nilsson [this message]
2012-03-24 18:24     ` Finalizing fix committed for "[PATCH] sim: make sure to include strsignal prototype" Mike Frysinger
2012-03-24 20:55       ` Hans-Peter Nilsson
2012-03-25  8:14         ` Mike Frysinger
2012-03-25 14:03           ` Hans-Peter Nilsson
2012-03-25  7:40       ` Mike Frysinger
2012-03-25  7:54         ` Mike Frysinger
2012-03-25 14:26           ` Hans-Peter Nilsson
2012-03-24  5:39 ` [PATCH] sim: make sure to include strsignal prototype Mike Frysinger

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=alpine.BSF.2.00.1203240534250.57633@dair.pair.com \
    --to=hp@bitrange.com \
    --cc=gdb-patches@sourceware.org \
    --cc=vapier@gentoo.org \
    /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