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

Trouble with byte-compiling .el files on Emacs update



An emacs22 upgrade that was recently installed broke when it tried to
byte-compile a part of sepia (for which I maintain the Debian
package). This is the output I got when I tried to reinstall the
emacs22-gtk package:

$ sudo apt-get --reinstall install emacs22-gtk
[...]
emacs-install emacs22
install/a2ps: Handling install for emacsen flavor emacs22
Wrote /usr/share/emacs22/site-lisp/a2ps/a2ps.elc
Wrote /usr/share/emacs22/site-lisp/a2ps/a2ps-print.elc
[...]
Wrote /usr/share/emacs22/site-lisp/sepia/sepia-cpan.elc
Wrote /usr/share/emacs22/site-lisp/sepia/sepia.elc
Wrote /usr/share/emacs22/site-lisp/sepia/sepia-ido.elc
Source file `/usr/share/emacs22/site-lisp/sepia/snippet.el' newer than byte-compiled file
Wrote /usr/share/emacs22/site-lisp/sepia/sepia-snippet.elc
Wrote /usr/share/emacs22/site-lisp/sepia/sepia-tree.elc

In toplevel form:
sepia-w3m.el:37:13:Error: Cannot open load file: w3m-perldoc
Wrote /usr/share/emacs22/site-lisp/sepia/snippet.elc
emacs-install: /usr/lib/emacsen-common/packages/install/sepia emacs22 failed at /usr/lib/emacsen-common/emacs-install line 28, <TSORT> line 56.
dpkg: error processing emacs22-gtk (--configure):
 subprocess post-installation script returned error exit status 1
Errors were encountered while processing:
 emacs22-gtk
E: Sub-process /usr/bin/dpkg returned an error code (1)


w3m-perldoc is part of the w3m-el package, but that hasn't been
through the byte-compilation process at this point.

I first suspected that

	(eval-when-compile
	  (require 'w3m-perldoc))

was causing the error, so I changed that to

	(require 'w3m-perldoc)

but this doesn't help because byte-compiling executes any `require'
calls at top level.

Is there any way to ensure that the files from w3m-el are handled
before the files from sepia? A dependency on w3m-el is declared in the
package of course, but that obviously doesn't help since the error
happens in the postinst of the emacs package.

Cheers,
-Hilko


Reply to: