简体   繁体   English

emacs elpa版本的auctex没有“ auctex.el”

[英]emacs elpa version of auctex has no “auctex.el”

To set up auctex in Emacs you are told to include 要在Emacs中设置auctex,系统会提示您包括

(load "auctex.el" nil t t)

...etc. ...等等。 in your init/.emacs file. 在您的init / .emacs文件中。 But if you installed auctex with elpa (which puts files in ~/.emacs.d/elpa/auctex-11.86/), you have no auctex.el and the (load ...) fails. 但是,如果使用elpa安装auctex(将文件放置在〜/ .emacs.d / elpa / auctex-11.86 /中),则没有auctex.el,并且(load ...)失败。 What should I do? 我该怎么办?

Instead of loading nonexistent auctex.el do 而不是加载不存在的auctex.el而是

(require 'tex)

which initializes AUCTeX for me (Windows Emacs 24.3 and pdflatex from Cygwin). 它会为我初始化AUCTeX(来自Cygwin的Windows Emacs 24.3和pdflatex)。 If you have MiKTeX, you would also need 如果您拥有MiKTeX,则还需要

(require 'tex-mik)

Another potential problem with the package from elpa is the tex-site.el which is supposed to be generated during installation and contain system-specific data but gets installed from elpa instead. elpa软件包的另一个潜在问题是tex-site.el ,它应该在安装过程中生成并包含特定于系统的数据,但可以从elpa安装。 You may want to examine the file and make corrections if needed (and copy it to some other location which is listed earlier in your load-path ). 您可能需要检查文件并根据需要进行更正(并将其复制到load-path前面列出的其他位置)。 For instance it has some unix paths which make no sense in Windows environment. 例如,它具有一些在Windows环境中没有意义的unix路径。

Your problem is most likely due to the package initialization problem discussed here: Emacs 24 Package System Initialization Problems 您的问题很可能是由于此处讨论的程序包初始化问题引起的: Emacs 24程序包系统初始化问题

You need to call (package-initialize) before calling load to not get an error. 您需要在调用load之前调用(package-initialize) ,以免出错。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM