Installing pdksh

G

gatorparrots

Guest
ksh for OS X
AT&T Research has a pre-compiled Darwin binary of ksh available for those wishing to try out a so-called scripting shell:
http://www.research.att.com/~gsf/cgi-bin/d...n=list&name=ksh
However, the AT&T version does not come with a man page and may generate locale errors under Darwin/OS X. Therefore, I suggest installing an alternative. If you want to try ksh on OS X, you can install pdksh (a korn shell clone) like so:
curl -O ftp://ftp.cs.mun.ca/pub/pdksh/pdksh-5.2.14.tar.gz
gnutar -xzf pdksh-5.2.14.tar.gz
cd pdksh-5.2.14
curl -O ftp://ftp.cs.mun.ca/pub/pdksh/pdksh-5.2.14-patches.1
curl -O ftp://ftp.cs.mun.ca/pub/pdksh/pdksh-5.2.14-patches.2
patch < pdksh-5.2.14-patches.1
patch < pdksh-5.2.14-patches.2
./configure --prefix=/usr/local
make
sudo -s
make install
echo "/usr/local/bin/ksh" >> /etc/shells
exit


Available Shells in OS X
On OS X 10.2, the default shell is tcsh. Here is a list of the provided shells:
/bin/bash
/bin/csh
/bin/sh
/bin/tcsh
/bin/zsh

(sh is actually bash running in sh compatibility mode; ksh can be invoked in zsh, but only in compatibility mode)

bash was not included in 10.1.x allegedly due to licensing concerns on Apple's part. Now it is part of the shipping shell choices, although it has not yet been blessed with the default shell assignment status (as has tcsh).
 
Joined
Oct 27, 2002
Messages
1,345
Reaction score
0
Points
36
Location
Vermont
Your Mac's Specs
17" iMac G4 800MHz 1GB RAM
what is the default shell in OS X? Is it bash? I like the RedHat default, which I think is bash. Mainly the colored shell is my main reason for asking
 

rman


Retired Staff
Joined
Dec 24, 2002
Messages
12,637
Reaction score
168
Points
63
Location
Los Angeles, California
Your Mac's Specs
14in MacBook Pro M1 Max 32GB 2TB
Thanx gatorparrots, I was wondering about the other shells. I didn't have the time to look. Will have to try the pdksh you suggested. :)
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top