From: Andrew Cagney <ac131313@cygnus.com>
To: Keith Seitz <keiths@cygnus.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] gdb-events.sh portability update
Date: Thu, 07 Jun 2001 12:24:00 -0000 [thread overview]
Message-ID: <3B1FD4D1.2070401@cygnus.com> (raw)
In-Reply-To: <Pine.GSO.4.33.0106071113051.10814-100000@ryobi.cygnus.com>
> Hi,
>
> gdb-events.sh will only run on a linux box (maybe BSD, too). It does not
> run on Solaris, SunOS, or almost any other host OS because the script does
> things like:
>
> 1) Assumes that /bin/sh's "if" has built-in logical not.
>
> if ! test -r file_exits
> then
> # stuf
> fi
>
> and
>
> if ! diff ...
> then
> # stuff
> fi
>
> 2) Some commands assume that IFS is a space:
>
> for arg in `echo ${args} | tr '[,]' '[ ]'`; do
> # stuff
> done
>
> At the top of this script, we explicitly set it to ":". This bug prevents
> using event notifiers with more than one argument, i.e.,
>
> f:void:my_new_event_notifier:int a, void *b:a, b
>
> would produce output like:
>
> void
> my_new_event_notifier_event (int a, void *b)
> {
> if (gdb_events_debug)
> fprintf_unfiltered (gdb_stdlog, "my_new_event_notifier_event\n");
> if (!current_event_hooks->my_new_event_notifier)
> return;
> current_event_hooks->my_new_event_notifier (a b);
> }
>
> 3) Uses "echo" to put strings containing special characters (e.g. \n) into
> files:
>
> echo ""
> echo "fprintf_unfiltered (gdb_stderr, \"This is an error\\n\");"
Yes, ok. On the last one, gdbarch.sh now uses printf but it doesn't
matter either way.
Andrew
next prev parent reply other threads:[~2001-06-07 12:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-06-07 11:30 Keith Seitz
2001-06-07 12:24 ` Andrew Cagney [this message]
2001-06-07 12:43 ` Keith Seitz
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=3B1FD4D1.2070401@cygnus.com \
--to=ac131313@cygnus.com \
--cc=gdb-patches@sources.redhat.com \
--cc=keiths@cygnus.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