François-René Rideau ([info]fare) wrote,
@ 2005-08-20 15:18:00
Previous Entry  Add to memories!  Tell a Friend!  Next Entry
Current music:Doris Day - My Romance
Entry tags:code, en, hacker, intellectual property, lisp, meta, smop, tao of programming, unix

cl-launch

I am glad to announce my latest piece of semi-useful software, CL-Launch, an infrastructure to easily make your Common Lisp software launchable from a Unix command line.

CL-Launch essentially supports two modes of operation:

  • to produce a shell script executable out of a single Lisp file, or
  • to produce a shell script executable that loads a given ASDF project.

In both cases, CL-Launch will autodetect a Common Lisp implementation out of a list of supported ones. You can override the default list if you want. Currently supported are SBCL, CMUCL and CLISP (the ones I use), with partial support for OpenMCL and GCL (ones that I don't use). I'll update my software with any patches that are sent to me so as to better support more implementations.

When run with ASDF projects, CL-Launch will have it cache fasl files in the user's home directory.

CL-Launch is part public-domain (the shell scripting), part LLGPL (the Lisp stub), for having taken snippets out of common-lisp-controller. These licensing terms do not apply to the software that you process with CL-Launch, that can independently use whatever terms the authors may choose. Of course, all this paragraph is only valid if you believe in intellectual property, in which case you'll have to abide by my End-Seller License.

Other features include the ability to define a form to be executed after loading the file, or to run cl-launch on a file already processed by cl-launch so as to upgrade its cl-launch components without touching the rest of the file.

The software is currently only available on my site. It currently consists of three files, which is clumsy: one auxiliary file is required at compile-time, and the other one is required at run-time for ASDF projects. But I have plans to make it better in the near future.

The plan in the immediate future is to merge all three files into one using here-documents, which will remove the hassles both of compile-time and run-time dependencies together with the problem of packaging multiple files. Other desirable improvements would be on the Lisp side to smooth a few things, for instance, the access to the argument list; it would be nice to allow for more configurability of runtime options to Lisp implementations or of FASL location. Don't expect me to do it until I need it, though; however if you do it I'll gladly integrate it with my upstream version.

In a further future, it would be fun to bootstrap later versions to have all the shell maker logic in Lisp but I think I will leave that part as an exercise to the gentle macro-expander. (Obviously the wrapper logic will forever have to remain in shell, even if that shell stuff is one day dumped from an efficient SEX encoding that is eventually usable in other ways than mere shell dumping -- a Lisp-to-shell compiler would be nice.)

2005-08-21 Update: new release according to plan, with all files merged in one [an exercise in Quining], the ability to update the cl-launch part [an exercise in de-quining and re-quining], the ability to specify implementation-dependent options, and smoother command line argument access [and lots of testing]. Still lacking is more configurability of FASL cache location [provided since].



(Post a new comment)


[info]gustavolacerda
2005-08-21 03:51 pm UTC (link)
is this part of your job?

(Reply to this)

nouvelles Bretagne
(Anonymous)
2005-09-03 06:53 pm UTC (link)
Ici tout va bien. Ton grand père s'est cassé le bras droit en tombant!
Donne nous de tes nouvelles
Bises
Papa

(Reply to this)


(Anonymous)
2006-05-14 08:33 pm UTC (link)
http://www.fallenfrukt.com/ucw-intro.html claims that I need cl-launch:

Ucwctl depends on cl-launch, to which a number of ucwtl's configure options are passed. It provides a suite of launch options to invoke lisp from the command-line. Be sure to put a link to cl-launch somewhere in your application search path. For general cl-launch understanding, read the cl-launch documentation.

I read the cl-launch documentation, and I did not understand squat. I have openmcl in /Applications/openmcl/ccl/scripts/openmcl.

How do I call cl-launch to generate the script that ucwctl expects?
--
chr

(Reply to this)(Thread)

wrong place to ask
[info]fare
2006-05-14 10:31 pm UTC (link)
Sorry, I have little recent experience with either UCW or OpenMCL. You should ask for help on the ucw mailing-list or on irc.freenode.net #ucw.

If you experience specific trouble with cl-launch dumping an image with OpenMCL (which is currently untested), I'll gladly accept a patch.

(Reply to this)(Parent)

all
[info]sich67
2007-01-19 11:17 am UTC (link)
hello

(Reply to this)(Parent)


[info]alinemistress
2006-12-22 01:03 pm UTC (link)
Thank you fare! I've looked for such a thing for a long time.

(Reply to this)(Thread)


[info]fare
2006-12-22 04:26 pm UTC (link)
You look strangely like a bot. Do you actually use cl-launch, and if so what for?

(Reply to this)(Parent)


[info]alinemistress
2006-12-25 10:01 am UTC (link)
It's pity that you percieved me like a bot...

(Reply to this)(Thread)

non-bot
[info]fare
2006-12-25 11:29 pm UTC (link)
Call me jaded. I get so much spam and scam on LJ and various electronic communication channels, that I tend to assume a contact is spam until I can see a clear, unambiguous signal that my correspondent actually shares a common interest. You just proved you were not a bot (or that spambot writers have grown more sophisticated than they used to be). You seem civilized enough that you have non-trivial probability of not being a spammer (despite the spelling mistake), though I cannot confirm that yet.

In any case, merry winter holiday season! And thanks a lot if you genuinely like cl-launch (current version is 2.03)

(Reply to this)(Parent)(Thread)

Re: non-bot
[info]alinemistress
2006-12-27 01:21 pm UTC (link)
Thanks for your answers. Speaking about my spelling mistakes I can explain it. English is not my native language, but did you heard about gagauz language, or about gagauz nation?

(Reply to this)(Parent)(Thread)

Re: non-bot
[info]fare
2006-12-27 05:37 pm UTC (link)
I had never heard of the Gagauz nation before today. Just looked it up on Wikipedia. Interesting. The Internet sure brings together people from any origin.

And so I apologize for doubting your humanity. Nice to meet you, alinemistress.

Now, what do you do with cl-launch? What fun Lisp programs do you write?

(Reply to this)(Parent)(Thread)

Re: non-bot
[info]alinemistress
2007-01-03 01:10 pm UTC (link)
Really I don't have a great experience in programming with Lisp. I just want to try and I need some interesting examples with description. So, your example is good for it. I hope I'll understand pieces your of code.

(Reply to this)(Parent)(Thread)

Re: non-bot
[info]fare
2007-01-04 08:09 am UTC (link)
OK. Have you read Practical Common Lisp? (or seen the Google Video?) Otherwise, see cliki.net, join irc #lisp...

(Reply to this)(Parent)(Thread)

Re: non-bot
[info]alinemistress
2007-01-12 03:59 pm UTC (link)
Hi Fare! I just began to read a book. It's a litle bit difficult for me. Thanks for advise;)

(Reply to this)(Parent)


Create an Account
Forgot your login?
Login w/ OpenID
English • Español • Deutsch • Русский…