all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#8660: 23.2; info-look.el makefile-mode derivatives
@ 2011-05-12  0:21 Kevin Ryde
  2011-05-12  3:11 ` Stefan Monnier
  0 siblings, 1 reply; 8+ messages in thread
From: Kevin Ryde @ 2011-05-12  0:21 UTC (permalink / raw)
  To: 8660

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

C-h S in the various makefile-mode derivatives such as
makefile-gmake-mode for GNUmakefile prompts for

    Use symbol help mode:

where I hoped it would already know what to do.

Perhaps something like the following, also confining the automake manual
things to the automake mode.  It and the make manual overlap in a few
places, mainly variables like LFLAGS etc.

2011-05-11  Kevin Ryde  <user42@zip.com.au>

	* info-look.el (makefile-automake-mode): New setups, looking in
	automake manual, then makefile-mode.
	(makefile-mode): Remove automake manual, have it just in
	makefile-automake-mode.  Remove non-existent automake-mode,
	believe a hypothetical automake-mode would go to makefile-mode,
	not the other way around.
	(makefile-bsdmake-mode, makefile-gmake-mode, makefile-imake-mode)
	(makefile-makepp-mode): New setups, just going to makefile-mode.
	In particular makefile-gmake-mode lets lookups work from a
	GNUmakefile.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: info-look.el.makefile-derivatives.diff --]
[-- Type: text/x-diff, Size: 2281 bytes --]

--- info-look.el.orig	2011-05-12 08:36:49.000000000 +1000
+++ info-look.el	2011-05-12 10:13:37.000000000 +1000
@@ -720,11 +720,44 @@
  :mode 'makefile-mode
  :regexp "\\$[^({]\\|\\.[_A-Z]*\\|[_a-zA-Z][_a-zA-Z0-9-]*"
  :doc-spec '(("(make)Name Index" nil
-	      "^[ \t]*`" "'")
-	     ("(automake)Macro and Variable Index" nil
 	      "^[ \t]*`" "'"))
- :parse-rule "\\$[^({]\\|\\.[_A-Z]*\\|[_a-zA-Z0-9-]+"
- :other-modes '(automake-mode))
+ :parse-rule "\\$[^({]\\|\\.[_A-Z]*\\|[_a-zA-Z0-9-]+")
+
+(info-lookup-maybe-add-help
+ :topic      'symbol
+ :mode       'makefile-automake-mode
+ ;; similar regexp/parse-rule as makefile-mode, but also
+ ;;   "##" special automake comment
+ ;;   "+=" append operator, separate from the GNU make one
+ :regexp     "\\$[^({]\\|\\.[_A-Z]*\\|[_a-zA-Z][_a-zA-Z0-9-]*\\|##\\|\\+="
+ :parse-rule "\\$[^({]\\|\\.[_A-Z]*\\|[_a-zA-Z0-9-]+\\|##\\|\\+="
+ :doc-spec   '(
+               ;; "(automake)Macro Index" is autoconf macros used in
+               ;; configure.in, not Makefile.am, so don't have that here.
+               ("(automake)Variable Index" nil "^[ \t]*`" "'")
+               ;; In automake 1.4 macros and variables were a combined node.
+               ("(automake)Macro and Variable Index" nil "^[ \t]*`" "'")
+               ;; Directives like "if" are in the "General Index".
+               ;; Prefix "`" since the text for say `+=' isn't always an
+               ;; @item etc and so not always at the start of a line.
+               ("(automake)General Index" nil "`" "'")
+               ;; In automake 1.3 there was just a single "Index" node.
+               ("(automake)Index" nil "`" "'"))
+ :other-modes '(makefile-mode))
+
+;; makefile-mode derivatives going to plain makefile-mode.
+(let ((regexp     (info-lookup->regexp     'symbol 'makefile-mode))
+      (parse-rule (info-lookup->parse-rule 'symbol 'makefile-mode)))
+  (dolist (mode '(makefile-bsdmake-mode
+                  makefile-gmake-mode
+                  makefile-imake-mode
+                  makefile-makepp-mode))
+    (info-lookup-maybe-add-help
+     :topic       'symbol
+     :mode        mode
+     :regexp      regexp
+     :parse-rule  parse-rule
+     :other-modes '(makefile-mode))))
 
 (info-lookup-maybe-add-help
  :mode 'texinfo-mode

[-- Attachment #3: Type: text/plain, Size: 1056 bytes --]






In GNU Emacs 23.2.1 (i486-pc-linux-gnu, GTK+ Version 2.20.0)
 of 2010-05-16 on raven, modified by Debian
configured using `configure  '--build' 'i486-linux-gnu' '--build' 'i486-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib' '--localstatedir=/var/lib' '--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes' '--enable-locallisppath=/etc/emacs23:/etc/emacs:/usr/local/share/emacs/23.2/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/23.2/site-lisp:/usr/share/emacs/site-lisp:/usr/share/emacs/23.2/leim' '--with-x=yes' '--with-x-toolkit=gtk' '--with-toolkit-scroll-bars' 'build_alias=i486-linux-gnu' 'CFLAGS=-DDEBIAN -g -O2' 'LDFLAGS=-g' 'CPPFLAGS=''

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: en_AU
  value of $XMODIFIERS: nil
  locale-coding-system: iso-latin-1-unix
  default enable-multibyte-characters: t

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

end of thread, other threads:[~2013-02-16 17:21 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-12  0:21 bug#8660: 23.2; info-look.el makefile-mode derivatives Kevin Ryde
2011-05-12  3:11 ` Stefan Monnier
2011-05-14  1:37   ` Kevin Ryde
2011-05-14  3:55     ` Stefan Monnier
2011-05-16  0:02       ` Kevin Ryde
2011-05-16 17:42         ` Stefan Monnier
2013-02-16  0:02       ` Kevin Ryde
2013-02-16 17:21         ` Stefan Monnier

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.