Tuesday, November 14, 2006

Attack of the killer S-expressions


In this era of open source, you'd think it would be a simple matter to compile a 45 year old language that has been used and update extensively during its entire life.

WRONG!

I was after a Lisp dialect that ran on Windows (Cygwin), Mac (Intel) and *nix. PLT Scheme looked good for a while- slipped onto all the platforms, no worries. But Scheme suffers from lack-of-standards and there was some note somewhere about PLT about to lose its NSF funding (read "insert dead-end language here"). Also, all the benchmarks I could find showed dull old Common Lisp whipping the pants off Scheme implementations.

So, onto Lisp. GCL had no Intel-Darwin version and while SBCL came highly recommended, it get dying on compilation. Offically, Fink has clisp but I could never get my local version to find that packagte. Then I tried DarwinPorts but that barphed cause Fink had got there first and added in headers that DarwinPorts saw as "not a registerred (Darwin) port". So that was that.

Currently, I'm trying ECL. It uses gcc and compiled cleanly on the Mac (after telling its configure to use my own directory structure for $prefix. Right now, I'm trying a Cygwin compile. Cross fingers.

This is day five of poking around web sites, looking at this, trying that. Not that I worked on it full time but this is much more work than I'd anticipated.

(print 'goodGrief)

(UPDATE: ECL compiled fine under cygwin, but now it won't recognize any command line arguments- it just quits after loading. grrr)

(UPDATE on the UPDATE: Cygwin's clisp compiles just fine so it looks like it'll be ecl on the mac and clisp on PCs. Which has its upside- I'll be less likely to use uncommon Common Lisp constructs if I have to satisfy two interpreters.)

1 comment:

Bart Massey said...

Seriously consider ML. It's like Lisp, only with a decent type and module system. I'm an SML guy, but these days all the cool folks are using CAML. It has nice libraries and implementations on all your platforms IIRC.

BTW, I think this is one of those places where I don't want to take the Red Pill…