all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#8330: Undefined macros during compilation in mm-util
@ 2011-03-23 17:58 Stefan Monnier
  2011-03-23 21:08 ` Lennart Borgman
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Stefan Monnier @ 2011-03-23 17:58 UTC (permalink / raw)
  To: 8330

Package: Emacs,Gnus
Version: 24.0.50

mm-til uses the mm-handle-type macro from mm-decode but doesn't require
mm-decode, so the macro call is compiled as a function call, leading to
runtime errors about invalid function.

Adding a (require 'mm-decode) seems to lead to a circular require loop,
so I'm not sure what's the best fix.


        Stefan
        



In GNU Emacs 24.0.50.1 (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2011-03-12 on pastel
Windowing system distributor `The X.Org Foundation', version 11.0.10707000
configured using `configure  '--enable-maintainer-mode' 'CFLAGS=-Wall -Wno-pointer-sign -DUSE_LISP_UNION_TYPE -DSYNC_INPUT -DENABLE_CHECKING -DXASSERTS -DFONTSET_DEBUG -g -O1 -I/usr/include/GNUstep' '--with-x-toolkit=lucid''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: fr_CH.UTF-8
  value of $XMODIFIERS: nil
  locale-coding-system: utf-8-unix
  default enable-multibyte-characters: t

Major mode: Emacs-Lisp

Minor modes in effect:
  diff-auto-refine-mode: t
  outline-minor-mode: t
  flyspell-mode: t
  eldoc-mode: t
  checkdoc-minor-mode: t
  electric-pair-mode: t
  electric-indent-mode: t
  url-handler-mode: t
  global-reveal-mode: t
  reveal-mode: t
  auto-insert-mode: t
  savehist-mode: t
  minibuffer-electric-default-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
C-c @ C-a <down-mouse-5> <mouse-5> <down-mouse-5> <mouse-5> 
<down-mouse-5> <mouse-5> <down-mouse-1> <mouse-1> C-u 
M-x g r e p <return> <left> <left> <left> <left> * 
* / <return> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> C-x v 
l <switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <help-echo> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> M-< <down> <down> <down> <down> C-e 
<return> ( e v a l - w h e n - c o m p <tab> ( r e 
q u i r e SPC ' ' <backspace> m m - d e c o d e C-e 
M-; F o r SPC v a r i o u s SPC m a c r o s . C-x C-s 
<switch-frame> <switch-frame> <select-window> <switch-frame> 
<switch-frame> <select-window> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <select-window> <select-window> 
<select-window> <select-window> <select-window> <select-window> 
<select-window> <select-window> <select-window> <select-window> 
<select-window> <select-window> <select-window> <select-window> 
<select-window> <select-window> <select-window> <select-window> 
<select-window> <select-window> <select-window> <switch-frame> 
<switch-frame> <switch-frame> C-x v = <switch-frame> 
M-b <M-backspace> C-e <backspace> SPC l i k e SPC m 
m - h a n d l e - t y p e . C-a C-x C-s C-x v = <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<down-mouse-1> <mouse-movement> <mouse-1> C-u C-x 5 
1 <up> <up> <up> M-x c d <return> <M-backspace> <M-backspace> 
<M-backspace> w o <tab> <return> <M-return> <select-window> 
<help-echo> C-x 1 <switch-frame> C-c C-a <switch-frame> 
C-x C-s <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> <switch-frame> 
<switch-frame> <switch-frame> <switch-frame> M-x m 
m <backspace> <backspace> b u g - <M-backspace> r e 
p - e m - b u <tab> <return>

Recent messages:
Wrote /home/monnier/src/emacs/trunk/lisp/gnus/mm-util.el
Finding changes in /home/monnier/src/emacs/trunk/lisp/gnus/mm-util.el...done
Saving file /home/monnier/src/emacs/trunk/lisp/gnus/mm-util.el...
Wrote /home/monnier/src/emacs/trunk/lisp/gnus/mm-util.el
Finding changes in /home/monnier/src/emacs/trunk/lisp/gnus/mm-util.el...done
Hunk not yet applied
Hunk applied
diff-hunk-next: No next hunk
Saving file /home/monnier/src/emacs/work/lisp/gnus/mm-util.el...
Wrote /home/monnier/src/emacs/work/lisp/gnus/mm-util.el

Load-path shadows:
/usr/share/emacs23/site-lisp/bbdb/bbdb hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb
/usr/share/emacs23/site-lisp/bbdb/bbdb-mhe hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-mhe
/usr/share/emacs23/site-lisp/bbdb/bbdb-gnus hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-gnus
/usr/share/emacs23/site-lisp/bbdb/bbdb-migrate hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-migrate
/usr/share/emacs23/site-lisp/bbdb/bbdb-sc hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-sc
/usr/share/emacs23/site-lisp/bbdb/bbdb-snarf hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-snarf
/usr/share/emacs23/site-lisp/bbdb/bbdb-w3 hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-w3
/usr/share/emacs23/site-lisp/bbdb/bbdb-gui hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-gui
/usr/share/emacs23/site-lisp/bbdb/bbdb-print hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-print
/usr/share/emacs23/site-lisp/bbdb/bbdb-rmail hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-rmail
/usr/share/emacs23/site-lisp/bbdb/bbdb-vm hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-vm
/usr/share/emacs23/site-lisp/bbdb/bbdb-ftp hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-ftp
/usr/share/emacs23/site-lisp/bbdb/bbdb-merge hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-merge
/usr/share/emacs23/site-lisp/bbdb/bbdb-whois hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-whois
/usr/share/emacs23/site-lisp/bbdb/bbdb-com hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-com
/usr/share/emacs23/site-lisp/bbdb/bbdb-hooks hides /usr/share/emacs/site-lisp/bbdb/lisp/bbdb-hooks

Features:
(mail-extr message sendmail format-spec rfc822 mml mml-sec mm-decode
mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 ietf-drums
mailabbrev mail-utils mailheader emacsbug url-util log-view cl-specs
etags informat info texinfo vc-annotate sh-script smie ediff-merg
ediff-diff ediff-wind ediff-help ediff-util ediff-mult ediff-init ediff
dabbrev make-mode grep compile hideif cpp cmacexp log-edit pcvs-util
cc-mode cc-fonts cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars
cc-defs add-log vc-sccs vc-svn vc-cvs vc-rcs vc-dir skeleton nxml-uchnm
rng-xsd xsd-regexp rng-cmpct rng-nxml rng-valid rng-loc rng-uri
rng-parse nxml-parse rng-match rng-dt rng-util rng-pttrn nxml-ns
nxml-mode nxml-outln nxml-rap nxml-util nxml-glyph nxml-enc xmltok
epa-file epa derived epg epg-config vc vc-dispatcher whitespace
smerge-mode diff-mode executable copyright xscheme trace testcover
scheme unsafep re-builder shadow inf-lisp ielm pp comint ring gmm-utils
ert find-func ewoc debug elp edebug cust-print cus-edit cus-start
cus-load wid-edit vc-bzr sha1 hex-util filecache multi-isearch sort mpc
server noutline outline easy-mmode flyspell ispell eldoc checkdoc
regexp-opt thingatpt help-mode easymenu view prog-mode electric
url-handlers url-parse auth-source warnings eieio byte-opt bytecomp
byte-compile cconv macroexp assoc gnus-util time-date password-cache
url-vars mm-util mail-prsvr reveal autoinsert uniquify advice help-fns
advice-preload savehist minibuf-eldef cl cl-loaddefs proof-site
proof-autoloads pg-vars bbdb-autoloads agda2 tooltip ediff-hook vc-hooks
lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image fringe
lisp-mode register page newcomment menu-bar rfn-eshadow timer select
scroll-bar mouse jit-lock font-lock syntax font-core frame cham georgian
utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
japanese hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev
minibuffer loaddefs button faces cus-face files text-properties overlay
md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote make-network-process dbusbind
dynamic-setting system-font-setting font-render-setting x-toolkit
x multi-tty emacs)





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#8330: Undefined macros during compilation in mm-util
  2011-03-23 17:58 bug#8330: Undefined macros during compilation in mm-util Stefan Monnier
@ 2011-03-23 21:08 ` Lennart Borgman
  2011-03-24 16:09 ` Luca Capello
       [not found] ` <mailman.4.1300985451.20655.bug-gnu-emacs@gnu.org>
  2 siblings, 0 replies; 5+ messages in thread
