home *** CD-ROM | disk | FTP | other *** search
Wrap
Makefile | 1994-05-23 | 26.0 KB | 302 lines
;ELC ;;; compiled by rms@mole.gnu.ai.mit.edu on Sun May 22 18:30:10 1994 ;;; from file /home/fsf/rms/e19/lisp/makefile.el ;;; emacs version 19.23.90.1. ;;; bytecomp version FSF 2.10 ;;; optimization is on. ;;; this file uses opcodes which do not exist in Emacs 18. (if (and (boundp 'emacs-version) (or (and (boundp 'epoch::version) epoch::version) (string-lessp emacs-version "19"))) (error "`/home/fsf/rms/e19/lisp/makefile.el' was compiled for Emacs 19")) (provide (quote makefile)) (defconst makefile-mode-name "Makefile" "\ The \"pretty name\" of makefile-mode, as it appears in the modeline.") (defvar makefile-browser-buffer-name "*Macros and Targets*" "\ Name of the macro- and target browser buffer.") (defvar makefile-target-colon ":" "\ The string that gets appended to all target names inserted by makefile-insert-target. \":\" or \"::\" are quite common values.") (defvar makefile-macro-assign " = " "\ The string that gets appended to all macro names inserted by makefile-insert-macro. The normal value should be \" = \", since this is what standard make expects. However, newer makes such as dmake allow a larger variety of different macro assignments, so you might prefer to use \" += \" or \" := \" .") (defvar makefile-use-curly-braces-for-macros-p nil "\ Controls the style of generated macro references. Set this variable to a non-nil value if you prefer curly braces in macro-references, so it looks like ${this}. A value of nil will cause makefile-mode to use parentheses, making macro references look like $(this) .") (defvar makefile-tab-after-target-colon t "\ If you want a TAB (instead of a space) to be appended after the target colon, then set this to a non-nil value.") (defvar makefile-browser-leftmost-column 10 "\ Number of blanks to the left of the browser selection mark.") (defvar makefile-browser-cursor-column 10 "\ Column in which the cursor is positioned when it moves up or down in the browser.") (defvar makefile-browser-selected-mark "+ " "\ String used to mark selected entries in the browser.") (defvar makefile-browser-unselected-mark " " "\ String used to mark unselected entries in the browser.") (defvar makefile-browser-auto-advance-after-selection-p t "\ If non-nil, the cursor will automagically advance to the next line after an item has been selected in the browser.") (defvar makefile-pickup-everything-picks-up-filenames-p nil "\ If non-nil, makefile-pickup-everything also picks up filenames as targets (i.e. it calls makefile-find-filenames-as-targets), otherwise filenames are omitted.") (defvar makefile-cleanup-continuations-p t "\ If non-nil, makefile-mode will assure that no line in the file ends with a backslash (the continuation character) followed by any whitespace. This is done by silently removing the trailing whitespace, leaving the backslash itself intact. IMPORTANT: Please note that enabling this option causes makefile-mode to MODIFY A FILE WITHOUT YOUR CONFIRMATION when 'it seems necessary'.") (defvar makefile-browser-hook nil "\ A function or list of functions to be called just before the browser is entered. This is executed in the makefile buffer.") (defvar makefile-special-targets-list (quote (("DEFAULT") ("DONE") ("ERROR") ("EXPORT") ("FAILED") ("GROUPEPILOG") ("GROUPPROLOG") ("IGNORE") ("IMPORT") ("INCLUDE") ("INCLUDEDIRS") ("INIT") ("KEEP_STATE") ("MAKEFILES") ("MAKE_VERSION") ("NO_PARALLEL") ("PARALLEL") ("PHONY") ("PRECIOUS") ("REMOVE") ("SCCS_GET") ("SILENT") ("SOURCE") ("SUFFIXES") ("WAIT") ("c.o") ("C.o") ("m.o") ("el.elc") ("y.c") ("s.o"))) "\ List of special targets. You will be offered to complete on one of those in the minibuffer whenever you enter a \".\" at the beginning of a line in makefile-mode.") (defvar makefile-runtime-macros-list (quote (("@") ("&") (">") ("<") ("*") ("^") ("?") ("%"))) "\ List of macros that are resolved by make at runtime. If you insert a macro reference using makefile-insert-macro-ref, the name of the macro is checked against this list. If it can be found its name will not be enclosed in { } or ( ).") (defconst makefile-dependency-regex "^[^ #:]+\\([ ]+[^ #:]+\\)*[ ]*:\\([ ]*$\\|\\([^=\n].*$\\)\\)" "\ Regex used to find dependency lines in a makefile.") (defconst makefile-macroassign-regex "^[^ ][^:#=]*[\\*:\\+]?:?=.*$" "\ Regex used to find macro assignment lines in a makefile.") (defconst makefile-ignored-files-in-pickup-regex "\\(^\\..*\\)\\|\\(.*~$\\)\\|\\(.*,v$\\)\\|\\(\\.[chy]\\)" "\ Regex for filenames that will NOT be included in the target list.") (defvar makefile-brave-make "make" "\ A make that can handle the '-q' option.") (defvar makefile-query-one-target-method (quote makefile-query-by-make-minus-q) "\ A function symbol [one that can be used as the first argument to funcall] that provides a function that must conform to the following interface: * As its first argument, it must accept the name of the target to be checked, as a string. * As its second argument, it may accept the name of a makefile as a string. Depending on what you're going to do you may not need this. * It must return the integer value 0 (zero) if the given target should be considered up-to-date in the context of the given makefile, any nonzero integer value otherwise.") (defvar makefile-up-to-date-buffer-name "*Makefile Up-to-date overview*" "\ Name of the Up-to-date overview buffer.") (defvar makefile-mode-map nil "\ The keymap that is used in makefile-mode.") (byte-code "O Á ÂÃÄ#ÂÅÆ#ÂÇÈ#ÂÉÊ#ÂËÌ#ÂÍÎ#ÂÏÐ#ÂÑÒ#ÂÓÔ#ÂÕÖ#Âר#ÂÙÚ#Á" [makefile-mode-map make-sparse-keymap define-key "$" makefile-insert-macro-ref ":" makefile-insert-target-ref ":" makefile-electric-colon "=" makefile-electric-equal "." makefile-electric-dot "" makefile-pickup-filenames-as-targets "" makefile-switch-to-browser "" makefile-pickup-everything "" makefile-create-up-to-date-overview " " makefile-insert-gmake-function "ð" makefile-previous-dependency "î" makefile-next-dependency] 4) (defvar makefile-browser-map nil "\ The keymap that is used in the macro- and target browser.") (byte-code "I Á ÂÃÄ#ÂÅÄ#ÂÆÇ#ÂÈÇ#ÂÉÊ#ÂËÌ#ÂÍÎ#ÂÏÐ#ÂÑÒ#ÂÓÔ#ÂÕÔ#Á" [makefile-browser-map make-sparse-keymap define-key "n" makefile-browser-next-line "" "p" makefile-browser-previous-line "" " " makefile-browser-toggle "i" makefile-browser-insert-selection "I" makefile-browser-insert-selection-and-quit " " makefile-browser-insert-continuation "q" makefile-browser-quit "" undefined ""] 4) (defvar makefile-mode-syntax-table nil "\ The syntax-table used in makefile mode.") (byte-code "7 Á ÂÃÄ#ÂÅÆ#ÂÇÈ#ÂÉÊ#ÂËÌ#ÂÍÎ#ÂÏÐ#ÂÑÒ#Á" [makefile-mode-syntax-table make-syntax-table modify-syntax-entry 40 "() " 41 ")( " 91 "(] " 93 "([ " 123 "(} " 125 "){ " 35 "< " 10 "> "] 4) (defvar makefile-target-table nil "\ Table of all targets that have been inserted in this Makefile buffer using makefile-insert-target or picked up using makefile-pickup-targets.") (defvar makefile-macro-table nil "\ Table of all macros that have been iserted in this Makefile buffer using makefile-insert-macro or picked up using makefile-pickup-macros.") (byte-code "ÀÁ! ÂÀÃ! ÄÀÅ! ÄÀÆ!! ÇÀÈ!* ÇÀÉ!3 Ä Ä" [boundp makefile-browser-client "A buffer in makefile-mode that is currently using the browser." makefile-browser-selection-vector nil makefile-has-prereqs makefile-need-target-pickup t makefile-need-macro-pickup makefile-mode-hook] 2) (defconst makefile-gnumake-functions-alist (quote (("subst" "From" "To" "In") ("patsubst" "Pattern" "Replacement" "In") ("strip" "Text") ("findstring" "Find what" "In") ("filter" "Pattern" "Text") ("filter-out" "Pattern" "Text") ("sort" "List") ("dir" "Names") ("notdir" "Names") ("suffix" "Names") ("basename" "Names") ("addsuffix" "Suffix" "Names") ("join" "List 1" "List 2") ("word" "Index" "Text") ("words" "Text") ("firstword" "Text") ("wildcard" "Pattern") ("foreach" "Variable" "List" "Text") ("origin" "Variable") ("shell" "Command"))) "\ A list of GNU make function names associated with the prompts for each function. This is used in the function makefile-insert-gmake-function .") (defalias 'makefile-mode #[nil "À ÁÂ!ÃÁÄ!ÁÅ!ÁÆ!ÁÇ!ÁÈ!ÁÉ!ÁÊ!ÁË!Ì Í\nÎÏÓ!Õ!×ÙÚ!" [kill-all-local-variables make-local-variable local-write-file-hooks (makefile-cleanup-continuations makefile-warn-suspicious-lines) makefile-target-table makefile-macro-table makefile-has-prereqs makefile-need-target-pickup makefile-need-macro-pickup comment-start comment-end comment-start-skip "#" "" "#[ ]*" makefile-mode major-mode makefile-mode-name mode-name use-local-map makefile-mode-map set-syntax-table makefile-mode-syntax-table t indent-tabs-mode run-hooks makefile-mode-hook] 2 "\ Major mode for editing Makefiles. Calling this function invokes the function(s) \"makefile-mode-hook\" before doing anything else. \\{makefile-mode-map} In the browser, use the following keys: \\{makefile-browser-map} makefile-mode can be configured by modifying the following variables: makefile-mode-name: The \"pretty name\" of makefile-mode, as it appears in the modeline. makefile-browser-buffer-name: Name of the macro- and target browser buffer. makefile-target-colon: The string that gets appended to all target names inserted by makefile-insert-target. \":\" or \"::\" are quite common values. makefile-macro-assign: The string that gets appended to all macro names inserted by makefile-insert-macro. The normal value should be \" = \", since this is what standard make expects. However, newer makes such as dmake allow a larger variety of different macro assignments, so you might prefer to use \" += \" or \" := \" . makefile-tab-after-target-colon: If you want a TAB (instead of a space) to be appended after the target colon, then set this to a non-nil value. makefile-browser-leftmost-column: Number of blanks to the left of the browser selection mark. makefile-browser-cursor-column: Column in which the cursor is positioned when it moves up or down in the browser. makefile-browser-selected-mark: String used to mark selected entries in the browser. makefile-browser-unselected-mark: String used to mark unselected entries in the browser. makefile-browser-auto-advance-after-selection-p: If this variable is set to a non-nil value the cursor will automagically advance to the next line after an item has been selected in the browser. makefile-pickup-everything-picks-up-filenames-p: If this variable is set to a non-nil value then makefile-pickup-everything also picks up filenames as targets (i.e. it calls makefile-find-filenames-as-targets), otherwise filenames are omitted. makefile-cleanup-continuations-p: If this variable is set to a non-nil value then makefile-mode will assure that no line in the file ends with a backslash (the continuation character) followed by any whitespace. This is done by silently removing the trailing whitespace, leaving the backslash itself intact. IMPORTANT: Please note that enabling this option causes makefile-mode to MODIFY A FILE WITHOUT YOUR CONFIRMATION when 'it seems necessary'. makefile-browser-hook: A function or list of functions to be called just before the browser is entered. This is executed in the makefile buffer. makefile-special-targets-list: List of special targets. You will be offered to complete on one of those in the minibuffer whenever you enter a \".\" at the beginning of a line in makefile-mode." nil]) (defalias 'makefile-next-dependency #[nil "`ÁÂdÄ# ÅyÄ bÁ)" [here nil re-search-forward makefile-dependency-regex t 0] 4 "\ Move (point) to the beginning of the next dependency line below (point)." nil]) (defalias 'makefile-previous-dependency #[nil "`ÁyÂeÄ# ÁyÄ bÅ)" [here 0 re-search-backward makefile-dependency-regex t nil] 4 "\ Move (point) to the beginning of the next dependency line above (point)." nil]) (defalias 'makefile-electric-dot #[nil "n À Ác" [makefile-insert-special-target "."] 1 "\ At (bol), offer completion on makefile-special-targets-list. Anywhere else just insert a dot." nil]) (defalias 'makefile-insert-special-target #[nil "À ÁÂÄ%GÆU?
ÇÈ \"cÉ )" [makefile-pickup-targets completing-read "Special target: " makefile-special-targets-list nil special-target 0 format ".%s:" makefile-forward-after-target-colon] 7 "\ Complete on makefile-special-targets-list, insert result at (point)." nil]) (defalias 'makefile-electric-equal #[nil "À n ÁÂ!Ãc" [makefile-pickup-macros call-interactively makefile-insert-macro "="] 2 "\ At (bol) do makefile-insert-macro. Anywhere else just self-insert." nil]) (defalias 'makefile-insert-macro #[(macro-name) "À GÂU?
ÂyÃÄ #cÆÈ !" [makefile-pickup-macros macro-name 0 format "%s%s" makefile-macro-assign t makefile-need-macro-pickup makefile-remember-macro] 4 "\ Prepare definition of a new macro." "sMacro Name: "]) (defalias 'makefile-insert-macro-ref #[(macro-name) "GÁU?
Â\" ÄÅ\"cÆ!c" [macro-name 0 assoc makefile-runtime-macros-list format "$%s" makefile-format-macro-ref] 3 "\ Complete on a list of known macros, then insert complete ref at (point)." (list (progn (makefile-pickup-macros) (completing-read "Refer to macro: " makefile-macro-table nil nil nil)))]) (defalias 'makefile-insert-target #[(target-name) "GÁU?
ÁyÂÃ\f#cÅ ÆÇÉ!" [target-name 0 format "%s%s" makefile-target-colon makefile-forward-after-target-colon nil t makefile-need-target-pickup makefile-remember-target] 4 "\ Prepare definition of a new target (dependency line)." "sTarget: "]) (defalias 'makefile-insert-target-ref #[(target-name) "GÁU?