[request-sponsor] Requesting sponsor for CR #6451262 ("RFE:

2007-09-01 Thread Alan Coopersmith
Roland Mainz wrote:
> - GNU "sleep" lives in an optional package while both the current
> implementation of /usr/bin/sleep and libshell.so.1 live in OS/Net. AFAIK
> GNU "sleep" would need to be moved to OS/Net first or "sleep" moved out
> of OS/Net somehow (which is tricky since some system scripts AFAIK
> depend on "sleep")

OS/Net depends on things in other consolidations already - there's no
trick to that.   The package dependencies would need to be updated, but
that's not hard.

-- 
 -Alan Coopersmith-   alan.coopersmith at sun.com
  Sun Microsystems, Inc. - X Window System Engineering



[request-sponsor] Requesting sponsor for CR #6451262 ("RFE:

2007-09-01 Thread Cyril Plisko
On 9/1/07, Roland Mainz  wrote:
> "Richard L. Hamilton" wrote:
>
> > > This is a sponsor request to implement the RFE/CR
> > > #6451262 ("RFE:
> > > /usr/bin/sleep should support floating-point values"
> > > -

considering that /usr/gnu/bin/sleep already does that, how important
it is to have yet another implementation of that feature ?

-- 
Regards,
Cyril



[request-sponsor] Requesting sponsor for CR #6451262 ("RFE:

2007-09-01 Thread Roland Mainz
Cyril Plisko wrote:
> 
> On 9/1/07, Roland Mainz  wrote:
> > "Richard L. Hamilton" wrote:
> >
> > > > This is a sponsor request to implement the RFE/CR
> > > > #6451262 ("RFE:
> > > > /usr/bin/sleep should support floating-point values"
> > > > -
> 
> considering that /usr/gnu/bin/sleep already does that, how important
> it is to have yet another implementation of that feature ?

Some points:
- libshell.so.1 is likely going to be already loaded in the system at
the time someone calls the external application /usr/bin/sleep and
loading another extra binary (e.g. GNU sleep) would require extra time
and memory (see my previous comment about sub-second timing)
- GNU "sleep" lives in an optional package while both the current
implementation of /usr/bin/sleep and libshell.so.1 live in OS/Net. AFAIK
GNU "sleep" would need to be moved to OS/Net first or "sleep" moved out
of OS/Net somehow (which is tricky since some system scripts AFAIK
depend on "sleep")
- GNU "sleep" has extensions which would need to be implemented to
ksh93's "sleep" builtin first to ensure compatibity (and this needs to
be checked against the POSIX specs, e.g. whether 'm', 'h', 'd', 's' can
be applied as time units). However this may lead to a similar problem as
GNU "readlink" vs. ksh93 "readlink" (e.g. GNU "readlink" has extensions
which are not functional on all types of filesystems and IMHO therefore
won't be very welcome in a shell which has portabilty of it's script as
one of it's primary goals (which reminds me that I still own Stephen
Hahn an email to discuss how to get rid of GNU "readlink" from
/usr/bin/readlink)) which is already a big mess and I don't like to see
more of these problems in my ToDo list... ;-(



Bye,
Roland

-- 
  __ .  . __
 (o.\ \/ /.o) roland.mainz at nrubsig.org
  \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix programmer
  /O /==\ O\  TEL +49 641 7950090
 (;O/ \/ \O;)



[request-sponsor] Requesting sponsor for CR #6451262 ("RFE:

2007-09-01 Thread Roland Mainz
"Richard L. Hamilton" wrote:

> > This is a sponsor request to implement the RFE/CR
> > #6451262 ("RFE:
> > /usr/bin/sleep should support floating-point values"
> > -
> > http://bugs.opensolaris.org/view_bug.do?bug_id=6451262
> > ).
> > An old draft for the matching ARC case can be found
> > at
> > http://svn.genunix.org/repos/on/branches/ksh93/gisburn
> > /arc/sleep/solaris_sleep_fasttrack.txt
> > (comments welcome) ...
> >
> > My contributor ID is "OS0025".
> 
> Why do I think you're going to do this in terms of ksh93? :-)

