[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: python-mode not working in Ubuntu
From: |
Peter Dyballa |
Subject: |
Re: python-mode not working in Ubuntu |
Date: |
Sun, 23 Aug 2009 20:28:25 +0200 |
Am 23.08.2009 um 02:24 schrieb travis+ml-emacs@subspacefield.org:
Can anyone please help me figure out how to troubleshoot this?
Launch GNU Emacs with -q and check the value of the variable load-
path. When it does not contain the element /usr/share/emacs/site-lisp/
python-mode then you'll need to add it, because GNU Emacs searches in
the directories given by load-path for .EL or .ELC files. You can do
it like this in your init file (which won't make the error from /etc/
emacs/site-start.d/50python-mode.el go away):
(add-to-list 'load-path "/usr/share/emacs/site-lisp/python-mode")
If this element is contained in load-path, then the syntax to load
that file is obviously faulty. The error message cites "Cannot open
load file" so it seems that the function load-file is used, which
assumes that the given file is complete, i.e., its extension is
named. The correct function call should be load-library. If the
latter is used *and* /usr/share/emacs/site-lisp/python-mode is in
load-path then the variables load-suffixes and load-file-rep-suffixes
could be wrong. The former should contain el and elc, the latter gz
to enable a modern GNU Emacs to load gzip'ed ELisp files.
Interactively you could try:
M-x load-library RET python-mode RET
The file python-mode.el seems to be an XEmacs file. GNU Emacs comes
with python.el. I think its "loaded" into GNU Emacs. The variable
auto-mode-alist should contain a mapping from .py files to python-
mode. So there should be no need for a python-mode.el file. Maybe
you'll have more success when you remove the python-mode package
(which should be easy).
--
Greetings
Pete
Rain is saved up in cloud banks.