I have to admit, I am one of those people who dislikes Linux for one major reason: Whenever you ask for help in any online forum, the knowledgeable people all seem to be command-line devotees, and they invariably give you instructions that involve typing long, arcane commands into the command line. I hate using the command line – if I had wanted to use a command line, I’d never have moved away from MS-DOS, and i cannot understand why Linux geeks insist on using it, and on trying to get others to use it. Even users of Linux distributions such as Ubuntu have found that when they go online asking how to do some function that could easily be accomplished using one of the GUI tools, often some obnoxious twit helpful person will reply by giving a bunch of stuff (that makes no sense at all to the uninitiated) to type in at the command line. One of the things I like most about Mac OS X is that you almost never have to do anything from a terminal prompt if you don’t want to, and Mac users seem to have a healthy disdain for using a computer as if it were still the 1970’s.
Long ago, when I was using MS-DOS, there was one tool that I had to have on any system I was using: Norton Commander. The original, dual-pane file manager that made it oh-so-easy to do typical file manipulations like copying and moving files, viewing and editing text files, launching executables, etc. without typing in DOS commands. Norton Commander was such a great program that it inspired similar programs on other platforms, such as Total Commander under Windows, and the cross-platform muCommander that runs on just about anything (if it has Java installed). In the Linux world, KDE users have Krusader, and Gnome users have Gnome Commander. Mac OS X users have a number of choices, including the aforementioned muCommander and Xfolders, both of which are free (there are other options that cost money, and that I frankly think are overpriced).
However, despite your best intentions, there may come a time when you find yourself working at a shell prompt. Maybe you are working with a Linux server, or on a Mac, maybe you can’t get OS X to come up but you are able to get to a terminal prompt (sadly, this has happened to me twice after Leopard upgrades – Leopard is better in many ways than Tiger was, but the first two versions were definitely not as stable, which makes me wonder why Apple is so willing to cast stones at Vista in some of their online advertising – but I digress). More commonly, you are getting a permissions error on some file and can’t understand why – that’s very rare on the Mac, but it happens, and now you find yourself in the terminal trying to remember how to change permissions or ownership on a file (by the way, in most cases you should be doing this by right-clicking on the file in Finder, then clicking on “Get Info” in the context menu, and then using the Sharing & Permissions section at the bottom of the information panel. But there are occasions when nothing else seems to work, and you want to go a bit deeper into the guts of the system). It is at those times when Midnight Commander may be the tool you want.
However, up until now there has not been a really easy way to install Midnight Commander on a Mac running OS X (at least not that I’ve seen). But now, there is a package by Rudá Moura called Rudix, which is described this way:
Rudix features a world class collection of pre-compiled and ready to use Unix compatible software which are not available from a fresh installation of Mac OS X but are popular among other Unix environments. Here you can find utilities, programming languages, libraries and tools delivered as standard Mac OS X packages.
Now, I hear some of you “cut-my-teeth-on-Unix” types screaming, “What about MacPorts? What about the Fink project?” Those are all well and good if that’s your cup of tea, but they require a much higher lever of Unix “geekiness” to install, and they add a lot of code that the typical user doesn’t need. Rudix will let you add a whole bunch of Unix utilities if you really want to do that, but if you only want a few needed utilities then the “Custom Install” button in the Rudix installation lets you select exactly what you want, and no more.
So here is how you would install Midnight Commander in Mac OS X, using Rudix:
- Go to http://www.rudix.org/ and download the installer package.
- Once you have it downloaded, double click on it to begin the installation. Don’t worry, you don’t have to install the entire package if you don’t want to. You should see a screen that looks like this (click on the thumbnails to enlarge):

- Click on Continue and you may get another screen asking you which volume to install the software on – if you get that, make a selection and then you should get this screen:

- Click on Customize – do not click on Install or you will get the whole thing, which is probably not what you want! That will get you to this screen:

- One minor nit about this program – when you click “Customize” you obviously want to select certain packages, so why is everything checked by default? Anyway, go through and UNcheck everything but gettext, glib, and mc. gettext and glib are dependencies that Midnight Commander needs to run, and are shown in the above screenshot (note they indicate an upgrade only because I had already installed everything when I took these screenshots – for you, they should indicate that these packages are being installed). Then you will want to keep scrolling down and unchecking everything else, except mc:

- Now click on Install (not “Standard Install”). You will get a popup window asking you to enter your password, so do it and then sit back and wait a few seconds. When the installer is finished, try typing mc from a terminal window, but note that you may need to complete step 7 before it will work correctly.
- The Midnight Commander package (if you view it individually) advises this:
Post installation
Open a Terminal application and become root to edit file /etc/profile. Add /usr/local to $PATH environment variable. The profile should appear like this:
# System-wide .profile for sh(1)
PATH=”/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin”
export PATHif [ "${BASH-no}" != "no" ]; then
[ -r /etc/bashrc ] && . /etc/bashrc
fiThis does NOT mean you should copy the path line shown above verbatim. Go into a terminal window and enter this:
echo $PATH
This will show you your current path. What they are telling you is to make sure that /usr/local/bin and /usr/local/sbin are already in your current path (in practice I found that only /usr/local/bin needs to be there, so it’s up to you whether you wish to add both), and if they are already there then you obviously don’t need to do anything to add them. But if they are not there, you can add them in /etc/profile by adding just the two lines that begin with PATH= (but use YOUR path with the necessary additions), and export PATH.
Or, better yet, you can use
export PATH = $PATH:/usr/local/bin:/usr/local/sbin
to append those two directories to the existing path. But, don’t duplicate any directories that are already in the path. (Thanks to fyngyrz for the comment that inspires this suggestion.)I found that the easiest way edit /etc/profile from a command prompt was this:
sudo nano /etc/profile
But, of course, you can use your favorite plain text editor in place of nano. After making your edits (don’t forget to make sure you have the opening and closing quotation marks in the appropriate places if applicable), close and re-open the terminal window (so it will use the newly-modified path), then try mc again.
Once you have installed Midnight Commander, you will realize that Rudix can be used to easily install many other utilities commonly found on Unix/Linux systems. Personally, I would not go hog wild on this – I’d only install the utilities you actually need, as you need them. It is easy enough to re-run the Rudix installer when you need another package or two. One of those available packages is inadyn, which is described as “a free, small, easy portable DynDNS client”, and which was the subject of a previous article on this site. I didn’t install that on my Mac, but I did install wget, because so many scripts (such as those written in Perl) expect it to be present.
Three more quick points: The Rudix installer package doesn’t have an uninstaller. However, if you use the Rudix installer to install the package named “Rudix”, described as “Command line tool to manage Rudix’s packages” (oooh, how I hate even mentioning that!) you can then uninstall any package by using this syntax from the dreaded command prompt:
sudo rudix -r unwanted.pkg
Also, if for some reason you really can’t (or don’t want to) get the entire Rudix installer, you can grab the individual packages. There is a list here and the downloads are at Sourceforge.
Finally, if after installing a package you get a message like dyld: Library not loaded: /usr/local/lib/…, that means that there is some library that needs to be installed (such as gettext and glib with Midnight Commander). If you are totally stuck, you can send the author of Rudix an e-mail (see the last Q&A in his FAQ for a link) and maybe he will be able to tell you which packages you need. I wrote to him when Midnight Commander wouldn’t install and got a speedy reply telling me which additional packages I needed to install – YMMV, but I have a feeling that most of the packages are either complete, or will make it obvious which libraries they are missing. Midnight Commander is a bit more complex than your average command line tool, after all, so it doesn’t surprise me that it’s a slight bit harder to install (but still very easy if you know how, and hopefully this article has shown you how!).
Edit March 28, 2008: I made an interesting discovery tonight. Normally I use iTerm as my terminal program, and Midnight Commander runs fine in that. What it does not seem to run so well under is the Terminal.app program that comes with OS X. What specifically does not work in Terminal.app, at least on my system, is the mouse. Under iTerm, mouse clicks get passed to Midnight Commander in the normal manner, but under Terminal.app that doesn’t seem to be the case. So, for the “best user experience”, so to speak, I’d suggest downloading and installing iTerm, which has a lot of other nice features you’ll probably appreciate (and did I mention it’s free?).
Edit April 1, 2008: If, for some reason, you want to modify the color theme of Midnight Commander, here are a couple of blog posts that show how to do that:
And, the Midnight Commander manual is another good source of information on this subject.
Command line haters of the world, untype!