Well, it's the easiest and cheapest way to do it and we have the
precedent of /usr/bin/ksh doing it for things like /usr/bin/test ... :-)

> Maybe since it's sleep builtin can do that?
> 
> So, will it be
> 
> #! /usr/bin/ksh93
> # do we need to set PATH to ensure the builtin is used?

Currently the "sleep" builtin is not bound to a PATH (one reason is to
avoid that the shell has to travel all PATH elements at the first usage
and |stat()| if there are other "sleep" commands around (which is
inacceptable for sub-second timeouts like $ sleep 0.001 #)).

> exec "$(basename "${0}")" "$...@}"
> 
> Or will it be a C wrapper to call b_sleep() in libcmd?
> (which if done right could also call any of the builtins,
> given a suitable hard or symbolic link; and might have
> faster startup than ksh93 itself)

Both implementations are possible - it could be implemented using a
wrapper script (like "alias.sh" links /usr/bin/ksh builtins like "kill"
to /usr/bin/kill) or directly calling the builtins via the |b_sleep()|
function (note that |b_sleep()| lives in libshell, not libcmd since this
is "core functionality" which is slightly more deeply connected with
shell internals than you may think at the first look).
The first solution has the advantage that there is the precedent of
/usr/bin/ksh already doing this stuff for it's builtins and that the
code would be quite small... the 2nd version has the advantage of being
faster and requiring less startup time (but would use a project-private
API where the usage needs to be ARC'ed somehow (AFAIK that's called
"contracted", right ?)).



Bye,
Roland

-- 
  __ .  . __
 (o.\ \/ /.o) roland.mainz at nrubsig.org
  \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix programmer
  /O /==\ O\  TEL +49 641 7950090
 (;O/ \/ \O;)



[request-sponsor] Requesting sponsor for CR #6451262 ("RFE:

2007-09-01 Thread Patrick Georgi
> considering that /usr/gnu/bin/sleep already does
> that, how important
> it is to have yet another implementation of that
> feature ?
How about we just add a compatibility layer to the GNU tools so old-time SunOS 
users feel at home and shut down operation? (Oh, and shut down POSIX, too - no 
one _really_ needs them, now that GNU has taken over)


Patrick Georgi
 
 
This message posted from opensolaris.org



[request-sponsor] Requesting sponsor for CR #6451262 ("RFE:

2007-09-01 Thread Richard L. Hamilton
Why do I think you're going to do this in terms of ksh93? :-)

Maybe since it's sleep builtin can do that?

So, will it be

#! /usr/bin/ksh93
# do we need to set PATH to ensure the builtin is used?
exec "$(basename "${0}")" "$...@}"

Or will it be a C wrapper to call b_sleep() in libcmd?
(which if done right could also call any of the builtins,
given a suitable hard or symbolic link; and might have
faster startup than ksh93 itself)

> This is a sponsor request to implement the RFE/CR
> #6451262 ("RFE:
> /usr/bin/sleep should support floating-point values"
> -
> http://bugs.opensolaris.org/view_bug.do?bug_id=6451262
> ).
> An old draft for the matching ARC case can be found
> at
> http://svn.genunix.org/repos/on/branches/ksh93/gisburn
> /arc/sleep/solaris_sleep_fasttrack.txt
> (comments welcome) ...
> 
> My contributor ID is "OS0025".
> 
> 
> 
> Bye,
> Roland
> 
> -- 
>   __ .  . __
> o.\ \/ /.o) roland.mainz at nrubsig.org
> \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix
>  programmer
>  /O /==\ O\  TEL +49 641 7950090
> (;O/ \/ \O;)
> ___
> request-sponsor mailing list
> request-sponsor at opensolaris.org
 
 
This message posted from opensolaris.org