Using saved parent location: http://bzr.savannah.gnu.org/r/emacs/trunk/ Now on revision 100077. ------------------------------------------------------------ revno: 100077 committer: Chong Yidong branch nick: trunk timestamp: Wed 2010-04-28 18:27:54 -0400 message: Document complete-symbol change. diff: === modified file 'etc/NEWS' --- etc/NEWS 2010-04-24 18:10:17 +0000 +++ etc/NEWS 2010-04-28 22:27:54 +0000 @@ -107,6 +107,8 @@ * Editing Changes in Emacs 24.1 +** completion-at-point is now an alias for complete-symbol. + * Changes in Specialized Modes and Packages in Emacs 24.1 ------------------------------------------------------------ revno: 100076 committer: Chong Yidong branch nick: trunk timestamp: Wed 2010-04-28 15:04:16 -0400 message: Unify complete-symbol with completion-at-point. * bindings.el (complete-symbol): Move into minibuffer.el. * minibuffer.el (complete-tag): Move from etags.el. If tags completion cannot be performed, return nil instead of signalling an error. (completion-at-point): Make it an alias for complete-symbol. (complete-symbol): Move from bindings.el, and replace with the body of completion-at-point. * progmodes/etags.el (complete-tag): Move to minibuffer.el. * cedet/semantic.el (semantic-mode): When enabled, add semantic-ia-complete-symbol to completion-at-point-functions. * cedet/semantic/ia.el (semantic-ia-complete-symbol): Return nil if Semantic is not active. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-04-28 18:42:20 +0000 +++ lisp/ChangeLog 2010-04-28 19:04:16 +0000 @@ -1,3 +1,22 @@ +2010-04-28 Chong Yidong + + * bindings.el (complete-symbol): Move into minibuffer.el. + + * minibuffer.el (complete-tag): Move from etags.el. If tags + completion cannot be performed, return nil instead of signalling + an error. + (completion-at-point): Make it an alias for complete-symbol. + (complete-symbol): Move from bindings.el, and replace with the + body of completion-at-point. + + * progmodes/etags.el (complete-tag): Move to minibuffer.el. + + * cedet/semantic.el (semantic-mode): When enabled, add + semantic-ia-complete-symbol to completion-at-point-functions. + + * cedet/semantic/ia.el (semantic-ia-complete-symbol): Return nil + if Semantic is not active. + 2010-04-28 Michael Albinus * net/tramp.el (tramp-remote-selinux-p): New defun. === modified file 'lisp/bindings.el' --- lisp/bindings.el 2010-04-05 23:38:53 +0000 +++ lisp/bindings.el 2010-04-28 19:04:16 +0000 @@ -671,29 +671,6 @@ (define-key esc-map "\t" 'complete-symbol) -(defun complete-symbol (arg) - "Perform tags completion on the text around point. -If a tags table is loaded, call `complete-tag'. -Otherwise, if Semantic is active, call `semantic-ia-complete-symbol'. - -With a prefix argument, this command does completion within -the collection of symbols listed in the index of the manual for the -language you are using." - (interactive "P") - (cond (arg - (info-complete-symbol)) - ((or tags-table-list tags-file-name) - (complete-tag)) - ((and (fboundp 'semantic-ia-complete-symbol) - (fboundp 'semantic-active-p) - (semantic-active-p)) - (semantic-ia-complete-symbol)) - (t - (error "%s" - (substitute-command-keys - "No completions available; use \\[visit-tags-table] \ -or \\[semantic-mode]"))))) - ;; Reduce total amount of space we must allocate during this function ;; that we will not need to keep permanently. (garbage-collect) === modified file 'lisp/cedet/semantic.el' --- lisp/cedet/semantic.el 2010-02-16 14:35:45 +0000 +++ lisp/cedet/semantic.el 2010-04-28 19:04:16 +0000 @@ -1080,6 +1080,10 @@ (require 'semantic/db-ebrowse) (semanticdb-load-ebrowse-caches))) (add-hook 'mode-local-init-hook 'semantic-new-buffer-fcn) + ;; Add semantic-ia-complete-symbol to + ;; completion-at-point-functions, so that it is run from + ;; M-TAB. + (add-hook 'completion-at-point-functions 'semantic-ia-complete-symbol) (if global-ede-mode (define-key cedet-menu-map [cedet-menu-separator] '("--"))) (dolist (b (buffer-list)) @@ -1087,6 +1091,7 @@ (semantic-new-buffer-fcn)))) ;; Disable all Semantic features. (remove-hook 'mode-local-init-hook 'semantic-new-buffer-fcn) + (remove-hook 'completion-at-point-functions 'semantic-ia-complete-symbol) (define-key cedet-menu-map [cedet-menu-separator] nil) (define-key cedet-menu-map [semantic-options-separator] nil) ;; FIXME: handle semanticdb-load-ebrowse-caches === modified file 'lisp/cedet/semantic/ia.el' --- lisp/cedet/semantic/ia.el 2010-01-13 08:35:10 +0000 +++ lisp/cedet/semantic/ia.el 2010-04-28 19:04:16 +0000 @@ -110,56 +110,52 @@ If POS is nil, default to point. Completion options are calculated with `semantic-analyze-possible-completions'." (interactive "d") - (or pos (setq pos (point))) - ;; Calculating completions is a two step process. - ;; - ;; The first analyzer the current context, which finds tags - ;; for all the stuff that may be references by the code around - ;; POS. - ;; - ;; The second step derives completions from that context. - (let* ((a (semantic-analyze-current-context pos)) - (syms (semantic-ia-get-completions a pos)) - (pre (car (reverse (oref a prefix)))) - ) - ;; If PRE was actually an already completed symbol, it doesn't - ;; come in as a string, but as a tag instead. - (if (semantic-tag-p pre) - ;; We will try completions on it anyway. - (setq pre (semantic-tag-name pre))) - ;; Complete this symbol. - (if (null syms) - (progn - ;(message "No smart completions found. Trying senator-complete-symbol.") + (when (semantic-active-p) + (or pos (setq pos (point))) + ;; Calculating completions is a two step process. + ;; + ;; The first analyzer the current context, which finds tags for + ;; all the stuff that may be references by the code around POS. + ;; + ;; The second step derives completions from that context. + (let* ((a (semantic-analyze-current-context pos)) + (syms (semantic-ia-get-completions a pos)) + (pre (car (reverse (oref a prefix))))) + ;; If PRE was actually an already completed symbol, it doesn't + ;; come in as a string, but as a tag instead. + (if (semantic-tag-p pre) + ;; We will try completions on it anyway. + (setq pre (semantic-tag-name pre))) + ;; Complete this symbol. + (if (null syms) (if (semantic-analyze-context-p a) ;; This is a clever hack. If we were unable to find any ;; smart completions, lets divert to how senator derives ;; completions. ;; - ;; This is a way of making this fcn more useful since the - ;; smart completion engine sometimes failes. - (semantic-complete-symbol))) - ;; Use try completion to seek a common substring. - (let ((tc (try-completion (or pre "") syms))) - (if (and (stringp tc) (not (string= tc (or pre "")))) - (let ((tok (semantic-find-first-tag-by-name - tc syms))) - ;; Delete what came before... - (when (and (car (oref a bounds)) (cdr (oref a bounds))) - (delete-region (car (oref a bounds)) - (cdr (oref a bounds))) - (goto-char (car (oref a bounds)))) - ;; We have some new text. Stick it in. - (if tok - (semantic-ia-insert-tag tok) - (insert tc))) - ;; We don't have new text. Show all completions. - (when (cdr (oref a bounds)) - (goto-char (cdr (oref a bounds)))) - (with-output-to-temp-buffer "*Completions*" - (display-completion-list - (mapcar semantic-ia-completion-format-tag-function syms)) - )))))) + ;; This is a way of making this fcn more useful since + ;; the smart completion engine sometimes failes. + (semantic-complete-symbol)) + ;; Use try completion to seek a common substring. + (let ((tc (try-completion (or pre "") syms))) + (if (and (stringp tc) (not (string= tc (or pre "")))) + (let ((tok (semantic-find-first-tag-by-name + tc syms))) + ;; Delete what came before... + (when (and (car (oref a bounds)) (cdr (oref a bounds))) + (delete-region (car (oref a bounds)) + (cdr (oref a bounds))) + (goto-char (car (oref a bounds)))) + ;; We have some new text. Stick it in. + (if tok + (semantic-ia-insert-tag tok) + (insert tc))) + ;; We don't have new text. Show all completions. + (when (cdr (oref a bounds)) + (goto-char (cdr (oref a bounds)))) + (with-output-to-temp-buffer "*Completions*" + (display-completion-list + (mapcar semantic-ia-completion-format-tag-function syms))))))))) (defcustom semantic-ia-completion-menu-format-tag-function 'semantic-uml-concise-prototype-nonterminal === modified file 'lisp/minibuffer.el' --- lisp/minibuffer.el 2010-04-19 18:33:11 +0000 +++ lisp/minibuffer.el 2010-04-28 19:04:16 +0000 @@ -1157,7 +1157,7 @@ (call-interactively 'minibuffer-complete) (delete-overlay ol))))) -(defvar completion-at-point-functions nil +(defvar completion-at-point-functions '(complete-tag) "Special hook to find the completion table for the thing at point. It is called without any argument and should return either nil, or a function of no argument to perform completion (discouraged), @@ -1169,22 +1169,56 @@ `:predicate' a predicate that completion candidates need to satisfy. `:annotation-function' the value to use for `completion-annotate-function'.") -(defun completion-at-point () - "Complete the thing at point according to local mode." +(declare-function tags-lazy-completion-table "etags.el" ()) + +(defun complete-tag () + "Perform tags completion on the text around point. +If no tags table is loaded, do nothing and return nil. +Otherwise, complete to the set of names listed in the tags table. +The string to complete is chosen in the same way as the default +for `find-tag'." (interactive) - (let ((res (run-hook-with-args-until-success - 'completion-at-point-functions))) - (cond - ((functionp res) (funcall res)) - (res - (let* ((plist (nthcdr 3 res)) - (start (nth 0 res)) - (end (nth 1 res)) - (completion-annotate-function - (or (plist-get plist :annotation-function) - completion-annotate-function))) - (completion-in-region start end (nth 2 res) - (plist-get plist :predicate))))))) + (when (or tags-table-list tags-file-name) + (require 'etags) + (let ((completion-ignore-case (if (memq tags-case-fold-search '(t nil)) + tags-case-fold-search + case-fold-search)) + (pattern (funcall (or find-tag-default-function + (get major-mode 'find-tag-default-function) + 'find-tag-default))) + (comp-table (tags-lazy-completion-table)) + beg) + (when pattern + (search-backward pattern) + (setq beg (point)) + (forward-char (length pattern)) + (completion-in-region beg (point) comp-table))))) + +(defun complete-symbol (&optional arg) + "Perform completion on the text around point. +The completion method is determined by `completion-at-point-functions'. + +With a prefix argument, this command does completion within +the collection of symbols listed in the index of the manual for the +language you are using." + (interactive "P") + (if arg + (info-complete-symbol) + (let ((res (run-hook-with-args-until-success + 'completion-at-point-functions))) + (cond + ((functionp res) (funcall res)) + (res + (let* ((plist (nthcdr 3 res)) + (start (nth 0 res)) + (end (nth 1 res)) + (completion-annotate-function + (or (plist-get plist :annotation-function) + completion-annotate-function))) + (completion-in-region start end (nth 2 res) + (plist-get plist :predicate)))))))) + +(defalias 'completion-at-point 'complete-symbol) ;;; Key bindings. @@ -1361,7 +1395,9 @@ (substitute-in-file-name string) (error string))) (comp (completion-file-name-table - str (or pred read-file-name-predicate) action))) + str + (with-no-warnings (or pred read-file-name-predicate)) + action))) (cond ((stringp comp) === modified file 'lisp/progmodes/etags.el' --- lisp/progmodes/etags.el 2010-01-13 08:35:10 +0000 +++ lisp/progmodes/etags.el 2010-04-28 19:04:16 +0000 @@ -2027,33 +2027,6 @@ (interactive) (quit-window t (selected-window))) -;;;###autoload -(defun complete-tag () - "Perform tags completion on the text around point. -Completes to the set of names listed in the current tags table. -The string to complete is chosen in the same way as the default -for \\[find-tag] (which see)." - (interactive) - (or tags-table-list - tags-file-name - (error "%s" - (substitute-command-keys - "No tags table loaded; try \\[visit-tags-table]"))) - (let ((completion-ignore-case (if (memq tags-case-fold-search '(t nil)) - tags-case-fold-search - case-fold-search)) - (pattern (funcall (or find-tag-default-function - (get major-mode 'find-tag-default-function) - 'find-tag-default))) - (comp-table (tags-lazy-completion-table)) - beg) - (or pattern - (error "Nothing to complete")) - (search-backward pattern) - (setq beg (point)) - (forward-char (length pattern)) - (completion-in-region beg (point) comp-table))) - (dolist (x '("^No tags table in use; use .* to select one$" "^There is no default tag$" "^No previous tag locations$" ------------------------------------------------------------ revno: 100075 committer: Michael Albinus branch nick: trunk timestamp: Wed 2010-04-28 20:42:20 +0200 message: * net/tramp.el (tramp-remote-selinux-p): New defun. (tramp-handle-file-selinux-context) (tramp-handle-set-file-selinux-context): Use it. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-04-28 16:14:41 +0000 +++ lisp/ChangeLog 2010-04-28 18:42:20 +0000 @@ -1,3 +1,9 @@ +2010-04-28 Michael Albinus + + * net/tramp.el (tramp-remote-selinux-p): New defun. + (tramp-handle-file-selinux-context) + (tramp-handle-set-file-selinux-context): Use it. + 2010-04-28 Sam Steingold * progmodes/bug-reference.el (bug-reference-url-format): Mark as === modified file 'lisp/net/tramp.el' --- lisp/net/tramp.el 2010-04-23 14:12:05 +0000 +++ lisp/net/tramp.el 2010-04-28 18:42:20 +0000 @@ -3030,6 +3030,17 @@ "chown" nil nil nil (format "%d:%d" uid gid) (tramp-shell-quote-argument filename)))))) +(defun tramp-remote-selinux-p (vec) + "Check, whether SELINUX is enabled on the remote host." + (with-connection-property (tramp-get-connection-process vec) "selinux-p" + (let ((result (tramp-find-executable + vec "getenforce" (tramp-get-remote-path vec) t t))) + (and result + (string-equal + (tramp-send-command-and-read + vec (format "echo \\\"`%S`\\\"" result)) + "Enforcing"))))) + (defun tramp-handle-file-selinux-context (filename) "Like `file-selinux-context' for Tramp files." (with-parsed-tramp-file-name filename nil @@ -3037,11 +3048,12 @@ (let ((context '(nil nil nil nil)) (regexp (concat "\\([a-z0-9_]+\\):" "\\([a-z0-9_]+\\):" "\\([a-z0-9_]+\\):" "\\([a-z0-9_]+\\)"))) - (when (zerop (tramp-send-command-and-check - v (format - "%s -d -Z %s" - (tramp-get-ls-command v) - (tramp-shell-quote-argument localname)))) + (when (and (tramp-remote-selinux-p v) + (zerop (tramp-send-command-and-check + v (format + "%s -d -Z %s" + (tramp-get-ls-command v) + (tramp-shell-quote-argument localname))))) (with-current-buffer (tramp-get-connection-buffer v) (goto-char (point-min)) (when (re-search-forward regexp (tramp-compat-line-end-position) t) @@ -3054,6 +3066,7 @@ "Like `set-file-selinux-context' for Tramp files." (with-parsed-tramp-file-name filename nil (if (and (consp context) + (tramp-remote-selinux-p v) (zerop (tramp-send-command-and-check v (format "chcon %s %s %s %s %s" (if (stringp (nth 0 context)) @@ -6924,7 +6937,7 @@ (tramp-send-command-and-read vec "echo \\\"`uname -sr`\\\"")))) (when (and (stringp old-uname) (not (string-equal old-uname new-uname))) (with-current-buffer (tramp-get-debug-buffer vec) - ;; Keep the debug buffer + ;; Keep the debug buffer. (rename-buffer (generate-new-buffer-name tramp-temp-buffer-name) 'unique) (funcall (symbol-function 'tramp-cleanup-connection) vec) @@ -8752,7 +8765,6 @@ ;; on remote hosts. ;; * Use secrets.el for password handling. ;; * Load ~/.emacs_SHELLNAME on the remote host for `shell'. -;; * Implement selinux-context. ;; Functions for file-name-handler-alist: ;; diff-latest-backup-file -- in diff.el ------------------------------------------------------------ revno: 100074 committer: Sam Steingold branch nick: trunk timestamp: Wed 2010-04-28 12:14:41 -0400 message: (bug-reference-url-format): Mark as `safe-local-variable' if the value is a string or a symbol with the property `bug-reference-url-format'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-04-28 15:45:45 +0000 +++ lisp/ChangeLog 2010-04-28 16:14:41 +0000 @@ -1,3 +1,9 @@ +2010-04-28 Sam Steingold + + * progmodes/bug-reference.el (bug-reference-url-format): Mark as + `safe-local-variable' if the value is a string or a symbol with + the property `bug-reference-url-format'. + 2010-04-28 Chong Yidong * progmodes/bug-reference.el (bug-reference-url-format): Revert === modified file 'lisp/progmodes/bug-reference.el' --- lisp/progmodes/bug-reference.el 2010-04-28 15:45:45 +0000 +++ lisp/progmodes/bug-reference.el 2010-04-28 16:14:41 +0000 @@ -48,10 +48,18 @@ 1. issue kind (bug, patch, rfe &c) 2. issue number. -There is no default setting for this, it must be set per file.") +There is no default setting for this, it must be set per file. +If you set it to a symbol in the file Local Variables section, +you need to add a `bug-reference-url-format' property to it: +\(put 'my-bug-reference-url-format 'bug-reference-url-format t) +so that it is considered safe, see `enable-local-variables'.") ;;;###autoload -(put 'bug-reference-url-format 'safe-local-variable 'stringp) +(put 'bug-reference-url-format 'safe-local-variable + (lambda (s) + (or (stringp s) + (and (symbolp s) + (get s 'bug-reference-url-format))))) (defconst bug-reference-bug-regexp "\\([Bb]ug ?#\\|[Pp]atch ?#\\|RFE ?#\\|PR [a-z-+]+/\\)\\([0-9]+\\)" ------------------------------------------------------------ revno: 100073 committer: Glenn Morris branch nick: trunk timestamp: Wed 2010-04-28 08:58:29 -0700 message: * configure.in (LIBXMU): Fix logic in previous change. diff: === modified file 'configure.in' --- configure.in 2010-04-28 07:20:39 +0000 +++ configure.in 2010-04-28 15:58:29 +0000 @@ -1896,7 +1896,7 @@ case "$machine" in ## These machines don't supply Xmu. hpux* | aix4-2 ) - test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" = "Xno" && LIBXMU= + test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU= ;; esac AC_SUBST(LIBXMU) ------------------------------------------------------------ revno: 100072 committer: Chong Yidong branch nick: trunk timestamp: Wed 2010-04-28 11:45:45 -0400 message: Revert last bug-reference-url-format change. * progmodes/bug-reference.el (bug-reference-url-format): Revert 2010-04-27 change due to security risk. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-04-28 15:18:37 +0000 +++ lisp/ChangeLog 2010-04-28 15:45:45 +0000 @@ -1,3 +1,8 @@ +2010-04-28 Chong Yidong + + * progmodes/bug-reference.el (bug-reference-url-format): Revert + 2010-04-27 change due to security risk. + 2010-04-28 Stefan Monnier Make it possible to locally disable a globally enabled mode. === modified file 'lisp/progmodes/bug-reference.el' --- lisp/progmodes/bug-reference.el 2010-04-27 15:13:42 +0000 +++ lisp/progmodes/bug-reference.el 2010-04-28 15:45:45 +0000 @@ -51,8 +51,7 @@ There is no default setting for this, it must be set per file.") ;;;###autoload -(put 'bug-reference-url-format 'safe-local-variable - (lambda (s) (or (stringp s) (functionp s)))) +(put 'bug-reference-url-format 'safe-local-variable 'stringp) (defconst bug-reference-bug-regexp "\\([Bb]ug ?#\\|[Pp]atch ?#\\|RFE ?#\\|PR [a-z-+]+/\\)\\([0-9]+\\)" ------------------------------------------------------------ revno: 100071 committer: Stefan Monnier branch nick: trunk timestamp: Wed 2010-04-28 11:18:37 -0400 message: Make it possible to locally disable a globally enabled mode. * simple.el (fundamental-mode): Run fundamental-mode-hook. * emacs-lisp/derived.el (define-derived-mode): Use fundamental-mode rather than kill-all-local-variables so it runs fundamental-mode-hook. * emacs-lisp/easy-mmode.el (define-globalized-minor-mode): Use fundamental-mode-hook to run MODE-enable-in-buffers earlier, so that subsequent hooks get a chance to disable it. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-04-27 18:14:16 +0000 +++ lisp/ChangeLog 2010-04-28 15:18:37 +0000 @@ -1,3 +1,13 @@ +2010-04-28 Stefan Monnier + + Make it possible to locally disable a globally enabled mode. + * simple.el (fundamental-mode): Run fundamental-mode-hook. + * emacs-lisp/derived.el (define-derived-mode): Use fundamental-mode + rather than kill-all-local-variables so it runs fundamental-mode-hook. + * emacs-lisp/easy-mmode.el (define-globalized-minor-mode): + Use fundamental-mode-hook to run MODE-enable-in-buffers earlier, so + that subsequent hooks get a chance to disable it. + 2010-04-27 Stefan Monnier * emacs-lisp/easy-mmode.el (define-globalized-minor-mode): === modified file 'lisp/emacs-lisp/derived.el' --- lisp/emacs-lisp/derived.el 2010-01-13 08:35:10 +0000 +++ lisp/emacs-lisp/derived.el 2010-04-28 15:18:37 +0000 @@ -230,7 +230,7 @@ ; Run the parent. (delay-mode-hooks - (,(or parent 'kill-all-local-variables)) + (,(or parent 'fundamental-mode)) ; Identify the child mode. (setq major-mode (quote ,child)) (setq mode-name ,name) === modified file 'lisp/emacs-lisp/easy-mmode.el' --- lisp/emacs-lisp/easy-mmode.el 2010-04-27 18:14:16 +0000 +++ lisp/emacs-lisp/easy-mmode.el 2010-04-28 15:18:37 +0000 @@ -338,9 +338,11 @@ (progn (add-hook 'after-change-major-mode-hook ',MODE-enable-in-buffers) + (add-hook 'fundamental-mode-hook ',MODE-enable-in-buffers) (add-hook 'find-file-hook ',MODE-check-buffers) (add-hook 'change-major-mode-hook ',MODE-cmhh)) (remove-hook 'after-change-major-mode-hook ',MODE-enable-in-buffers) + (remove-hook 'fundamental-mode-hook ',MODE-enable-in-buffers) (remove-hook 'find-file-hook ',MODE-check-buffers) (remove-hook 'change-major-mode-hook ',MODE-cmhh)) === modified file 'lisp/simple.el' --- lisp/simple.el 2010-04-16 01:41:58 +0000 +++ lisp/simple.el 2010-04-28 15:18:37 +0000 @@ -401,8 +401,7 @@ Other major modes are defined by comparison with this one." (interactive) (kill-all-local-variables) - (unless delay-mode-hooks - (run-hooks 'after-change-major-mode-hook))) + (run-mode-hooks 'fundamental-mode-hook)) ;; Special major modes to view specially formatted data rather than files. ------------------------------------------------------------ revno: 100070 committer: Glenn Morris branch nick: trunk timestamp: Wed 2010-04-28 00:33:48 -0700 message: Regenerate configure. diff: === modified file 'configure' --- configure 2010-04-27 08:11:11 +0000 +++ configure 2010-04-28 07:33:48 +0000 @@ -711,6 +711,8 @@ CFLAGS_SOUND SET_MAKE XMKMF +NS_OBJ +NS_SUPPORT HAVE_XSERVER RSVG_CFLAGS RSVG_LIBS @@ -724,6 +726,7 @@ GCONF_LIBS LIBSELINUX_LIBS LIBXTR6 +LIBXMU FONTCONFIG_CFLAGS FONTCONFIG_LIBS XFT_CFLAGS @@ -732,6 +735,7 @@ LIBOTF_LIBS M17N_FLT_CFLAGS M17N_FLT_LIBS +FONT_OBJ FREETYPE_CFLAGS FREETYPE_LIBS LIBXPM @@ -740,6 +744,7 @@ LIBTIFF LIBGIF LIBGPM +GPM_MOUSE_SUPPORT LIBXSM ALLOCA liblockfile @@ -794,6 +799,7 @@ XOBJ WIDGET_OBJ TOOLKIT_LIBW +CYGWIN_OBJ LTLIBOBJS' ac_subst_files='' ac_user_opts=' @@ -5448,6 +5454,73 @@ fi fi + +## Although we're running on an amd64 kernel, we're actually compiling for +## the x86 architecture. The user should probably have provided an +## explicit --build to `configure', but if everything else than the kernel +## is running in i386 mode, we can help them out. +if test "$machine" = "amdx86-64"; then + { $as_echo "$as_me:$LINENO: checking whether i386 is declared" >&5 +$as_echo_n "checking whether i386 is declared... " >&6; } +if test "${ac_cv_have_decl_i386+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +#ifndef i386 + (void) i386; +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_have_decl_i386=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_have_decl_i386=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_i386" >&5 +$as_echo "$ac_cv_have_decl_i386" >&6; } + + if test "$ac_cv_have_decl_i386" = "yes"; then + canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'` + machine=intel386 + machfile="m/${machine}.h" + fi +fi + # Extract the first word of "install-info", so it can be a program name with args. set dummy install-info; ac_word=$2 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 @@ -9922,6 +9995,9 @@ NS_HAVE_NSINTEGER=no fi fi + +NS_OBJ= +NS_SUPPORT= if test "${HAVE_NS}" = yes; then window_system=nextstep with_xft=no @@ -9931,10 +10007,14 @@ if test "${EN_NS_SELF_CONTAINED}" = yes; then prefix=${ns_appresdir} fi + NS_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o fontset.o fringe.o image.o" + NS_SUPPORT="\${lispsource}emacs-lisp/easymenu.elc \${lispsource}term/ns-win.elc" fi CFLAGS="$tmp_CFLAGS" CPPFLAGS="$tmp_CPPFLAGS" + + case "${window_system}" in x11 ) HAVE_X_WINDOWS=yes @@ -13176,6 +13256,15 @@ fi +LIBXMU=-lXmu +case "$machine" in + ## These machines don't supply Xmu. + hpux* | aix4-2 ) + test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" = "Xno" && LIBXMU= + ;; +esac + + # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D. if test "${HAVE_X11}" = "yes"; then if test "${USE_X_TOOLKIT}" != "none"; then @@ -14442,6 +14531,15 @@ HAVE_LIBOTF=no HAVE_M17N_FLT=no fi + +FONT_OBJ=xfont.o +if test "$HAVE_XFT" = "yes"; then + FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o" +elif test "$HAVE_FREETYPE" = "yes"; then + FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o" +fi + + ### End of font-backend (under X11) section. @@ -15735,6 +15833,7 @@ ### Use -lgpm if available, unless `--with-gpm=no'. HAVE_GPM=no LIBGPM= +GPM_MOUSE_SUPPORT= if test "${with_gpm}" != "no"; then if test "${ac_cv_header_gpm_h+set}" = set; then { $as_echo "$as_me:$LINENO: checking for gpm.h" >&5 @@ -15944,10 +16043,12 @@ _ACEOF LIBGPM=-lgpm + GPM_MOUSE_SUPPORT="\${lispsource}mouse.elc" fi fi + if test "${ac_cv_header_malloc_malloc_h+set}" = set; then { $as_echo "$as_me:$LINENO: checking for malloc/malloc.h" >&5 $as_echo_n "checking for malloc/malloc.h... " >&6; } @@ -26038,6 +26139,9 @@ fi +CYGWIN_OBJ= +test "$opsys" = "cygwin" && CYGWIN_OBJ="sheap.o" + ------------------------------------------------------------ revno: 100069 committer: Glenn Morris branch nick: trunk timestamp: Wed 2010-04-28 00:25:47 -0700 message: src/Makefile.in minor simplification, * src/Makefile.in (BASE_WINDOW_SUPPORT, X_WINDOW_SUPPORT): New variables. (WINDOW_SUPPORT) [HAVE_WINDOW_SYSTEM]: Use them. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2010-04-28 07:20:39 +0000 +++ src/ChangeLog 2010-04-28 07:25:47 +0000 @@ -1,5 +1,8 @@ 2010-04-28 Glenn Morris + * Makefile.in (BASE_WINDOW_SUPPORT, X_WINDOW_SUPPORT): New variables. + (WINDOW_SUPPORT) [HAVE_WINDOW_SYSTEM]: Use them. + * Makefile.in (CYGWIN_OBJ): Set with configure, not cpp. * Makefile.in (GPM_MOUSE_SUPPORT): New, set by configure. === modified file 'src/Makefile.in' --- src/Makefile.in 2010-04-28 07:20:39 +0000 +++ src/Makefile.in 2010-04-28 07:25:47 +0000 @@ -119,6 +119,13 @@ ## Not used if HAVE_MOUSE. GPM_MOUSE_SUPPORT=@GPM_MOUSE_SUPPORT@ +BASE_WINDOW_SUPPORT=${lispsource}fringe.elc ${lispsource}image.elc \ + ${lispsource}international/fontset.elc ${lispsource}dnd.elc \ + ${lispsource}tool-bar.elc ${lispsource}mwheel.elc + +X_WINDOW_SUPPORT=${lispsource}x-dnd.elc ${lispsource}term/common-win.elc \ + ${lispsource}term/x-win.elc ${lispsource}dynamic-setting.elc + LIBSELINUX_LIBS = @LIBSELINUX_LIBS@ INTERVALS_H = dispextern.h intervals.h composite.h @@ -469,15 +476,9 @@ #ifdef HAVE_WINDOW_SYSTEM #ifdef HAVE_X_WINDOWS -#define WINDOW_SUPPORT ${lispsource}fringe.elc ${lispsource}image.elc \ - ${lispsource}international/fontset.elc ${lispsource}dnd.elc \ - ${lispsource}tool-bar.elc ${lispsource}mwheel.elc ${lispsource}x-dnd.elc \ - ${lispsource}term/common-win.elc ${lispsource}term/x-win.elc \ - ${lispsource}dynamic-setting.elc +#define WINDOW_SUPPORT $(BASE_WINDOW_SUPPORT) $(X_WINDOW_SUPPORT) #else -#define WINDOW_SUPPORT ${lispsource}fringe.elc ${lispsource}image.elc \ - ${lispsource}international/fontset.elc ${lispsource}dnd.elc \ - ${lispsource}tool-bar.elc ${lispsource}mwheel.elc +#define WINDOW_SUPPORT $(BASE_WINDOW_SUPPORT) #endif #else #define WINDOW_SUPPORT ------------------------------------------------------------ revno: 100068 committer: Glenn Morris branch nick: trunk timestamp: Wed 2010-04-28 00:20:39 -0700 message: Define CYGWIN_OBJ with configure, not cpp. * configure.in (CYGWIN_OBJ): New output variable. * src/Makefile.in (CYGWIN_OBJ): Set with configure, not cpp. diff: === modified file 'ChangeLog' --- ChangeLog 2010-04-28 07:15:10 +0000 +++ ChangeLog 2010-04-28 07:20:39 +0000 @@ -1,5 +1,7 @@ 2010-04-28 Glenn Morris + * configure.in (CYGWIN_OBJ): New output variable. + * configure.in (GPM_MOUSE_SUPPORT): New output variable. * configure.in (FONT_OBJ): New output variable. === modified file 'configure.in' --- configure.in 2010-04-28 07:15:10 +0000 +++ configure.in 2010-04-28 07:20:39 +0000 @@ -2928,6 +2928,9 @@ buffer space.]) fi +CYGWIN_OBJ= +test "$opsys" = "cygwin" && CYGWIN_OBJ="sheap.o" +AC_SUBST(CYGWIN_OBJ) AH_TOP([/* GNU Emacs site configuration template file. Copyright (C) 1988, 1993, 1994, 1999, 2000, 2001, 2002, 2004, 2005, === modified file 'src/ChangeLog' --- src/ChangeLog 2010-04-28 07:15:10 +0000 +++ src/ChangeLog 2010-04-28 07:20:39 +0000 @@ -1,5 +1,7 @@ 2010-04-28 Glenn Morris + * Makefile.in (CYGWIN_OBJ): Set with configure, not cpp. + * Makefile.in (GPM_MOUSE_SUPPORT): New, set by configure. (MOUSE_SUPPORT) [!HAVE_MOUSE]: Use $GPM_MOUSE_SUPPORT. === modified file 'src/Makefile.in' --- src/Makefile.in 2010-04-28 07:15:10 +0000 +++ src/Makefile.in 2010-04-28 07:20:39 +0000 @@ -106,6 +106,9 @@ ## widget.o if USE_X_TOOLKIT, otherwise empty. WIDGET_OBJ=@WIDGET_OBJ@ +## sheap.o if CYGWIN, otherwise empty. +CYGWIN_OBJ=@CYGWIN_OBJ@ + NS_OBJ=@NS_OBJ@ NS_SUPPORT=@NS_SUPPORT@ @@ -368,10 +371,6 @@ #endif #endif -#ifdef CYGWIN -CYGWIN_OBJ = sheap.o -#endif - #ifdef HAVE_NS ns_appdir=@ns_appdir@/ ns_appbindir=@ns_appbindir@/ ------------------------------------------------------------ revno: 100067 committer: Glenn Morris branch nick: trunk timestamp: Wed 2010-04-28 00:15:10 -0700 message: Set GPM part of MOUSE_SUPPORT with configure, not cpp. * configure.in (GPM_MOUSE_SUPPORT): New output variable. * src/Makefile.in (GPM_MOUSE_SUPPORT): New, set by configure. (MOUSE_SUPPORT) [!HAVE_MOUSE]: Use $GPM_MOUSE_SUPPORT. diff: === modified file 'ChangeLog' --- ChangeLog 2010-04-28 07:08:53 +0000 +++ ChangeLog 2010-04-28 07:15:10 +0000 @@ -1,5 +1,7 @@ 2010-04-28 Glenn Morris + * configure.in (GPM_MOUSE_SUPPORT): New output variable. + * configure.in (FONT_OBJ): New output variable. * configure.in (LIBXMU): New output variable. === modified file 'configure.in' --- configure.in 2010-04-28 07:08:53 +0000 +++ configure.in 2010-04-28 07:15:10 +0000 @@ -2291,6 +2291,7 @@ ### Use -lgpm if available, unless `--with-gpm=no'. HAVE_GPM=no LIBGPM= +GPM_MOUSE_SUPPORT= if test "${with_gpm}" != "no"; then AC_CHECK_HEADER(gpm.h, [AC_CHECK_LIB(gpm, Gpm_Open, HAVE_GPM=yes)]) @@ -2298,9 +2299,11 @@ if test "${HAVE_GPM}" = "yes"; then AC_DEFINE(HAVE_GPM, 1, [Define to 1 if you have the gpm library (-lgpm).]) LIBGPM=-lgpm + GPM_MOUSE_SUPPORT="\${lispsource}mouse.elc" fi fi AC_SUBST(LIBGPM) +AC_SUBST(GPM_MOUSE_SUPPORT) dnl Check for malloc/malloc.h on darwin AC_CHECK_HEADER(malloc/malloc.h, [AC_DEFINE(HAVE_MALLOC_MALLOC_H, 1, [Define to 1 if you have the header file.])]) === modified file 'src/ChangeLog' --- src/ChangeLog 2010-04-28 07:08:53 +0000 +++ src/ChangeLog 2010-04-28 07:15:10 +0000 @@ -1,5 +1,8 @@ 2010-04-28 Glenn Morris + * Makefile.in (GPM_MOUSE_SUPPORT): New, set by configure. + (MOUSE_SUPPORT) [!HAVE_MOUSE]: Use $GPM_MOUSE_SUPPORT. + * Makefile.in (FONT_OBJ): New, set by configure. (FONT_DRIVERS): Use $FONT_OBJ. === modified file 'src/Makefile.in' --- src/Makefile.in 2010-04-28 07:08:53 +0000 +++ src/Makefile.in 2010-04-28 07:15:10 +0000 @@ -112,6 +112,10 @@ ## Only used if HAVE_X_WINDOWS and HAVE_WINDOW_SYSTEM. FONT_OBJ=@FONT_OBJ@ +## ${lispsource}mouse.elc if HAVE_GPM, otherwise empty. +## Not used if HAVE_MOUSE. +GPM_MOUSE_SUPPORT=@GPM_MOUSE_SUPPORT@ + LIBSELINUX_LIBS = @LIBSELINUX_LIBS@ INTERVALS_H = dispextern.h intervals.h composite.h @@ -452,11 +456,7 @@ #define MOUSE_SUPPORT ${lispsource}mouse.elc \ ${lispsource}select.elc ${lispsource}scroll-bar.elc #else -#ifdef HAVE_GPM -#define MOUSE_SUPPORT ${lispsource}mouse.elc -#else -#define MOUSE_SUPPORT -#endif +#define MOUSE_SUPPORT $(GPM_MOUSE_SUPPORT) #endif #ifdef MSDOS ------------------------------------------------------------ revno: 100066 committer: Glenn Morris branch nick: trunk timestamp: Wed 2010-04-28 00:08:53 -0700 message: Set FONT_DRIVERS with configure rather than cpp. * configure.in (FONT_OBJ): New output variable. * src/Makefile.in (FONT_OBJ): New, set by configure. (FONT_DRIVERS): Use $FONT_OBJ. diff: === modified file 'ChangeLog' --- ChangeLog 2010-04-28 07:01:43 +0000 +++ ChangeLog 2010-04-28 07:08:53 +0000 @@ -1,5 +1,7 @@ 2010-04-28 Glenn Morris + * configure.in (FONT_OBJ): New output variable. + * configure.in (LIBXMU): New output variable. * configure.in (NS_OBJ, NS_SUPPORT): New output variables. === modified file 'configure.in' --- configure.in 2010-04-28 07:01:43 +0000 +++ configure.in 2010-04-28 07:08:53 +0000 @@ -2121,6 +2121,15 @@ HAVE_LIBOTF=no HAVE_M17N_FLT=no fi + +FONT_OBJ=xfont.o +if test "$HAVE_XFT" = "yes"; then + FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o" +elif test "$HAVE_FREETYPE" = "yes"; then + FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o" +fi +AC_SUBST(FONT_OBJ) + ### End of font-backend (under X11) section. AC_SUBST(FREETYPE_CFLAGS) === modified file 'src/ChangeLog' --- src/ChangeLog 2010-04-28 07:01:43 +0000 +++ src/ChangeLog 2010-04-28 07:08:53 +0000 @@ -1,5 +1,8 @@ 2010-04-28 Glenn Morris + * Makefile.in (FONT_OBJ): New, set by configure. + (FONT_DRIVERS): Use $FONT_OBJ. + * Makefile.in (LIBXMU): Set with configure, not cpp. * s/aix4-2.h (LIBXMU): * s/hpux10-20.h (LIBXMU): === modified file 'src/Makefile.in' --- src/Makefile.in 2010-04-28 07:01:43 +0000 +++ src/Makefile.in 2010-04-28 07:08:53 +0000 @@ -109,6 +109,9 @@ NS_OBJ=@NS_OBJ@ NS_SUPPORT=@NS_SUPPORT@ +## Only used if HAVE_X_WINDOWS and HAVE_WINDOW_SYSTEM. +FONT_OBJ=@FONT_OBJ@ + LIBSELINUX_LIBS = @LIBSELINUX_LIBS@ INTERVALS_H = dispextern.h intervals.h composite.h @@ -374,13 +377,7 @@ #ifdef HAVE_WINDOW_SYSTEM #ifdef HAVE_X_WINDOWS -#if defined (HAVE_XFT) -FONT_DRIVERS = xfont.o ftfont.o xftfont.o ftxfont.o -#elif defined (HAVE_FREETYPE) -FONT_DRIVERS = xfont.o ftfont.o ftxfont.o -#else /* ! defined (HAVE_XFT) && ! defined (HAVE_FREETYPE) */ -FONT_DRIVERS = xfont.o -#endif /* ! defined (HAVE_XFT) && ! defined (HAVE_FREETYPE) */ +FONT_DRIVERS=$(FONT_OBJ) #endif /* HAVE_X_WINDOWS */ #endif /* HAVE_WINDOW_SYSTEM */ ------------------------------------------------------------ revno: 100065 committer: Glenn Morris branch nick: trunk timestamp: Wed 2010-04-28 00:01:43 -0700 message: Move LIBXMU from cpp to configure. * configure.in (LIBXMU): New output variable. * src/Makefile.in (LIBXMU): Set with configure, not cpp. * src/s/aix4-2.h (LIBXMU): * src/s/hpux10-20.h (LIBXMU): Remove definition, now set in configure. diff: === modified file 'ChangeLog' --- ChangeLog 2010-04-28 06:54:25 +0000 +++ ChangeLog 2010-04-28 07:01:43 +0000 @@ -1,5 +1,7 @@ 2010-04-28 Glenn Morris + * configure.in (LIBXMU): New output variable. + * configure.in (NS_OBJ, NS_SUPPORT): New output variables. * configure.in (machine, canonical): On amdx86-64, check for a 32-bit === modified file 'configure.in' --- configure.in 2010-04-28 06:54:25 +0000 +++ configure.in 2010-04-28 07:01:43 +0000 @@ -1890,6 +1890,17 @@ fi AC_SUBST(LIBXTR6) +dnl FIXME the logic here seems weird, but this is what cpp was doing. +dnl Why not just test for libxmu in the normal way? +LIBXMU=-lXmu +case "$machine" in + ## These machines don't supply Xmu. + hpux* | aix4-2 ) + test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" = "Xno" && LIBXMU= + ;; +esac +AC_SUBST(LIBXMU) + # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D. if test "${HAVE_X11}" = "yes"; then if test "${USE_X_TOOLKIT}" != "none"; then === modified file 'src/ChangeLog' --- src/ChangeLog 2010-04-28 06:54:25 +0000 +++ src/ChangeLog 2010-04-28 07:01:43 +0000 @@ -1,5 +1,10 @@ 2010-04-28 Glenn Morris + * Makefile.in (LIBXMU): Set with configure, not cpp. + * s/aix4-2.h (LIBXMU): + * s/hpux10-20.h (LIBXMU): + Remove definition, now set in configure. + * Makefile.in (NS_OBJ, NS_SUPPORT): Set with configure, not cpp. * m/amdx86-64.h [i386]: Move this test to configure.in. === modified file 'src/Makefile.in' --- src/Makefile.in 2010-04-28 06:54:25 +0000 +++ src/Makefile.in 2010-04-28 07:01:43 +0000 @@ -86,6 +86,8 @@ GTK_OBJ=@GTK_OBJ@ +LIBXMU=@LIBXMU@ + LIBXSM=@LIBXSM@ LIBXTR6=@LIBXTR6@ @@ -261,11 +263,7 @@ #ifdef USE_X_TOOLKIT LIBW=$(TOOLKIT_LIBW) -#ifndef LIBXMU -#define LIBXMU -lXmu -#endif - -LIBXT= $(LIBW) LIBXMU -lXt $(LIBXTR6) -lXext +LIBXT= $(LIBW) $(LIBXMU) -lXt $(LIBXTR6) -lXext #else /* not USE_X_TOOLKIT */ === modified file 'src/s/aix4-2.h' --- src/s/aix4-2.h 2010-04-27 07:02:12 +0000 +++ src/s/aix4-2.h 2010-04-28 07:01:43 +0000 @@ -136,8 +136,6 @@ #undef sigmask #ifndef HAVE_LIBXMU -#define LIBXMU - /* Unfortunately without libXmu we cannot support EditRes. */ #define NO_EDITRES #endif @@ -153,8 +151,8 @@ It is possible to completely override the malloc implementation on AIX, but that involves putting the malloc functions in a shared library and setting the MALLOCTYPE environment variable to point to - tha shared library. - + that shared library. + Emacs currently calls xrealloc on the results of get_current_dir name, to avoid a crash just use the Emacs implementation for that function. */ === modified file 'src/s/hpux10-20.h' --- src/s/hpux10-20.h 2010-04-27 03:14:14 +0000 +++ src/s/hpux10-20.h 2010-04-28 07:01:43 +0000 @@ -105,12 +105,6 @@ /* This triggers a conditional in xfaces.c. */ #define XOS_NEEDS_TIME_H -#ifndef HAVE_LIBXMU -/* HP-UX doesn't supply Xmu. */ -#define LIBXMU - -#endif - /* Assar Westerlund says this is necessary for HP-UX 10.20, and that it works for HP-UX 0 as well. */ #define NO_EDITRES ------------------------------------------------------------ revno: 100064 committer: Glenn Morris branch nick: trunk timestamp: Tue 2010-04-27 23:54:25 -0700 message: Move NS_OBJ, NS_SUPPORT from cpp to configure. * configure.in (NS_OBJ, NS_SUPPORT): New output variables. * src/Makefile.in (NS_OBJ, NS_SUPPORT): Set with configure, not cpp. diff: === modified file 'ChangeLog' --- ChangeLog 2010-04-28 06:43:38 +0000 +++ ChangeLog 2010-04-28 06:54:25 +0000 @@ -1,5 +1,7 @@ 2010-04-28 Glenn Morris + * configure.in (NS_OBJ, NS_SUPPORT): New output variables. + * configure.in (machine, canonical): On amdx86-64, check for a 32-bit userland and maybe change values to i386 (move test from s/amdx86-64.h). === modified file 'configure.in' --- configure.in 2010-04-28 06:43:38 +0000 +++ configure.in 2010-04-28 06:54:25 +0000 @@ -1404,6 +1404,9 @@ NS_HAVE_NSINTEGER=no fi fi + +NS_OBJ= +NS_SUPPORT= if test "${HAVE_NS}" = yes; then window_system=nextstep with_xft=no @@ -1413,9 +1416,13 @@ if test "${EN_NS_SELF_CONTAINED}" = yes; then prefix=${ns_appresdir} fi + NS_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o fontset.o fringe.o image.o" + NS_SUPPORT="\${lispsource}emacs-lisp/easymenu.elc \${lispsource}term/ns-win.elc" fi CFLAGS="$tmp_CFLAGS" CPPFLAGS="$tmp_CPPFLAGS" +AC_SUBST(NS_OBJ) +AC_SUBST(NS_SUPPORT) case "${window_system}" in x11 ) === modified file 'src/ChangeLog' --- src/ChangeLog 2010-04-28 06:45:35 +0000 +++ src/ChangeLog 2010-04-28 06:54:25 +0000 @@ -1,5 +1,7 @@ 2010-04-28 Glenn Morris + * Makefile.in (NS_OBJ, NS_SUPPORT): Set with configure, not cpp. + * m/amdx86-64.h [i386]: Move this test to configure.in. 2010-04-27 Glenn Morris === modified file 'src/Makefile.in' --- src/Makefile.in 2010-04-27 08:09:01 +0000 +++ src/Makefile.in 2010-04-28 06:54:25 +0000 @@ -104,6 +104,9 @@ ## widget.o if USE_X_TOOLKIT, otherwise empty. WIDGET_OBJ=@WIDGET_OBJ@ +NS_OBJ=@NS_OBJ@ +NS_SUPPORT=@NS_SUPPORT@ + LIBSELINUX_LIBS = @LIBSELINUX_LIBS@ INTERVALS_H = dispextern.h intervals.h composite.h @@ -369,9 +372,6 @@ ns_appbindir=@ns_appbindir@/ ns_appresdir=@ns_appresdir@/ ns_appsrc=@ns_appsrc@ -/* Object files for NeXTstep */ -NS_OBJ= nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o \ - fontset.o fringe.o image.o #endif /* HAVE_NS */ #ifdef HAVE_WINDOW_SYSTEM @@ -504,13 +504,6 @@ #define TOOLTIP_SUPPORT #endif -#ifdef HAVE_NS -#define NS_SUPPORT ${lispsource}emacs-lisp/easymenu.elc \ - ${lispsource}term/ns-win.elc -#else -#define NS_SUPPORT -#endif - /* This is the platform-specific list of Lisp files loaded into the dumped Emacs. It is arranged like this because it is easier to generate it semi-mechanically from loadup.el this way. @@ -611,7 +604,7 @@ MSDOS_SUPPORT \ WINNT_SUPPORT \ WINDOW_SUPPORT \ - NS_SUPPORT \ + ${NS_SUPPORT} \ ${lispsource}widget.elc \ ${lispsource}window.elc \ ${lispsource}version.el ------------------------------------------------------------ revno: 100063 committer: Glenn Morris branch nick: trunk timestamp: Tue 2010-04-27 23:45:35 -0700 message: Missing src/ChangeLog for previous commit. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2010-04-27 08:09:01 +0000 +++ src/ChangeLog 2010-04-28 06:45:35 +0000 @@ -1,3 +1,7 @@ +2010-04-28 Glenn Morris + + * m/amdx86-64.h [i386]: Move this test to configure.in. + 2010-04-27 Glenn Morris * Makefile.in (LIBXTR6): Set with configure, not cpp. ------------------------------------------------------------ revno: 100062 committer: Glenn Morris branch nick: trunk timestamp: Tue 2010-04-27 23:43:38 -0700 message: Move test for 64-bit kernel with 32-bit userland to configure. See discussion in bug#5655. * configure.in (machine, canonical): On amdx86-64, check for a 32-bit userland and maybe change values to i386 (move test from s/amdx86-64.h). * src/m/amdx86-64.h [i386]: Move this test to configure.in. diff: === modified file 'ChangeLog' --- ChangeLog 2010-04-27 08:09:01 +0000 +++ ChangeLog 2010-04-28 06:43:38 +0000 @@ -1,3 +1,8 @@ +2010-04-28 Glenn Morris + + * configure.in (machine, canonical): On amdx86-64, check for a 32-bit + userland and maybe change values to i386 (move test from s/amdx86-64.h). + 2010-04-27 Glenn Morris * configure.in (LIBXTR6): New output variable. Move unixware special === modified file 'configure.in' --- configure.in 2010-04-27 08:09:01 +0000 +++ configure.in 2010-04-28 06:43:38 +0000 @@ -761,6 +761,20 @@ if test "x$RANLIB" = x; then AC_PROG_RANLIB fi + +## Although we're running on an amd64 kernel, we're actually compiling for +## the x86 architecture. The user should probably have provided an +## explicit --build to `configure', but if everything else than the kernel +## is running in i386 mode, we can help them out. +if test "$machine" = "amdx86-64"; then + AC_CHECK_DECL([i386]) + if test "$ac_cv_have_decl_i386" = "yes"; then + canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'` + machine=intel386 + machfile="m/${machine}.h" + fi +fi + AC_PATH_PROG(INSTALL_INFO, install-info) AC_PATH_PROG(INSTALL_INFO, install-info,, /usr/sbin) AC_PATH_PROG(INSTALL_INFO, install-info,:, /sbin) === modified file 'src/m/amdx86-64.h' --- src/m/amdx86-64.h 2010-04-27 03:14:14 +0000 +++ src/m/amdx86-64.h 2010-04-28 06:43:38 +0000 @@ -17,15 +17,6 @@ You should have received a copy of the GNU General Public License along with GNU Emacs. If not, see . */ -#ifdef i386 -/* Although we're running on an amd64 kernel, we're actually compiling for - the x86 architecture. The user should probably have provided an - explicit --build to `configure', but if everything else than the kernel - is running in i386 mode, then the bug is really ours: we should have - guessed better. */ -#include "m/intel386.h" -#else - /* The following line tells the configuration script what sort of operating system this machine is likely to run. USUAL-OPSYS="linux" */ @@ -90,7 +81,6 @@ #define LIB_STANDARD -lgcc -lc -lgcc $(CRT_DIR)/crtn.o #endif /* SOLARIS2 */ -#endif /* !i386 */ /* arch-tag: 8a5e001d-e12e-4692-a3a6-0b15ba271c6e (do not change this comment) */ ------------------------------------------------------------ revno: 100061 committer: Stefan Monnier branch nick: trunk timestamp: Tue 2010-04-27 14:14:16 -0400 message: Let the user turn off locally a globalized minor mode * emacs-lisp/easy-mmode.el (define-globalized-minor-mode): Avoid re-enabling a minor mode after the user turned the minor mode off if MODE-enable-in-buffers is run twice (typically once from fundamental-mode's after-change-major-mode-hook and a second time from run-mode-hook's own after-change-major-mode-hook). diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-04-27 17:57:32 +0000 +++ lisp/ChangeLog 2010-04-27 18:14:16 +0000 @@ -1,5 +1,11 @@ 2010-04-27 Stefan Monnier + * emacs-lisp/easy-mmode.el (define-globalized-minor-mode): + Avoid re-enabling a minor mode after the user turned the minor mode + off if MODE-enable-in-buffers is run twice (typically once from + fundamental-mode's after-change-major-mode-hook and a second time from + run-mode-hook's own after-change-major-mode-hook). + * emacs-lisp/lisp.el (lisp-complete-symbol): Fail gracefully. 2010-04-27 Sam Steingold === modified file 'lisp/emacs-lisp/easy-mmode.el' --- lisp/emacs-lisp/easy-mmode.el 2010-04-13 01:03:04 +0000 +++ lisp/emacs-lisp/easy-mmode.el 2010-04-27 18:14:16 +0000 @@ -361,13 +361,14 @@ (dolist (buf ,MODE-buffers) (when (buffer-live-p buf) (with-current-buffer buf - (if ,mode - (unless (eq ,MODE-major-mode major-mode) - (,mode -1) - (,turn-on) - (setq ,MODE-major-mode major-mode)) - (,turn-on) - (setq ,MODE-major-mode major-mode)))))) + (unless (eq ,MODE-major-mode major-mode) + (if ,mode + (progn + (,mode -1) + (,turn-on) + (setq ,MODE-major-mode major-mode)) + (,turn-on) + (setq ,MODE-major-mode major-mode))))))) (put ',MODE-enable-in-buffers 'definition-name ',global-mode) (defun ,MODE-check-buffers ()