status of ksh (korn shell) in macports

joerg van den hoff veedeehjay at
Sun Aug 7 09:20:20 UTC 2022

On 07.08.22 03:59, Ryan Schmidt wrote:
> On Aug 6, 2022, at 06:22, joerg van den hoff wrote:
>> `port search ksh' currently yields the following 4 korn shell packages:
>> ksh @2020.0.0_1 (shells)
>>     the KornShell UNIX shell and programming language (stable version)
>> ksh-devel @20200125-g43d1853 (shells)
>>     the KornShell UNIX shell and programming language (development version)
>> ksh93 @93u+20120801_2 (shells)
>>     the AT&T KornShell
>> ksh93-devel @93u+m-1.0.0-beta.2 (shells)
>>     continued development of the AT&T KornShell
>> in view of the current naming scheme (_and_ info string denoting it as "stable version"), the unwary user very probably would wrongly conclude that the first one, `ksh @2020.0.0_1', is the canonical "true" korn shell to install. but it is not...
>> I wonder if the package names (and descriptions) should not be somewhat modified since the ksh93u+m project now has done it's first release with many bug fixes relative to ksh93u+, and given the project's aim to just fix existing bugs in 93u+, might be validly viewed as true fully compatible successor to 93u+ (which ksh2020 most definitely is not). it also seems that linux distros are partly already moving in that way (adopting 93u+m as default ksh).
>> so I would find it preferable to either denote ksh93 at 93u+20120801_2 (the last official ksh release) or possibly already ksh93-devel at 93u+m-1.0.1 as "ksh" and/or to rename the others to `ksh2020` (which identifies that (abandoned) project to those who care).
>> not a big deal but I think it would help to avoid possible confusion.
> Yes...
> ksh and ksh-devel were added when what you now call ksh2020 was under development and was supposed to be the future of ksh93. Since ksh93 hadn't been able to build since OS X Mavericks I was happy to have a replacement that did build, so I deleted ksh93. Later, the ksh2020 development effort was rejected by upstream, the upstream repository was reverted, and new more nuanced development of ksh93 began in a fork. At that point I reintroduced the ksh93 port and added the ksh93-devel port.

yes, I know. and I am happy that the latter two are now available in macports.

> I'm inclined to remove the ksh and ksh-devel ports (that is, to mark them as replaced_by ksh93 for one year and then delete them) unless someone thinks there is still a need to preserve that branch.

AFAIAC this would be fine. personally, I sure will not have any use for ksh2020 any more (the good 
bits (actual bug fixes to the shaky 93v- code base)) have been backported to 93u+m where applicable. 
otherwise ksh2020 remains severely broken in several regards (and is abandoned). OTOH, if the 
package title+description is clear enough what the package content actually is, no harm in keeping a 
ksh2020 package, I believe. but the cleaner solution sure is to enact your suggestion and to remove 
it in due time.

>> ps: and if I recall correctly `KornShell' was meant to denote the language while the shell's name is "Korn Shell" ;).
> Good grief! I remember pausing to consider whether to use "KornShell" or "Korn Shell" in the description but that interpretation never occurred to me. Do you have a link where that interpretation is described?
> The manpage says "ksh, rksh - KornShell, a standard/restricted command and programming language" which doesn't appear to make the distinction. The wikipedia page says "KornShell (ksh) is a Unix shell".

it was only a PS and under "IIRC" disclaimer :). I now have tried to clarify: the bolsky/korn book 
(prentice hall isbn -13-182700-6) is titled "The new KornShell command and programming language" and 
is always using KornShell only in this combination ("the KornShell language"). on p.9 under 
"notation" the book states "we refer to the programm that implements the KornShell language as ksh".

OTOH, I do not find them talking of "the Korn shell" anywhere (and thus have not recalled that 
correctly... ;)). but at least the "other" ksh book

denotes it as the "Korn Shell" (but that's not as "official" as the bolsky/korn book...).

and there also is

where the same distinction between language (KornShell) and implementation (ksh) is made.

so it seems Korn cared for that semantic distinction (and in that faq also talks of BourneShell
as being the language implemented in `sh', but that sure is somewhat idiosyncratic).

personally I would think if accepted terminology is that `sh' is the Bourne Shell (implementing
the "BourneShell" language if one adopts D.Korn's stance) than it makes sense to state that `ksh'
is (synonymous to) the Korn Shell (implementing the KornShell language etc.).

it's splitting fine hairs, though. :). one might also ask the 93u+m guys (who so far seem also to
use "KornShell" indiscriminately).


More information about the macports-users mailing list