Bash 4 b0rken?

DutchDaemon

Administrator
Staff member
Administrator
Moderator
Developer

Reaction score: 2,780
Messages: 11,279

Interesting, my bash scripts broke when I went to bash 4 ..

Code:
date=$(/bin/date)
bash: command substitution: line 17: syntax error near unexpected token `)'
bash: command substitution: line 17: `/bin/date)'
According to the manual, there's (still) nothing wrong with it:

Code:
Command Substitution
       Command substitution allows the output of a command to replace the com-
       mand name.  There are two forms:


              [B]$(command)[/B]
       or
              `command`
I've seen this on several machines now (all 7.1-STABLE). Wonder if this is a port(ing) issue, or might bash be broken on other OS platforms? As my bash scripts are usually valid sh syntax, changing the bangpath to /bin/sh is no big deal, of course, but still ..
 

plamaiziere

Active Member

Reaction score: 40
Messages: 184

DutchDaemon said:
Interesting, my bash scripts broke when I went to bash 4 ..

I've seen this on several machines now (all 7.1-STABLE). Wonder if this is a port(ing) issue, or might bash be broken on other OS platforms? As my bash scripts are usually valid sh syntax, changing the bangpath to /bin/sh is no big deal, of course, but still ..
There is a discussion of this issue on the Freebsd ports@ mailing list. It seems there is a problem with yacc under FreeBSD.

See this thread:
http://groups.google.com/group/mailing.freebsd.ports/browse_thread/thread/2480ba468d49cc6e/8e0411e9f149adaf?lnk=raot
 
OP
OP
DutchDaemon

DutchDaemon

Administrator
Staff member
Administrator
Moderator
Developer

Reaction score: 2,780
Messages: 11,279

Thanks, yes, that looks like it. I wanted to hold off on a PR while I waited for some confirmation, but I see it's already 'out there'.
 
OP
OP
DutchDaemon

DutchDaemon

Administrator
Staff member
Administrator
Moderator
Developer

Reaction score: 2,780
Messages: 11,279

Looks like today's update (version 4.0.10(2)-release) sussed it.
 

vivek

Aspiring Daemon

Reaction score: 194
Messages: 805

I've just pushed update...and it is now compiling .. let us hope for the best!
 
Top