Mercurial > hg > xemacs-beta
diff lisp/loadup.el @ 398:74fd4e045ea6 r21-2-29
Import from CVS: tag r21-2-29
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:13:30 +0200 |
parents | aabb7f5b1c81 |
children | 5a2589c672dc |
line wrap: on
line diff
--- a/lisp/loadup.el Mon Aug 13 11:12:06 2007 +0200 +++ b/lisp/loadup.el Mon Aug 13 11:13:30 2007 +0200 @@ -42,18 +42,36 @@ (defvar preloaded-file-list nil "List of files preloaded into the XEmacs binary image.") +(defvar Installation-string nil + "Description of XEmacs installation.") (let ((gc-cons-threshold 30000)) ;; This is awfully damn early to be getting an error, right? (call-with-condition-handler 'really-early-error-handler #'(lambda () - ;; message not defined yet ... + + ;; Initialize Installation-string. We do it before loading + ;; anything so that dumped code can make use of its value. + (setq Installation-string + (save-current-buffer + (set-buffer (get-buffer-create (generate-new-buffer-name + " *temp*"))) + ;; insert-file-contents-internal bogusly calls + ;; format-decode without checking if it's defined. + (fset 'format-decode #'(lambda (f l &optional v) l)) + (insert-file-contents-internal "../Installation") + (fmakunbound 'format-decode) + (prog1 (buffer-substring) + (kill-buffer (current-buffer))))) + (setq load-path (split-path (getenv "EMACSBOOTSTRAPLOADPATH"))) (setq module-load-path (split-path (getenv "EMACSBOOTSTRAPMODULEPATH"))) + ;; message not defined yet ... (external-debugging-output (format "\nUsing load-path %s" load-path)) - (external-debugging-output (format "\nUsing module-load-path %s" module-load-path)) + (external-debugging-output (format "\nUsing module-load-path %s" + module-load-path)) ;; We don't want to have any undo records in the dumped XEmacs. (buffer-disable-undo (get-buffer "*scratch*")) @@ -86,7 +104,8 @@ (defun pureload (file) (let ((full-path (locate-file file load-path - (if load-ignore-elc-files ".el:" ".elc:.el:")))) + (if load-ignore-elc-files + '(".el" "") '(".elc" ".el" ""))))) (if full-path (prog1 (load full-path) @@ -98,7 +117,7 @@ ;;(print (format "guessed-roots: %S" (paths-find-emacs-roots invocation-directory invocation-name))) nil))) - (load (concat default-directory "../lisp/dumped-lisp.el")) + (load (expand-file-name "../lisp/dumped-lisp.el")) (let ((files preloaded-file-list) file) @@ -145,7 +164,6 @@ ;;; for the sake of the next call to precompute-menubar-bindings. ;(setq define-key-rebound-commands nil) - ;; Note: all compiled Lisp files loaded above this point ;; must be among the ones parsed by make-docfile ;; to construct DOC. Any that are not processed