CodyReichert/awesome-cl

Buildapp & cl-launch?

rbugajewski opened this issue · 3 comments

Is there a reason why Buildapp and cl-launch aren’t listed (but similar tools like Roswell are)?

Hello, yes, because:

  • to build executables, they seem deprecated by asdf:make which does it portably
  • they look superseded by Roswell
  • (buildapp might have --dispatched-entry unique to it)
  • they look old and have poor doc
  • the State of CL of 2015 says "kill cl-launch, use Roswell" https://borretti.me/article/common-lisp-sotu-2015
  • this list doesn't aim to list every available tool or library
  • I didn't feel the need for them and we didn't receive PRs with explanations.

Best,

Thank you very much for this detailed explanation!

For Common Lisp, look into cl-launch. It's meant to abstract over the details of scripting and building executables across different CL implementations. roswell I find to be way too opinionated in how it does things.

For cl-launch "scripts", you can add something like exec cl-launch -Q -sp ${name-of-package} -r main -- "$@" to the top of the file for your script so that you can run it from the command line with cl-launch your-script.lisp (just make sure you have a main function that is a command line interface). To build an executable with cl-launch, you can run something like cl-launch -o ${name-of-binary} -d ! -Q -r main -L ${your-script}.lisp.

Some caveats I've found with using cl-launch is that the command line options can be very finnicky and complicated, and for some reason I haven't gotten it to work with building an ECL executable. But it's overall the simplest and most portable solution I've found for running CL code as scripts and building executables.

https://www.reddit.com/r/lisp/comments/zwtfak/writing_scripts_in_lisp/j1x6xws/

To answer myself:

to build executables, they seem deprecated by asdf:make which does it portably

cl-launch allows to build a binary from the command line. Might be useful, easier to do for some,

AND it gives a shebang line to run files as scripts (and do it portably across implemenetations, otherwise we can do it with a SBCL shebang line).

they look superseded by Roswell

but Roswell has its own way to do things (it uses its own Quicklisp directory etc).

they look old and have poor doc

still applies.

I didn't feel the need for them and we didn't receive PRs with explanations.

I might see a need…