From: Sergio Durigan Junior <sergiodj@redhat.com>
To: Christian Groessler <chris@groessler.org>
Cc: gdb@sourceware.org
Subject: Re: [patch]: testsuite: run bash instead of sh when using brace expansion
Date: Wed, 15 May 2013 23:25:00 -0000 [thread overview]
Message-ID: <m3hai3kes8.fsf@redhat.com> (raw)
In-Reply-To: <51936596.8010205@groessler.org> (Christian Groessler's message of "Wed, 15 May 2013 12:38:14 +0200")
On Wednesday, May 15 2013, Christian Groessler wrote:
> I had some testsuite failures in gdb.dwarf2/dw2-dir-file-name.exp,
> because /bin/sh on my system doesn't support brace expansion.
> I'm using Debian, where /bin/sh is in fact dash. I tried /bin/sh on
> Solaris (9), too, and it also doesn't support brace expansion.
>
> This patch changes dw2-dir-file-name.exp to use bash instead of sh.
Hey, thanks for the patch.
Next time, please make sure to send patches to
gdb-patches@sourceware.org. Also I don't see you on gdb/MAINTAINERS, do
you have copyright assignment for GDB? This patch is simple enough to
go in without a copyright assignment, but if you intend to send more
patches please let me know (in off) and I can get you started on the
process.
> gdb/testsuite:
> 2013-05-15 Christian Groessler <chris@groessler.org>
Two spaces between name and e-mail.
>
> * gdb.dwarf2/dw2-dir-file-name.exp: Use bash instead of sh, since
> brace expansion is not available in sh.
^^^^^^^^
You're using spaces instead of a TAB here.
> Index: gdb.dwarf2/dw2-dir-file-name.exp
> ===================================================================
> RCS file: /cvs/src/src/gdb/testsuite/gdb.dwarf2/dw2-dir-file-name.exp,v
> retrieving revision 1.4
> diff -u -p -r1.4 dw2-dir-file-name.exp
> --- gdb.dwarf2/dw2-dir-file-name.exp 15 Mar 2013 01:41:28 -0000 1.4
> +++ gdb.dwarf2/dw2-dir-file-name.exp 15 May 2013 10:27:20 -0000
> @@ -322,10 +322,10 @@ if { [gdb_compile "${asmsrcfile} ${srcdi
> return -1
> }
>
> -remote_exec host "sh -c \"rm -f
> ${srcabsdir}{/rdir,}{/xdir,}{/compdir,}{/ldir,}{/fdir,}/${srctmpfile}\""
> -remote_exec host "sh -c \"rmdir
> ${srcabsdir}{/rdir,}{/xdir,}{/compdir,}{/ldir,}{/fdir,}\""
> -remote_exec host "sh -c \"mkdir
> ${srcabsdir}{,/rdir}{,/xdir}{,/compdir}{,/ldir}{,/fdir}\""
> -remote_exec host "sh -c \"for d in
> ${srcabsdir}{,/rdir}{,/xdir}{,/compdir}{,/ldir}{,/fdir};do cp
> ${srcdir}/${subdir}/${srcfile} \\\$d/${srctmpfile}; done\""
> +remote_exec host "bash -c \"rm -f
> ${srcabsdir}{/rdir,}{/xdir,}{/compdir,}{/ldir,}{/fdir,}/${srctmpfile}\""
> +remote_exec host "bash -c \"rmdir
> ${srcabsdir}{/rdir,}{/xdir,}{/compdir,}{/ldir,}{/fdir,}\""
> +remote_exec host "bash -c \"mkdir
> ${srcabsdir}{,/rdir}{,/xdir}{,/compdir}{,/ldir}{,/fdir}\""
> +remote_exec host "bash -c \"for d in
> ${srcabsdir}{,/rdir}{,/xdir}{,/compdir}{,/ldir}{,/fdir};do cp
> ${srcdir}/${subdir}/${srcfile} \\\$d/${srctmpfile}; done\""
>
> clean_restart ${testfile}
I am not sure what others think, but instead of depending on bash (which
may not be available on all platforms), I'd rather rewrite those
commands to avoid brace expansions at all, thus making them compatible
with sh. I am not a maintainer however, so you'd better wait for one
until you do that.
Thanks,
--
Sergio
next prev parent reply other threads:[~2013-05-15 23:25 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-15 10:38 Christian Groessler
2013-05-15 11:03 ` Luis Machado
2013-05-15 11:06 ` Christian Groessler
2013-05-15 14:55 ` Tom Tromey
2013-05-15 23:25 ` Sergio Durigan Junior [this message]
2013-05-17 7:45 ` Christian Groessler
2013-05-17 8:13 ` Joel Brobecker
2013-05-17 16:44 ` Tom Tromey
2013-05-17 22:57 ` Christian Groessler
2013-05-20 15:16 ` Tom Tromey
2013-05-21 7:27 ` Christian Groessler
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=m3hai3kes8.fsf@redhat.com \
--to=sergiodj@redhat.com \
--cc=chris@groessler.org \
--cc=gdb@sourceware.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