Installing a Lisp environment

on Mac OS X

  1. Download and install ​Emacs.
  2. Download ​Clozure Common Lisp (CCL). Unpack the archive and then move the ccl folder somewhere where you want to keep it, for example to your home directory (or, if you know how to do that, to /usr/local/ccl).
  3. If you have ​Fink, Macports or Homebrew installed (and know what that is), then use it to install ​Graphviz and ​Gnuplot. Proceed to step 5.
  4. We will now install macports which will enable us to install gnuplot and graphviz easily.
    • Run this line in a terminal and follow instructions:
    •     xcode-select --install
      
    • Download and install Macports.
    • Open Terminal.app (can be found in Applications/Utilities or use Spotlight) and type (the first command will require your password)
          sudo port install gnuplot
          sudo port install graphviz
          sudo ln -s /opt/local/bin/gnuplot /usr/bin/gnuplot
      
  5. Download the latest ​Slime (use “cvs snapshot in tarfile format”), unpack it, rename the unpacked folder slime-xxxx-xx-xx to slime and move it somewhere where you want to keep it, for example to your home directory (or, if you know what your are doing, to /usr/local/slime).
  6. For configuring your Emacs, use a text editor to create a plain text file called .emacs (without extension) in your home directory (~/.emacs) with this content (adapt the paths to your slime and to your ccl):
      (custom-set-variables
       '(show-paren-mode t)
       '(size-indication-mode t)
       '(tool-bar-mode nil)
       '(transient-mark-mode t)
       '(column-number-mode t)
       '(indent-tabs-mode nil)
       '(make-backup-files nil))
    
      (set-face-foreground 'font-lock-string-face "navy")
    
      (setq mac-allow-anti-aliasing t)
      ;;(require 'mac-key-mode)
      ;;(mac-key-mode 1)
      ;;(pc-selection-mode 1)
      ;;(setq mac-option-modifier 'meta)
    
      (add-to-list 'load-path "/Users/yourusername/slime") ;; change this
    
      (require 'slime)
      (slime-setup '(slime-repl slime-autodoc slime-fancy-inspector))
    
      (setq inferior-lisp-program "/Users/yourusername/ccl/dx86cl64") ;; change this
      ;; use this on a 32Bit Mac (only if your mac is pretty old)
      ;;(setq inferior-lisp-program "/Users/yourusername/ccl/dx86cl") ;; if needed, change this
      (command-execute 'slime)
    
  7. Done! When you start Emacs it hopefully automatically starts a Lisp and looks like this
  8. If not, then something in the steps above went wrong, try again.
  9. Time to install Babel 2.