rstm said
Hello Jack, I’ve read your post and enjoy it much. This is the kind of information which only a native speaker can do to pass users a very descriptive background in what Rudix is and do.
I like the way do you explain step-by-step in how to install Rudix with only a few packages and how do you show to the novices the customization of /etc/profile and to insert the correct PATH. Really Great.
So, I’m asking you permission to link your post into my Website in “Documentation” section because it worth allot for other users.
– Rudá.
michigantelephone said
Rudá, of course you have my permission to link to this post, and I much appreciate the link! And thank you for making it so easy to install many of the popular Unix-based packages, without adding a lot of extra bloat to your system. I hope that many Mac OS X users will try Rudix, it really is a nice package.
- Jack
Three FREE dual pane Commander-type file managers | CrabApple Forest said
[...] And thanks to our friends at the Michigan Telephone, VoIP and Broadband blog there are now some instructions for installing Midnight Commander that make the process as easy as following a recipe in a [...]
robind63 said
What are your iTerm settings for the terminal and keyboard profiles? I tried this build of MC because the one I did myself misbehaved with the mouse in both iTerm and Terminal. In iTerm it types garbage characters when I click the mouse instead of sending the mouse event to the app. The funny thing is that if I am logged in to a linux system in the iTerm and run MC there then the mouse does fine.
robind63 said
Nevermind. It was just a bad setting in my .mc/ini file. The use_8th_bit_as_meta value needs to be set to zero.
fyngyrz said
If you’d like to add something to your path such as /usr/local, here’s how it’s done:
export PATH = $PATH:/usr/local/
…the $PATH tells export to use the previous value, the colon separates the last value in the path from the new one you supply, and and finally the new is appended
.
Mac OS X: mc - Midnight Commander « Tuxhausen-Blog said
[...] Weitere Infos (auf englisch) findest du hier http://michigantelephone.wordpress.com/2008/03/25/how-to-install-midnight-commander-under-mac-os-x-t... [...]
Anonymous said
I’m getting error
dyld: Library not loaded: /usr/local/lib/libintl.8.dylib
Referenced from: /usr/local/bin/mc
Reason: image not found
Any idea?
-Janusz
michigantelephone said
Anonymous, why do I get the feeling you hurried through the article and didn’t take the time to read and follow the instructions explicitly? In particular, did you also install gettext and glib, as instructed in the article? If you did install BOTH of those packages and you still got that message, you may want to send the author of Rudix an e-mail, as the article states.
The five Windows programs I wish were available on a Mac « Michigan Telephone, VoIP and Broadband blog said
[...] Total Commander – I’ve said before how much I think that Mac OS X Finder Sucks, but if you try to find a decent dual-pane file manager for the Mac you won’t find one as full-featured as Total Commander. What I’m looking for here is ease of use – give me buttons to select my various drives (or Volumes, as they are known under OS X). Don’t make me click-click-click-click-click to get to frequently used locations. I would run Total Commander under Codeweavers Crossover except that it knows nothing of permissions. Strangely enough, the dual-pane file manager I most often use on my Mac is a Linux program called Midnight Commander, which I install using Rudix, as previously mentioned in my post appropriately titled How to install Midnight Commander under Mac OS X (the easy way, using Rudix). [...]
Midnight Commander on OSX | Kamen Dimitrov's Blog said
[...] намерих по въпроса, можете директно да я намерите тук или директно да отидете на rudix.org и да си свалите glib, [...]