[CUWiN-Dev] Re: [CUWiN-Commits] r2664 - in cuw/trunk/src/boot-image: . steps.d

Bryan Cribbs bdcribbs at ojctech.com
Thu Feb 3 13:30:35 CST 2005


* Chase Phillips <shepard at ameth.org> :
> Oh?  I use dashes in subroutine names in dhcpselect and so do the
> /etc/sh-incl/* files.  Can you provide an example of the error you saw for
> archive's sake?

They work fine when run under both sh and bash-2.05b.0 in NetBSD, 
however, for portability, apparently one shouldn't use them.
On the Linux box in question, /bin/sh was a symlink to bash-2.05b.0.

$ cat > test.sh <<EOF
. #!/bin/sh
. 
. subr-with-hyphens ()
. {
. 
.     echo "Hello";
. }
. EOF
$ chmod u+x test.sh 
$ ./test.sh 
./test.sh: line 6: `subr-with-hyphens': not a valid identifier
$ 


> 
> On Thu, 3 Feb 2005 bdcribbs at cuw.ojctech.com wrote:
> 
> > Author: bdcribbs
> > Date: 2005-02-03 12:39:06 -0600 (Thu, 03 Feb 2005)
> > New Revision: 2664
> >
> > Modified:
> >    cuw/trunk/src/boot-image/modules.subr
> >    cuw/trunk/src/boot-image/steps.d/modules
> > Log:
> > Change the hyphens in the module subroutines to underscores,
> > because sh on Linux doesn't like the hyphens.
> >
> >
> >
> > _______________________________________________
> > CU-Wireless-Commits mailing list
> > CU-Wireless-Commits at cuwireless.net
> > http://lists.chambana.net/cgi-bin/listinfo/cu-wireless-commits
> >
> _______________________________________________
> CU-Wireless-Dev mailing list
> CU-Wireless-Dev at lists.cuwireless.net
> http://lists.chambana.net/cgi-bin/listinfo/cu-wireless-dev


More information about the CU-Wireless-Dev mailing list