[PATCH v2 modular 1/1] build.sh: use the script name only, not the path in usage statement

Gaetan Nadon memsize at videotron.ca
Wed Dec 15 13:51:42 PST 2010

On Tue, 2010-12-14 at 18:40 -0800, Dan Nicholson wrote:

> Oh, never mind. I thought you guys had decided on POSIX shell as a
> baseline.

This has been the subject of confusion on a number of occasions. We know
we have users on Solaris 10
with a Bourne shell that isn't POSIX compliant, as explained by Alan.
Most of the changes done are from people
with POSIX shell, mostly bash. 

I'd like to find a meaningful comment to add in the script to clear the
confusion, but I am rather ignorant on the subject, barely cognisant of
the shell I am using (turns out to be "dash").

# Note on portability: 
# This script is intended to run on any platform supported by X.Org. 
# The Autoconf generated configure script is a good reference as to what is permitted.
# Basically, it should be able to run in a Bourne shell.

I figured that if packages configure script can run on a given platform,
so should build.sh.

Should we had this boiler plate code from configure:

        # Be more Bourne compatible
        if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
          emulate sh
          # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
          # is contrary to our usage.  Disable this feature.
          alias -g '${1+"$@"}'='"$@"'
          setopt NO_GLOB_SUBST
          case `(set -o) 2>/dev/null` in
          *posix*) set -o posix ;;

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg-devel/attachments/20101215/6b78991a/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/20101215/6b78991a/attachment.pgp>

More information about the xorg-devel mailing list