emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: awk-mode not defined in current CVS Emacs


From: Alan Mackenzie
Subject: Re: awk-mode not defined in current CVS Emacs
Date: Fri, 19 Nov 2004 22:39:53 +0000 (GMT)

Hi, Glenn,

On Wed, 17 Nov 2004, Glenn Morris wrote:


>With the current CVS GNU Emacs, started as `emacs -q --no-site-file',
>the function `awk-mode' is not defined, until one explicitly does
>(require 'cc-mode).

I'm not totally familiar with the Emacs building mechanism, but:

The autoload forms for CC Mode's modes are in cc-mode.el.  Around line
1009 are the following lines:

;;; Autoload directives must be on the top level, so we construct an
;;; autoload form instead.
;;;###autoload (autoload 'awk-mode "cc-mode" "Major mode for editing AWK code.")

This rather unusual form is used for the AWK Mode autoload because the
new version of AWK Mode (first released with CC Mode 5.30 in June 2003)
only supersedes the older awk-mode.el when (>= emacs-version 20.1).

Starting from a 21.3 loaddefs.el, if I run M-x update-file-autoloads <CR>
~/cc-mode-5.30.n/cc-mode.el <CR>

, I get the following line (amongs others) inserted into my loaddefs.el:

(autoload 'awk-mode "cc-mode" "Major mode for editing AWK code.")

.  Now, I assume that at Emacs building time, update-file-autoloads (or
some batch equivalent) is run on every file.el.  Could you perhaps check
the following:

1/- Your cc-mode.el is a version 5.30.n one  (i.e., it contains the
above AWK Mode autoload form).

2/- The loaddefs.el that you generate by building Emacs contains the
above AWK Mode autoload.

3/- This autoload in loaddefs.el works when Emacs is dumped.  (OK, you're
bug report is that it _doesn't_ work, but you know what I mean.)

4/- If the AWK Mode autoload _isn't_ there, are the following other
forms?
 (add-to-list 'auto-mode-alist '("\\.awk\\'" . awk-mode))
 (add-to-list 'interpreter-mode-alist '("awk" . awk-mode))
 (add-to-list 'interpreter-mode-alist '("mawk" . awk-mode))
 (add-to-list 'interpreter-mode-alist '("nawk" . awk-mode))
 (add-to-list 'interpreter-mode-alist '("gawk" . awk-mode))

Any further ideas?

-- 
Alan Mackenzie (Munich, Germany)






reply via email to

[Prev in Thread] Current Thread [Next in Thread]