[英]load external with emacs-slime
I'd like to install slime on my Emacs 23.2.1. 我想在Emacs 23.2.1上安装史莱姆。 Since Mx slime
doesn't succeed in start it, I modified the ~/.emacs file. 由于Mx slime
无法成功启动,因此我修改了〜/ .emacs文件。
(setq inferior-lisp-program "/usr/bin/sbcl")
(add-to-list 'load-path "/usr/share/emacs/site-lisp/slime/")
(require 'slime)
(slime-setup)
Of course this doesn't work for the slime path in the second line of ~/.emacs file should be /usr/share/common-lisp/source/swank
instead. 当然,这不适用于〜/ .emacs文件第二行中的粘液路径,而应改为/usr/share/common-lisp/source/swank
。 However, after I changed this directory, the error remains. 但是,更改此目录后,错误仍然存在。 It says like this: 它说像这样:
Couldn't load "/usr/share/emacs/site-lisp/slime/swank-loader.lisp": file does not exist. 无法加载“ /usr/share/emacs/site-lisp/slime/swank-loader.lisp”:文件不存在。
Why would this load external remain and how to make these things right? 为什么这种外部负载仍然存在,以及如何使这些事情正确?
This post on LispForum suggests adding the following line to your .emacs: 这个职位上LispForum建议增加以下行到你的.emacs:
(slime-setup '(slime-fancy))
The explanation for the error: 错误的解释:
What you are seeing is an effect of splitting REPL into a contrib. 您所看到的是将REPL拆分为贡献的效果。 No contribs are loaded by default, which is a bit unfortunate, since current bare slime has pretty minimal functionality. 默认情况下不加载任何贡献,这有点不幸,因为当前的裸泥只有很少的功能。
Edit : OK, what platform, Emacs, and Slime version are you using? 编辑 :好的,您正在使用什么平台,Emacs和Slime版本? I'm using Emacs 24 on Ubuntu. 我在Ubuntu上使用Emacs 24。 I installed slime using apt-get. 我使用apt-get安装了史莱姆。 I was seeing the same error as you: 我看到了与您相同的错误:
Couldn't load "/usr/share/emacs/site-lisp/slime/swank-loader.lisp": file does not exist.
I fixed it using the method suggested in this answer : 我使用此答案中建议的方法修复了该问题 :
The next thing to try is Mx customize-variable slime-backend and setting that to the absolute path of swank-loader.lisp. 接下来要尝试的是Mx customize-variable粘液后端,并将其设置为swank-loader.lisp的绝对路径。 I think that will fix it for sure, but I am not sure why it doesn't work to begin with. 我认为可以肯定会解决此问题,但是我不确定为什么一开始它不起作用。
I had to customize the value of slime-backend
to /usr/share/common-lisp/source/slime/swank-loader.lisp
to get Mx slime
to work. 我必须将slime-backend
的值自定义为/usr/share/common-lisp/source/slime/swank-loader.lisp
才能使Mx slime
正常工作。
On debian sid Mon. 在debian sid周一。 Jan. 27 22:18 CET - I had to install cl-swank 1月27日22:18 CET-我必须安装cl-swank
This error occurred for me and it boiled down to /etc/emacs/site-start.d having a 50slime file without the cl-swank and slime packages being installed (on a debian variant) 对我而言,发生了此错误,并将其简化为/etc/emacs/site-start.d,其中包含50slime文件,而未安装cl-swank和slime软件包(在debian变体上)
In my case I had removed them so I could have a more current slime, so I just deleted the file. 在我的情况下,我已将它们删除,以便可以拥有更多当前的史莱姆,因此我只是删除了该文件。 The other way is to just install the packages ("apt-get install cl-swank slime") and use the packaged versions. 另一种方法是仅安装软件包(“ apt-get install cl-swank粘液”)并使用打包的版本。
Hope that helps someone. 希望能对某人有所帮助。
I think you should use Quicklisp wich is a package installer for Common Lisp. 我认为您应该使用Quicklisp,这是Common Lisp的软件包安装程序。 It has a slime package that is usually updated to the most recent version. 它具有一个史莱姆软件包,通常会将其更新为最新版本。 The Quicklisp web site has all the instructions you'll need to configure emacs and slime. Quicklisp网站提供了配置emacs和史莱姆所需的所有说明。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.