Posts Tagged ‘mac os x’

Debian almquist shell on Mac OS X

Tuesday, May 4th, 2010

I’ve recently changed the default shell /bin/sh on my Leopard install to dash from bash. Why would I do this? Well, by bash’s own admission (see BUGS in its manpage), bash is “too big and too slow”. dash is used for /bin/sh by default on Ubuntu nowadays, and it’s a goal for Debian (supposedly for Lenny, but I can’t see it noted in the release notes and it’s only “confirmed” in the Lenny goals). dash is significantly smaller and faster.

Ubuntu and Debian ran into plenty of bashisms when they tried to change, how about Mac OS X? So far I’ve found problems with /usr/libexec/path_helper (I just changed the shebang line to #!/bin/bash). There was also a problem with X11′s startx, and my patch was quickly committed.

Interestingly enough, when I went to move the sh binary, there are actually two versions of bash in /bin. Both report

GNU bash, version 3.2.17(1)-release (i386-apple-darwin9.0)

but differ at the binary level (they aren’t even the same size). I wonder if Apple tried to optimize their /bin/sh given that it gets more usage.

I built dash-0.5.5.1 from the tarball without a problem.

Muxic – Minimal XMMS2 client for Mac OS X

Thursday, March 19th, 2009

XMMS2 is cool. In my experience, its architecture does everything The Right Way, and their support tools (git, mantis, mediawiki, doxygen-generated documentation) are all modern.

The clientlib is good enough that clients (frontends) can be very lightweight. FWICS there are some good Qt and GTK based clients that would probably run fine on OS X, if you can be bothered getting them and their dependencies working.

Even then, other Qt and GTK based applications I have on scud always feel slightly out of place (or very out of place for those using X11). There were no Cocoa/Application Kit based GUIs on the old clientlist. I set out to create a Cocoa UI.

I like Winamp Classic’s UI; it is functional and compact, especially in windowshade mode. If you are used to the keyboard shortcuts (and they make a lot of sense with a QWERTY keyboard), you don’t need huge buttons.

Hence I made a client with similar minimalism, without trying to be Winamp-skin-compatible. I’m quite happy to use the CLI and other clients for managing the media library, but for something that’s sitting on my desktop all the time I wanted small, and I wanted it to fit in with OS X. It’s got Growl support too!

Muxic Desktop screenshot

Introducing: Muxic.

Muxic is a minimal user interface to XMMS2. It should be ready for a release soon, meanwhile you can browse the Muxic source.

Leopard ahoy!

Tuesday, July 1st, 2008

Now that fink has finally started to show some maturing support for Mac OS X 10.5, I’ve upgraded on scud.

I re-used my home directory from Tiger, without any help of migration tools other than chown. Mail.app upgraded its data and so far everything’s gone smoothly.

Managing users has changed a bit: you have to Ctrl+click the account in System Preferences and select “Advanced Options” to change the usual POSIX fields. If you’re serious, check out dscl(1):

 dscl . -read /Users/$(whoami)

Looks like Apple’s Terminal.app has improved a great deal, almost surpassing iTerm. However, it still fails short in the tab apartment: AFAICS Terminal.app’s tab titles always display the process name and don’t respond to the usual xterm escape codes, and the visual style of the tabbar isn’t nearly as nice as iTerm’s Aqua style.

Trying to switch to fink unstable doesn’t work as advertised: you must use the CVS method of selfupdate (rsync being the default).

After Software Updating to 10.5.4, X11.app broke.

1/07/08 4:04:01 PM org.x.X11[12697] /usr/X11/libexec/x11-exec: Unable to find application for org.x.X11

Since Apple’s official updates are lagging by more than 6 months, it’s better just to get it from the xquartz project.

Photoshop doesn’t like case-sensitive filesystems, but there is a (tedious) workaround. I totally agree that this is just laziness on the part of the Adobe devs: it would take 1 man less than a day to do the appropriate case consistency changes given the source code: there’s nothing to break.

launch for Mac OS X

Tuesday, May 27th, 2008

I’m in the habit of keeping multiple profiles under firefox. It means I can have a profile for FF2 (with old plugins that haven’t been ported to FF3), a profile for development with FF3, and one for general browsing with FF3.

Despite their usefulness, profiles seem to be discouraged. The profile manager isn’t shown by default. You have to start the firefox binary with -P to get it up.

Having multiple profiles is great, but under Mac OS X it’s not easy to use them simultaneously. Trying to re-launch an application just activates the currently open instance. Aside from the (wasteful) hack of duplicating the .app directory, how do you open the same application twice under Mac OS X?

The answer is launch. It’s in fink too.

launch -m -a Firefox

Apparently Quicksilver had a “Launch a copy” action that did something similar, but I can’t find it in the current version.