Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* /usr/bin/getopts under DU4.0a
@ 1997-04-14  4:00 Gaylord Holder
  1997-04-15  4:00 ` Jonathan Chen
  1997-04-15  4:00 ` Bob Vickers
  0 siblings, 2 replies; 4+ messages in thread
From: Gaylord Holder @ 1997-04-14  4:00 UTC (permalink / raw)



/usr/bin/getopts seems to work fine under /bin/ksh, but not under
/bin/sh in 4.0a.  

Does anyone know if this is a feature?

-Gaylord



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: /usr/bin/getopts under DU4.0a
  1997-04-15  4:00 ` Bob Vickers
@ 1997-04-15  4:00   ` Charles M Richmond
  0 siblings, 0 replies; 4+ messages in thread
From: Charles M Richmond @ 1997-04-15  4:00 UTC (permalink / raw)



Bob Vickers wrote:
> 
> Gaylord Holder wrote:
> >
> > /usr/bin/getopts seems to work fine under /bin/ksh, but not under
> > /bin/sh in 4.0a.
> >
> > Does anyone know if this is a feature?
> >
> 
> Hi,
> 
> Can you be more explicit? getopts is a ksh builtin, so under ksh you
> won't execute /usr/bin/getopts unless you explicitly ask for it.
> 


In 3.2 (and 4.0 ?) /usr/bin/getopts is just a ksh script that 
invokes the builtin by:

********
c=`basename $0`         # Invoke the ksh builtin
$c "$@"
********

Under the circumstances, I wouldn't expect any effect under the Bourne
shell.

Charlie


-- 
***********************************************************************
*  Charles Richmond    Integrated International Systems Corporation   *
*  cmr@iisc.com        cmr@koibito.iisc.com  cmr@shore.net            *
*  UNIX Internals, I18N, L10N, X, Realtime Imaging, and  Custom S/W   *
*  One Longfellow Place Suite 3309 , Boston , Ma. USA 02114-2431      *
*  (617) 723 7695    (617) 367 3151        FAX (617) 723 6861         *
***********************************************************************



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: /usr/bin/getopts under DU4.0a
  1997-04-14  4:00 /usr/bin/getopts under DU4.0a Gaylord Holder
@ 1997-04-15  4:00 ` Jonathan Chen
  1997-04-15  4:00 ` Bob Vickers
  1 sibling, 0 replies; 4+ messages in thread
From: Jonathan Chen @ 1997-04-15  4:00 UTC (permalink / raw)



In <3352AED8.167E@phy.ucsf.edu> Gaylord Holder <holder@phy.ucsf.edu> writes:

>/usr/bin/getopts seems to work fine under /bin/ksh, but not under
>/bin/sh in 4.0a.  

getopts is a shell-level feature that DEC neglected to put into their
version of /bin/sh.
-- 
Jonathan Chen <jonc@pinnacle.co.nz>
-----
char *p="char *p=%c%s%c;main(){printf(p,34,p,34);}";main(){printf(p,34,p,34);}



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: /usr/bin/getopts under DU4.0a
  1997-04-14  4:00 /usr/bin/getopts under DU4.0a Gaylord Holder
  1997-04-15  4:00 ` Jonathan Chen
@ 1997-04-15  4:00 ` Bob Vickers
  1997-04-15  4:00   ` Charles M Richmond
  1 sibling, 1 reply; 4+ messages in thread
From: Bob Vickers @ 1997-04-15  4:00 UTC (permalink / raw)
  To: Gaylord Holder


Gaylord Holder wrote:
> 
> /usr/bin/getopts seems to work fine under /bin/ksh, but not under
> /bin/sh in 4.0a.
> 
> Does anyone know if this is a feature?
> 

Hi,

Can you be more explicit? getopts is a ksh builtin, so under ksh you
won't execute /usr/bin/getopts unless you explicitly ask for it.

I don't know what /usr/bin/getopts does under 4.0, but the 3.2 version
looks utterly pointless. getopts is meant to set shell variables, but it
can't possibly do this if invoked as a separate process.

Bob
-- 
======================================================================
Bob Vickers			R.Vickers@rhbnc.ac.uk
Dept of Computer Science, Royal Holloway College, University of London
WWW:	http://www.dcs.rhbnc.ac.uk/%7Ebobv/
Phone:	+44 1784 443691



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~1997-04-15  4:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1997-04-14  4:00 /usr/bin/getopts under DU4.0a Gaylord Holder
1997-04-15  4:00 ` Jonathan Chen
1997-04-15  4:00 ` Bob Vickers
1997-04-15  4:00   ` Charles M Richmond

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox