build.sh broken on Solaris 10

Gaetan Nadon memsize at videotron.ca
Thu Nov 11 14:03:18 PST 2010


On Thu, 2010-11-11 at 14:40 -0600, Pat Kane wrote:

> The following build.sh  lines do not work with Solaris 10 /bin/sh
> 
>       local rtn
>       local needs_config=0
>       local line
>       local module
>       local component
> 
> looks like build.sh is turning into a bash script, which is okay,
> but if so,  please fix the first line of the file.


According to "man sh" on my Debian distro:

     Variables may be declared to be local to a function by using a local com‐
     mand.  This should appear as the first statement of a function, and the
     syntax is

           local [variable | -] ...

     Local is implemented as a builtin command.

     When a variable is made local, it inherits the initial value and exported
     and readonly flags from the variable with the same name in the surround‐
     ing scope, if there is one.  Otherwise, the variable is initially unset.
     The shell uses dynamic scoping, so that if you make the variable x local
     to function f, which then calls function g, references to the variable x
     made inside g will refer to the variable x declared inside f, not to the
     global variable named x.


Could it be a difference in Solaris? Anyway, this can be removed. A
patch would be appreciated.



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg-devel/attachments/20101111/304ffb76/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
URL: <http://lists.x.org/archives/xorg-devel/attachments/20101111/304ffb76/attachment.pgp>


More information about the xorg-devel mailing list