emacs 23.1 doesn't work with slime

Discussion of programming Lisps using Emacs, including SLIME and other tools
Post Reply
dbdkmezz
Posts: 6
Joined: Sat Jul 25, 2009 9:26 am

emacs 23.1 doesn't work with slime

Post by dbdkmezz » Wed Aug 05, 2009 6:02 am

Hi,

I've just upgraded to emacs 23.1 (by compiling the source), but now when I use emacs 23.1 slime doesn't work. If I run the old version of emacs then everything is still OK.

This is the error I get:

Code: Select all

Couldn't load "/usr/share/emacs/site-lisp/slime/swank-loader.lisp": file does not exist.
Which isn't surprising, since swank-loader.lisp is located "/usr/share/common-lisp/source/slime/".

By the way, Slime itself is installed somewhere else, at "/usr/share/emacs/site-lisp/slime/", so in my .emacs file I use the line:

Code: Select all

(add-to-list 'load-path "/usr/share/emacs/site-lisp/slime")
So I'm wondering if the problem is due to ubuntu installing slime and cl-swank in different places. But then again, why would emacs22 have worked, and not 23.1?

I've noticed that the progn that is run at the start of *inferior-lisp* has changed. In the old version of emacs it loaded swank-loader.lisp from the correct directory, but in the new is now looks in slime's directory. Here is the progn run in emacs 23.1:

Code: Select all

(progn (load "/usr/share/emacs/site-lisp/slime/swank-loader.lisp" :verbose t) (funcall (read-from-string "swank-loader:init")) (funcall (read-from-string "swank:start-server") "/tmp/slime.23519" :coding-system "iso-latin-1-unix")) 
And under emacs 22 it is this:

Code: Select all

(progn (load "/usr/share/common-lisp/source/slime/swank-loader.lisp" :verbose t) (funcall (read-from-string "swank-loader:init")) (funcall (read-from-string "swank:start-server") "/tmp/slime.24088" :coding-system "iso-latin-1-unix"))
I'm running kubuntu 9.04, and have installed slime, cl-swank and sbcl all from the official ubuntu repositories.

Anyone got any ideas?

(By the way, I tried to grab the latest version of slime and sbcl off their web pages, and use them. But then I still didn't get a proper repl promt, but no errors (a couple of warnings though). All I got was a star promt in *inferior-lisp*, just like as if I had just run sbcl from the command line. A quick google implied that slime is in transition and a bit broken at the moment, so I think I'll just stick with ubuntu's version, sine I know that works (with the old version of emacs))

Thanks

ramarren
Posts: 613
Joined: Sun Jun 29, 2008 4:02 am
Location: Warsaw, Poland
Contact:

Re: emacs 23.1 doesn't work with slime

Post by ramarren » Wed Aug 05, 2009 7:04 am

I'm using current slime with Emacs 23 (lexbind branch though, which was last merged into four months ago I think), and it works. I don't use Ubuntu, so I am not sure, but I think that their repositories have very old versions of both slime and sbcl, and it is usually recommended to use something like clbuild to build your own from sources.
dbdkmezz wrote:(By the way, I tried to grab the latest version of slime and sbcl off their web pages, and use them. But then I still didn't get a proper repl promt, but no errors (a couple of warnings though). All I got was a star promt in *inferior-lisp*, just like as if I had just run sbcl from the command line. A quick google implied that slime is in transition and a bit broken at the moment, so I think I'll just stick with ubuntu's version, sine I know that works (with the old version of emacs))
As far as I know current Slime is not broken, at least not more than most of the time. What you are seeing is an effect of splitting REPL into a contrib. No contribs are loaded by default, which is a bit unfortunate, since current bare slime has pretty minimal functionality. You need at least

Code: Select all

(slime-setup '(slime-repl))
in your .emacs, but usually using a metacontrib with

Code: Select all

(slime-setup '(slime-fancy))
is better, since it loads many features which were split from Slime proper in the last few years.

dbdkmezz
Posts: 6
Joined: Sat Jul 25, 2009 9:26 am

Re: emacs 23.1 doesn't work with slime

Post by dbdkmezz » Wed Aug 05, 2009 7:20 am

Ramarren wrote:(slime-setup '(slime-fancy))
That was exactly what I needed. Everything works with the latest version of slime now :D

It feels quicker too :)

(By the way, I didn't need to use cbuild or anything, just grabbed the slime and sbcl binaries from their web sites.)

Thanks!

Post Reply