Tuesday, February 22, 2011

OS X Package Management Evolution

Having only a few remaining gigs of free space I've been getting desperate. Everything that can be moved off to an external drive has been. I started to dig into two package management systems that I realize I rarely use any more: Fink and MacPorts.

Removing Fink

Fink has been a good package manager, but I've found the pre-compiled packages less useful for my purposes and I haven't been using it as much since I haven't had to open an X11 application in a long time. It seems like software versions are always a few revs back and I never really got familiar with how things are organized so it's a black box I'm happy to get rid of. It turns out removing fink is a snap:

sudo rm -rf /sw

This removed a bunch of unused stuff, almost 10Gb! Something that easy to remove and well-documented can't be all bad though...

Removing MacPorts

MacPorts is much like Fink, but instead of pre-compiled packages it is built on your system after download. I like this approach, but I still haven't been using it much lately. Removing MacPorts is also really easy. First remove all your installed port files:

sudo port -f uninstall installed

and all the other remnants:

sudo rm -rf /opt/local

There are a number of other directories that the official uninstall documentation recommends, but they didn't really apply to my system.

Now What?

I'm always trying to stay current on the latest technologies, even though I know sometimes the next great thing is nothing more than churn. I randomly came across a cool little utility that I wanted to install (pianobar - a command line interface to Pandora) and the instructions I came across were raving about using Homebrew. It seems like a nice, simple, and well-contained package manager that puts everything where I would anyway (in /usr/local/). Installing couldn't be easier:

curl -L http://github.com/mxcl/homebrew/tarball/master | sudo tar xz --strip 1 -C /usr/local

This puts "brew" in /usr/local/bin. Super easy to use, for example here's how I installed pianobar:

sudo brew install libao faad2 libmad
sudo brew install pianobar

I can see all my new packages happily living in /usr/local/Cellar. Nice.

No comments:

Post a Comment