MDB Tools source

Alternatively, use a git repo I started because CVS makes baby Theanthropos cry:

git clone git://gitorious.org/mdbtools/mainline.git mdbtools

autogen.sh && make && make install

cd into the mdbtools directory and run autogen.sh Pass any configuration args to autogen.sh, and it will pass them along to configure. /usr/local is the default prefix. The options below set the install location, enable compilation of the mdb-sql tool, but not gmdb2, the Gnome MDB File Viewer and debugger.

Installing the Arc language on Mac OS X is trivial, assuming you have the right version of MzScheme.

Install MzScheme 352 with MacPorts

Arc requires MzScheme, version 352. The install instructions warn: “Don’t use the latest version. There is said to be some bug/feature in it that breaks Arc.” The version of mzscheme in MacPorts is 371, so we have to tweak the portfile, and the only historical versions of mzscheme I can find portfiles for are 201 and 360. There seem to have been some major build changes between 352 and 360, so I frankensteined the portfile for version 201. You can find my version here. I’m running 10.4.11 on my dev machine, and I haven’t tested anything else.

Thanks go to bitshaker.com for the instructions on setting up a local port repo.

mkdir /Users/Shared/dports/lang/mzscheme

Edit /opt/local/etc/macports/sources.conf to look like this:

# To enable your local ports repository, uncomment and customize the
# following line to point at your local dports directory
# Example: file:///Users/landonf/misc/macports/dports
#
# To get macports from the macports rsync server use:
# rsync://rsync.macports.org/release/ports/
file:///Users/Shared/dports
rsync://rsync.macports.org/release/ports/

Download this portfile and copy it to /Users/Shared/dports/lang/mzscheme/Portfile

Update the ports index:

portindex /Users/Shared/dports

When you run port list mzscheme, you should have an entry for mzscheme @352

I just posted to Rubyforge the first public version of FinderColor, a very small interface to the Finder label colors in Mac OS X. FinderColor sends Apple Events using rb-appscript, bypassing AppleScript entirely. This counts as a good thing.

The index argument must be between 0 and 7. The hash argument to batch_set expects the keys to be integers or symbols for color names. FinderColor::Labels gives you an array of the color symbols in their index order:

Because I’m using PHPLDAPAdmin as a stopgap while I build a custom web directory application, I have gotten soiled a bit by PHP. I’m running everything on a headless Mac mini, and I chose to use Mac OS X as the OS for reasons I won’t go into here.

The front-end web server is nginx, which is proxying to php running as fcgi. Pardon me in advance if/when I get the terminology wrong. I tried using the instructions from the Homo Adminus blog, and while both the Bash script method and the spawn-fcgi method work, I could not figure out how to get launchd to manage them.

I hope that some of you are laughing at me at this point, because the problem was (and may still be) totally centered on my ignorance of the fastCGI usage of the php binary. I was being dense about launchd as well. Launchd doesn’t use spawn-fcgi or a custom shell script as the ProgramArguments. Rather, it completely obviates the need for them. This should have been obvious (a phrase that I promise will be common on this blog).

For the edification of the similarly ignorant, here’s a launchd plist that seems to work.

As I understand it, you set the server IP address and port number with the -b argument to the php binary. Homo Adminus adds the -q option (suppressing HTTP Header output) in his Bash script, so I did as well. To arrange for more than one listening process, you have to set the PHP_FCGI_CHILDREN environment variable.