From: Roman Neuhauser <neuhauser@sigpipe.cz>
To: Helmut Jarausch <jarausch@igpm.rwth-aachen.de>
Cc: zsh-workers@sunsite.dk
Subject: Re: expert help sought [offtopic]
Date: Mon, 23 Oct 2006 12:04:25 +0000 [thread overview]
Message-ID: <20061023120425.GA49995@dagan.sigpipe.cz> (raw)
In-Reply-To: <tkrat.f70905462444c4ef@igpm.rwth-aachen.de>
# jarausch@igpm.rwth-aachen.de / 2006-10-23 08:55:47 +0200:
> I am desparately in need for help on the following piece of
> code within a 'configure' file.
> It's run under '/bin/sh' which is a symlink to '/bin/bash'
> but I known that real experts are reading this mailing list.
>
> The following code fails in the 2nd line with
> syntax error near unexpected token `('
> ../htmlwidget2/configure: line 4957: ` case `(ac_space=' '; set | grep ac_space) 2>&1` in'
My experience from porting FreeBSD's periodic(8) to RedHat suggests
that bash can't parse quite a bit of valid POSIX sh syntax, it loves
to get lost in parentheses and subshells. Try moving the subshell
into a separate statement.
> here are the lines 4956 ff
>
> (set) 2>&1 |
> case `(ac_space=' '; set | grep ac_space) 2>&1` in
> *ac_space=\ *)
> # `set' does not quote correctly, so add quotes (double-quote substitution
> # turns \\\\ into \\, and sed turns \\ into \).
> sed -n \
> -e "s/'/'\\\\''/g" \
> -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
> ;;
> *)
> # `set' quotes correctly as required by POSIX, so do not add quotes.
> sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
> ;;
> esac >> confcache
>
> I admit I don't really understand what's going on and even what's meant
> to be going on.
The code is meant to write config.cache.
--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man. You don't KNOW.
Cause you weren't THERE. http://bash.org/?255991
prev parent reply other threads:[~2006-10-23 10:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-23 6:55 Helmut Jarausch
2006-10-23 12:04 ` Roman Neuhauser [this message]
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=20061023120425.GA49995@dagan.sigpipe.cz \
--to=neuhauser@sigpipe.cz \
--cc=jarausch@igpm.rwth-aachen.de \
--cc=zsh-workers@sunsite.dk \
/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.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).