Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 29 Feb 1996 23:27:57 +0100
From:      tege@matematik.su.se
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   bin/1053: /bin/sh problem with new GCC (snapshot for 2.8)
Message-ID:  <199602292227.XAA05612@noisy.matematik.su.se>
Resent-Message-ID: <199602292330.PAA19210@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         1053
>Category:       bin
>Synopsis:       /bin/sh problem with new GCC (snapshot for 2.8)
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Feb 29 15:30:02 PST 1996
>Last-Modified:
>Originator:     Torbjorn Granlund
>Organization:
TMG Datakonsult
>Release:        FreeBSD 2.1-STABLE i386
>Environment:
Hardly relevant.

>Description:

The /bin/sh of FreeBSD doesn't work as on other systems, or like bash.
The problem seems to be with the builtin `eval'.

>How-To-Repeat:

bash$ foo=tomte; var=foo; echo `eval echo \\$$var`
tomte
sh$ foo=tomte; var=foo; echo `eval echo \\$$var`
5578var

>Fix:
	
I don't know of any fix that is compatible with a non-flawed sh.  A fix
would be desirable if you want your users that install GCC 2.8 to avoid
problems.  Just imagine the flood of bug reports that you will get...

If you provide me with a (reasonable) fix, I will put it in to the gcc
repository in time for 2.8.
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199602292227.XAA05612>