Installation, Implementations and the Development Environment

2.1 Implementations

SBCL (Steel Bank Common Lisp) Free, fast native compiler, most popular; monthly releases CCL (Clozure CL)

Free, fast compiler, good macOS support, fast compilation ECL (Embeddable CL)

Compiles via C; embeddable in C programs; mobile targets ABCL (Armed Bear CL) Runs on the JVM with Java interop

Bytecode interpreter, very portable (slower) LLVM-based, seamless C++ interop

Commercial, excellent IDE and CAPI GUI toolkit, delivery tools (free Personal edition) Allegro CL (Franz)

Commercial, AllegroGraph, IDE (free Express edition)

2.2 Installing SBCL

# Linux
sudo apt install sbcl                 # Debian/Ubuntu (may be older)
# macOS
brew install sbcl
# Windows: installer from sbcl.org, or scoop install sbcl / choco install sbcl
# Version managers: roswell (ros install sbcl-bin), or build from source
sbcl --version

2.3 Installing Quicklisp (the Library Manager)

curl -O https://beta.quicklisp.org/quicklisp.lisp
sbcl --load quicklisp.lisp
(quicklisp-quickstart:install)
(ql:add-to-init-file)                 ; load Quicklisp automatically on startup
(ql:quickload "alexandria")           ; download and load a library

2.4 Editors and IDEs

Emacs + SLIME or Sly The classic: REPL, debugger, inspector, compile-and-load, cross-reference, macroexpansion

Portable, preconfigured Emacs + SBCL + Quicklisp + Git bundle

An editor written in Common Lisp (SLIME-like features built in) VS Code + Alive REPL integration, debugger, inspection

Vim/Neovim + Vlime / Slimv / Conjure SLIME-style integration for Vim users LispWorks IDE, Allegro IDE Jupyter + common-lisp-jupyter

2.5 Hello, World

;;;; hello.lisp
(defun main ()
  (format t "Hello, World!~%"))

(main)
sbcl --script hello.lisp              # run as a script
sbcl --load hello.lisp                # load, then stay in the REPL
sbcl --non-interactive --eval '(print (+ 1 2))'