From: Lennart Borgman @ 2011-03-23 21:08 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: 8330

On Wed, Mar 23, 2011 at 6:58 PM, Stefan Monnier
<monnier@iro.umontreal.ca> wrote:
> Package: Emacs,Gnus
> Version: 24.0.50
>
> mm-til uses the mm-handle-type macro from mm-decode but doesn't require
> mm-decode, so the macro call is compiled as a function call, leading to
> runtime errors about invalid function.
>
> Adding a (require 'mm-decode) seems to lead to a circular require loop,
> so I'm not sure what's the best fix.

Move the macros to a new elisp file?





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#8330: Undefined macros during compilation in mm-util
  2011-03-23 17:58 bug#8330: Undefined macros during compilation in mm-util Stefan Monnier
  2011-03-23 21:08 ` Lennart Borgman
@ 2011-03-24 16:09 ` Luca Capello
       [not found] ` <mailman.4.1300985451.20655.bug-gnu-emacs@gnu.org>
  2 siblings, 0 replies; 5+ messages in thread
From: Luca Capello @ 2011-03-24 16:09 UTC (permalink / raw)
  To: 8330

[-- Attachment #1: Type: text/plain, Size: 4411 bytes --]

severity 8330 important
thanks

Hi there!

On Wed, 23 Mar 2011 18:58:09 +0100, Stefan Monnier wrote:
> Package: Emacs,Gnus
> Version: 24.0.50
>
> mm-til uses the mm-handle-type macro from mm-decode but doesn't require
> mm-decode, so the macro call is compiled as a function call, leading to
> runtime errors about invalid function.

Severity: to important given that this causes most of the email in Gnus
to not be available (latest Debian emacs-snapshot package, version
20110323-1), for example with a post on debian-devel@lists.d.o:

  <http://lists.debian.org/msgid-search/%3c20110324144017.GD8136%40michelle1%3e>

=====
Debugger entered--Lisp error: (invalid-function mm-handle-type)
  mm-handle-type((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil nil nil))
  mm-handle-filename((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil nil nil))
  mm-display-inline-fontify((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil ni$
  mm-inline-text((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil nil nil))
  mm-display-inline((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil nil nil))
  mm-display-part((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil nil nil) t)
  byte-code("^H\203^W^@\306^H\211A^P@   \"\203^@^@\307\300\310\"\210\202^@^@\n\211^[\205\"^@\311\312^K!!)\203/^@r\nq\210\f)\20$
  gnus-mime-display-single((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil nil$
  gnus-mime-display-part((#<buffer  *mm*<2>> ("text/plain" (charset . "iso-8859-1")) quoted-printable nil ("inline") nil nil n$
  gnus-mime-display-security((#("multipart/signed" 0 16 (boundary "=_samba3-13102-1300977618-0001-2" protocol "application/pgp$
  gnus-mime-display-part((#("multipart/signed" 0 16 (boundary "=_samba3-13102-1300977618-0001-2" protocol "application/pgp-sig$
  gnus-display-mime()
  gnus-article-prepare-display()
  gnus-article-prepare(11517 nil)
  gnus-summary-display-article(11517 nil)
  gnus-summary-select-article(nil nil pseudo)
  gnus-summary-scroll-up(1)
  call-interactively(gnus-summary-scroll-up nil nil)
=====

FWIW, re-loading mm-util.el.gz (from Debian emacs-snapshot-el) solves it:

  (load-file "/usr/share/emacs/24.0.50/lisp/gnus/mm-util.el.gz")

> Adding a (require 'mm-decode) seems to lead to a circular require loop,
> so I'm not sure what's the best fix.

I guess because mm-decode requires mm-bodies which requires mm-util...

Thx, bye,
Gismo / Luca
                                    
In GNU Emacs 24.0.50.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.3)
 of 2011-03-23 on cigue, modified by Debian
 (emacs-snapshot package, version 1:20110323-1)
configured using `configure  '--build' 'x86_64-linux-gnu' '--host' 'x86_64-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib' '--localstatedir=/var' '--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes' '--enable-locallisppath=/etc/emacs-snapshot:/etc/emacs:/usr/local/share/emacs/24.0.50/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/24.0.50/site-lisp:/usr/share/emacs/site-lisp' '--without-compress-info' '--with-x=yes' '--with-x-toolkit=gtk' '--with-imagemagick=yes' 'build_alias=x86_64-linux-gnu' 'host_alias=x86_64-linux-gnu' 'CFLAGS=-DDEBIAN -DSITELOAD_PURESIZE_EXTRA=5000 -g -O2' 'LDFLAGS=-g -Wl,--as-needed' 'CPPFLAGS=''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: en_US.UTF-8
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: en_US.UTF-8
  value of $LC_TIME: nil
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: nil
  locale-coding-system: utf-8-unix
  default enable-multibyte-characters: t

Major mode: Summary

Minor modes in effect:
  gpm-mouse-mode: t
  display-battery-mode: t
  display-time-mode: t
  show-paren-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t

[-- Attachment #2: Type: application/pgp-signature, Size: 835 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: bug#8330: Undefined macros during compilation in mm-util
       [not found] ` <mailman.4.1300985451.20655.bug-gnu-emacs@gnu.org>
@ 2011-03-25 18:45   ` Ted Zlatanov
  2011-03-25 22:14     ` Ted Zlatanov
  0 siblings, 1 reply; 5+ messages in thread
From: Ted Zlatanov @ 2011-03-25 18:45 UTC (permalink / raw)
  To: bug-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 44 bytes --]

Please try the attached patch.

Thanks
Ted


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: mm-handle-filename-moved.patch --]
[-- Type: text/x-diff, Size: 1141 bytes --]

diff --git a/lisp/mm-decode.el b/lisp/mm-decode.el
index 3909e12..f543920 100644
--- a/lisp/mm-decode.el
+++ b/lisp/mm-decode.el
@@ -1744,6 +1744,13 @@ If RECURSIVE, search recursively."
 	    (delete-region ,(point-min-marker)
 			   ,(point-max-marker))))))))
 
+(defun mm-handle-filename (handle)
+  "Return filename of HANDLE if any."
+  (or (mail-content-type-get (mm-handle-type handle)
+                             'name)
+      (mail-content-type-get (mm-handle-disposition handle)
+                             'filename)))
+
 (provide 'mm-decode)
 
 ;;; mm-decode.el ends here
diff --git a/lisp/mm-util.el b/lisp/mm-util.el
index d53784e..435c3bb 100644
--- a/lisp/mm-util.el
+++ b/lisp/mm-util.el
@@ -1667,13 +1667,6 @@ gzip, bzip2, etc. are allowed."
 	(when decomp
 	  (kill-buffer (current-buffer)))))))
 
-(defun mm-handle-filename (handle)
-  "Return filename of HANDLE if any."
-  (or (mail-content-type-get (mm-handle-type handle)
-                             'name)
-      (mail-content-type-get (mm-handle-disposition handle)
-                             'filename)))
-
 (provide 'mm-util)
 
 ;;; mm-util.el ends here

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: bug#8330: Undefined macros during compilation in mm-util
  2011-03-25 18:45   ` Ted Zlatanov
@ 2011-03-25 22:14     ` Ted Zlatanov
  0 siblings, 0 replies; 5+ messages in thread
From: Ted Zlatanov @ 2011-03-25 22:14 UTC (permalink / raw)
  To: bug-gnu-emacs

On Fri, 25 Mar 2011 13:45:07 -0500 Ted Zlatanov <tzz@lifelogs.com> wrote: 

TZ> Please try the attached patch.

It seemed to work for me so I pushed it into the Gnus Git repository;
please let me know if you have issues with it.

Ted


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-03-25 22:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-23 17:58 bug#8330: Undefined macros during compilation in mm-util Stefan Monnier
2011-03-23 21:08 ` Lennart Borgman
2011-03-24 16:09 ` Luca Capello
     [not found] ` <mailman.4.1300985451.20655.bug-gnu-emacs@gnu.org>
2011-03-25 18:45   ` Ted Zlatanov
2011-03-25 22:14     ` Ted Zlatanov

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.