From: Frans Pop <elendil@planet.nl>
To: maximilian attems <max@stro.at>
Cc: linux-kbuild@vger.kernel.org, sam@ravnborg.org,
Andres Salomon <dilinger@debian.org>
Subject: Re: [PATCH] kbuild: deb-pkg fix install scripts for posix sh
Date: Wed, 8 Jul 2009 09:28:29 +0200 [thread overview]
Message-ID: <200907080928.30733.elendil@planet.nl> (raw)
In-Reply-To: <1246817854-27396-1-git-send-email-max@stro.at>
On Sunday 05 July 2009, maximilian attems wrote:
> bash versus dash and posh disagree on expanding $@ within double
> quotes: export x="$@"
> see http://bugs.debian.org/381091 for details
> just use the arglist with $*.
[...]
> diff --git a/scripts/package/builddeb b/scripts/package/builddeb
> index b19f1f4..8b357b0 100644
> --- a/scripts/package/builddeb
> +++ b/scripts/package/builddeb
> @@ -89,7 +89,7 @@ for script in postinst postrm preinst prerm ; do
> set -e
>
> # Pass maintainer script parameters to hook scripts
> -export DEB_MAINT_PARAMS="\$@"
> +export DEB_MAINT_PARAMS="\$*"
Although blindly replacing "$@" by "$*" can cause regressions because they
*do* expand differently [1], I do not see a problem in this case given
that AFAIK Debian maintainer scripts only pass parameters without
whitespace in them.
Acked-by: Frans Pop <elendil@planet.nl>
[1] $@ preserves quoting; try the following:
cat <<EOF >test.fjp
#! /bin/bash
for i in "$*"; do echo $i; done
for i in "$@"; do echo $i; done
EOF
chmod +x test.fjp
./test.fjp This "is a" test
next prev parent reply other threads:[~2009-07-08 7:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-07-05 18:17 [PATCH] kbuild: deb-pkg fix install scripts for posix sh maximilian attems
2009-07-08 7:28 ` Frans Pop [this message]
2009-07-09 21:49 ` Andres Salomon
2009-07-17 21:03 ` Sam Ravnborg
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=200907080928.30733.elendil@planet.nl \
--to=elendil@planet.nl \
--cc=dilinger@debian.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=max@stro.at \
--cc=sam@ravnborg.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