Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7504963
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T21:45:05+00:00 2026-05-29T21:45:05+00:00

I am currently have a small program in Common Lisp, which I want to

  • 0

I am currently have a small program in Common Lisp, which I want to run as a shell script. I am using the SBCL and perfectly fine with this so will prefer to stay on this platform. 🙂

I am aware about the --script option and it works flawlessly except for (ql:quickload) form.

My program uses the CL-FAD, which loads through ql:quickload (I think I should mention that it is package-loading function from quicklisp). When script runs up to evaluating the

(ql:quickload :cl-fad)

form, it breaks with the next error:

package "QL" not found

Program is packed in the single source file, which has following header:

(defpackage :my-package
  (:use :common-lisp)
  (:export :my-main-method))

It is simple automation executable, so I decided (maybe erroneously) not to write any ASDF system. It exports single function which should be run without any arguments.

For this program I am currently trying to write the launcher script, and this is what I am staring at:

#!/usr/bin/sbcl --script
(load "my-program.lisp")
(in-package :my-package)
(my-main-method)

This three lines (not counting the shebang) is what I am want to automate. As I read in documentation, script with this shebang can be called as simple ./script.lisp, and it really does this… with the error described before.

What I need to add in the launcher for :cl-fad to load properly? Documentation states that with --script option SBCL doesn’t load any init file, so do I really need to copypaste the lines

#-quicklisp
(let ((quicklisp-init (merge-pathnames "systems/quicklisp/setup.lisp"
                                       (user-homedir-pathname))))
  (when (probe-file quicklisp-init)
    (load quicklisp-init)))

(which ql:add-to-init-file adds to .sbclrc), to my launcher script?
Maybe I have some deep architectural flaw in my program setup?

And yes, when I enter the lines which I try to automate in REPL in the sbcl itself, program runs as expected.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T21:45:08+00:00Added an answer on May 29, 2026 at 9:45 pm

    Creating a dedicated version of core image is a good option. You may:

    1. load quicklisp and sb-ext:save-lisp-and-die in a new image. You write a shell/bat script named, say qlsbcl, like this:

      sbcl --core <my-new-image-full-path-location> "$@"
      
    2. grab clbuild2 at http://gitorious.org/clbuild2 and run clbuild lisp. You’ll have to symlink clbuild to a binary directory in your path and tweak some scripts a bit if your quicklisp is not in the common place ~/quicklisp (https://gist.github.com/1485836) or if you use ASDF2 (https://gist.github.com/1621825). By doing so, clbuild create a new core with quicklisp, ASDF and anything you may add in conf.lisp. Now the shebang may look like this:

      #!/usr/bin/env sbcl --noinform --core <my-clbuild-install-directory>/sbcl-base.core --script
      

    The advantage of clbuild is that you may easily create and manage core and quicklisp installation from shell for sbcl (by default) or any other modern CL like ccl64 implementation. Mixing the two techniques (script and clbuild) will solve your problem.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I currently have a small Java program which I would like to run both
We have a small 3 developer team that is currently using Subversion for our
In GNU Emacs, I want to run a program, figlet, on the currently selected
I have written a small example C++ program, using boost::thread. Since it's 215 lines,
I am currently learning to program on iPhone. I currently have a small test
i'm currently (trying) to program a little game. And i have a small design/deadlock
So, we have a large program which uses HttpListener for a small remote admin
I currently have a small laptop and a desktop (+ gaming rig) that I
We (small team) currently have our Visual Studio projects on a network drive (no
I am working with a small theatre company. Currently they have a list of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.