On Thu, Mar 18, 2010 at 3:24 PM, Garrett D'Amore - sun microsystems <gd78059 at sac.sfbay.sun.com> wrote: > > Template Version: @(#)sac_nextcase 1.69 02/15/10 SMI > This information is Copyright 2010 Sun Microsystems > 1. Introduction > ? ?1.1. Project/Component Working Name: > ? ? ? ? More ksh93 builtins > ? ?1.2. Name of Document Author/Supplier: > ? ? ? ? Author: ?Olga Kryzhanovska > ? ?1.3 ?Date of This Document: > ? ? ? ?18 March, 2010 > 4. Technical Description > > I'm sponsoring this fast-track request on behalf of the > ksh93-integration project. > Please note that this is an *open* case. > > The release binding is the same as with the ksh93 project: a > patch/micro release of Solaris delivering through ON > Stability levels are as described below. > > > This project is an amendment to the Korn Shell 93 Integration project > (PSARC/2006/550 and PSARC/2007/035, PSARC/2008/094, PSARC/2008/344 > and PSARC/2008/589) specifying the following additional > interfaces: > Addition of /usr/gnu/bin, /usr/xpg4/bin and /usr/bin built in > mappings in ksh93 > > Bug/RFE Number(s): > > 6935110 ?ksh93 needs (more) XPG, GNU built ins > > This case proposes to deliver the following features as a set of > independent putbacks as they become available. Each feature is > self contained and independent of the others, so out of order > and partial putbacks at this granularity should have no adverse > impact on the functionality and behavior of the system as a whole. > > > Part 1: ksh93 built in mappings for /usr/gnu/bin utilities > ---------------------------------------------------------- > The case proposes to enable the following mappings to ksh93 built in > commands for utilities in /usr/gnu/bin. When the utility is called > using it's command name, and not the full path, the ksh93 builtin > will be used instead of executing the /usr/gnu/bin binary. > > > Interface ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Stability ? ? ? ?Description > --------- ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? --------- ? ? ? ?----------- > ksh93 '/usr/gnu/bin/basename' built in ?Uncommitted ? ? ?basename utility > with GNU extensions
So, if I call a plain basename, what gets executed? Does it look at the PATH setting and call the gnu/solaris/xpg4 (or for the more perverse of us, ucb) variant of the builtin? Is there just one builtin that always behaves the same way? Or, another way, if I don't have /usr/gnu/bin in my PATH, will the builtin basename have the GNU extensions? (Differences for something like basename are minor; for other utilities the differences may matter.) -- -Peter Tribble http://www.petertribble.co.uk/ - http://ptribble.blogspot.com/