annotate lisp/prim/loadup.el @ 74:54cc21c15cbb r20-0b32

Import from CVS: tag r20-0b32
author cvs
date Mon, 13 Aug 2007 09:04:33 +0200
parents 131b0175ea99
children 0d2f883870bc
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1 ;;; loadup.el --- load up standardly loaded Lisp files for XEmacs.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
2
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
3 ;; It is not a good idea to edit this file. Use site-init.el or site-load.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
4 ;; instead.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
5 ;;
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
6 ;; Copyright (C) 1985, 1986, 1992, 1994 Free Software Foundation, Inc.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
7 ;; Copyright (C) 1996 Richard Mlynarik.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
8 ;; Copyright (C) 1995, 1996 Ben Wing.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
9
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
10 ;; Keywords: internal
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
11
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
12 ;; This file is part of XEmacs.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
13
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
14 ;; XEmacs is free software; you can redistribute it and/or modify it
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
15 ;; under the terms of the GNU General Public License as published by
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
16 ;; the Free Software Foundation; either version 2, or (at your option)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
17 ;; any later version.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
18
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
19 ;; XEmacs is distributed in the hope that it will be useful, but
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
20 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
21 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
22 ;; General Public License for more details.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
23
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
24 ;; You should have received a copy of the GNU General Public License
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
25 ;; along with XEmacs; see the file COPYING. If not, write to the Free
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
26 ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
27 ;; 02111-1307, USA.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
28
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
29 ;;; Synched up with: Last synched with FSF 19.30, with wild divergence since.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
30
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
31 ;;; Commentary:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
32
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
33 ;; This is loaded into a bare Emacs to make a dumpable one.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
34
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
35 ;;; Code:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
36
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
37 (if (fboundp 'error)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
38 (error "loadup.el already loaded!"))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
39
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
40 (define-function 'defalias 'define-function)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
41
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
42 (call-with-condition-handler
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
43 ;; This is awfully damn early to be getting an error, right?
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
44 'really-early-error-handler
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
45 #'(lambda ()
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
46 ;; message not defined yet ...
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
47 (external-debugging-output (format "\nUsing load-path %s" load-path))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
48
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
49 ;; We don't want to have any undo records in the dumped XEmacs.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
50 (buffer-disable-undo (get-buffer "*scratch*"))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
51
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
52 ;; lread.c (or src/Makefile.in.in) has prepended "${srcdir}/../lisp/prim"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
53 ;; to load-path, which is how this file has been found. At this point,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
54 ;; enough of emacs has been initialized that we can call directory-files
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
55 ;; and get the rest of the dirs (so that we can dump stuff from modes/
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
56 ;; and packages/.)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
57 ;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
58 (let ((temp-path (expand-file-name ".." (car load-path))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
59 (setq source-directory temp-path)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
60 (setq load-path (nconc (directory-files temp-path t "^[^-.]"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
61 nil 'dirs-only)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
62 (cons temp-path load-path))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
63
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
64 (setq load-warn-when-source-newer t ; set to nil at the end
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
65 load-warn-when-source-only t)
50
ee648375d8d6 Import from CVS: tag r19-16b91
cvs
parents: 32
diff changeset
66
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
67 ;; garbage collect after loading every file in an attempt to
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
68 ;; minimize the size of the dumped image (if we don't do this,
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
69 ;; there will be lots of extra space in the data segment filled
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
70 ;; with garbage-collected junk)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
71 (defmacro load-gc (file)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
72 (list 'prog1 (list 'load file) '(garbage-collect)))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
73 (load-gc "backquote") ; needed for defsubst etc.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
74 (load-gc "bytecomp-runtime") ; define defsubst
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
75 (load-gc "subr") ; load the most basic Lisp functions
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
76 (load-gc "replace") ; match-string used in version.el.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
77 (load-gc "version.el") ; Ignore compiled-by-mistake version.elc
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
78 (load-gc "cl")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
79 (load-gc "cmdloop")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
80 (or (fboundp 'recursive-edit) (load-gc "cmdloop1"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
81 (load-gc "keymap")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
82 (load-gc "syntax")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
83 (load-gc "device")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
84 (load-gc "console")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
85 (load-gc "obsolete")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
86 (load-gc "specifier")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
87 (load-gc "faces") ; must be loaded before any make-face call
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
88 ;;(load-gc "facemenu") #### not yet ported
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
89 (load-gc "glyphs")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
90 (load-gc "objects")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
91 (load-gc "extents")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
92 (load-gc "events")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
93 (load-gc "text-props")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
94 (load-gc "process")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
95 (load-gc "frame") ; move up here cause some stuff needs it here
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
96 (load-gc "map-ynp")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
97 (load-gc "simple")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
98 (load-gc "keydefs") ; Before loaddefs so that keymap vars exist.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
99 (load-gc "abbrev")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
100 (load-gc "derived")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
101 (load-gc "minibuf")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
102 (load-gc "list-mode")
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
103 (load-gc "modeline") ; needs simple.el to be loaded first
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
104 ;; If SparcWorks support is included some additional packages are
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
105 ;; dumped which would normally have autoloads. To avoid
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
106 ;; duplicate doc string warnings, SparcWorks uses a separate
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
107 ;; autoloads file with the dumped packages removed.
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
108 ;; After fixing, eos/loaddefs-eos and loaddefs appear identical?!!
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
109 ;; So just make loaddefs-eos go away...
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
110 ;;(load-gc (if (featurep 'sparcworks) "eos/loaddefs-eos" "loaddefs"))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
111 (load-gc "loaddefs")
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
112 (load-gc "misc")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
113 (load-gc "profile")
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
114 (load-gc "help")
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
115 ;; (load-gc "hyper-apropos") Soon...
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
116 (when (not (featurep 'mule))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
117 (load-gc "files-nomule"))
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
118 (load-gc "files")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
119 (load-gc "lib-complete")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
120 (load-gc "format")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
121 (load-gc "indent")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
122 (load-gc "isearch-mode")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
123 (load-gc "buffer")
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
124 (load-gc "buff-menu")
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
125 (load-gc "undo-stack")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
126 (load-gc "window")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
127 (load-gc "paths.el") ; don't get confused if paths compiled.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
128 (load-gc "startup")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
129 (load-gc "lisp")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
130 (load-gc "page")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
131 (load-gc "register")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
132 (load-gc "iso8859-1") ; This must be before any modes
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
133 ; (sets standard syntax table.)
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
134 (load-gc "paragraphs")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
135 (load-gc "lisp-mode")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
136 (load-gc "text-mode")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
137 (load-gc "fill")
74
54cc21c15cbb Import from CVS: tag r20-0b32
cvs
parents: 70
diff changeset
138 ;; (load-gc "cc-mode") ; as FSF goes so go we ..
54cc21c15cbb Import from CVS: tag r20-0b32
cvs
parents: 70
diff changeset
139 ;; (load-gc "scroll-in-place") ; We're not ready for this :-(
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
140 ;; we no longer load buff-menu automatically.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
141 ;; it will get autoloaded if needed.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
142
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
143 (cond ; Differences based on system-type
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
144 ((eq system-type 'vax-vms)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
145 (load-gc "vmsproc")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
146 (load-gc "vms-patch"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
147 ((eq system-type 'windows-nt)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
148 (load-gc "ls-lisp")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
149 (load-gc "winnt"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
150 ((eq system-type 'ms-dos)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
151 (load-gc "ls-lisp")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
152 (load-gc "dos-fns")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
153 (load-gc "disp-table"))) ; needed to setup ibm-pc char set,
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
154 ; see internal.el
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
155 (when (featurep 'lisp-float-type)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
156 (load-gc "float-sup"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
157 (load-gc "itimer") ; for vars auto-save-timeout and auto-gc-threshold
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
158 (if (featurep 'toolbar)
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
159 (load-gc "toolbar")
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
160 ;; else still define a few functions.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
161 (defun toolbar-button-p (obj) "No toolbar support." nil)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
162 (defun toolbar-specifier-p (obj) "No toolbar support." nil))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
163 (when (featurep 'scrollbar)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
164 (load-gc "scrollbar"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
165 (when (featurep 'menubar)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
166 (load-gc "menubar"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
167 (when (featurep 'dialog)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
168 (load-gc "dialog"))
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
169 (when (featurep 'mule)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
170 (load-gc "mule-load.el"))
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
171 (when (featurep 'window-system)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
172 (load-gc "gui")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
173 (load-gc "mode-motion")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
174 (load-gc "mouse"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
175 (when (featurep 'x)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
176 ;; preload the X code, for faster startup.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
177 (when (featurep 'menubar)
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
178 (load-gc "x-menubar")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
179 ;; autoload this.
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
180 ;;(load-gc "x-font-menu")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
181 )
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
182 (load-gc "x-faces")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
183 (load-gc "x-iso8859-1")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
184 (load-gc "x-mouse")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
185 (load-gc "x-select")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
186 (when (featurep 'scrollbar)
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
187 (load-gc "x-scrollbar"))
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
188 (load-gc "x-misc")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
189 (load-gc "x-init")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
190 (when (featurep 'toolbar)
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
191 (load-gc "x-toolbar"))
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
192 )
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
193 (when (featurep 'tty)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
194 ;; preload the TTY init code.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
195 (load-gc "tty-init"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
196 (when (featurep 'tooltalk)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
197 (load-gc "tooltalk/tooltalk-load"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
198 (load-gc "vc-hooks")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
199 (load-gc "ediff-hook")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
200 (load-gc "fontl-hooks")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
201 (load-gc "auto-show")
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
202 (when (featurep 'energize)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
203 (load-gc "energize/energize-load.el"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
204 (when (featurep 'sparcworks)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
205 (load-gc "sunpro/sunpro-load.el"))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
206 (fmakunbound 'load-gc)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
207 )) ;; end of call-with-condition-handler
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
208
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
209
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents: 2
diff changeset
210 (setq load-warn-when-source-newer t ; set to t at top of file
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
211 load-warn-when-source-only nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
212
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
213 (setq debugger 'debug)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
214
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
215 (when (member "no-site-file" command-line-args)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
216 (setq site-start-file nil))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
217
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
218 ;; If you want additional libraries to be preloaded and their
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
219 ;; doc strings kept in the DOC file rather than in core,
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
220 ;; you may load them with a "site-load.el" file.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
221 ;; But you must also cause them to be scanned when the DOC file
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
222 ;; is generated. For VMS, you must edit ../../vms/makedoc.com.
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
223 ;; For other systems, you must edit ../../src/Makefile.in.in.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
224 (if (load "site-load" t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
225 (garbage-collect))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
226
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
227 ;;FSFmacs randomness
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
228 ;;(if (fboundp 'x-popup-menu)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
229 ;; (precompute-menubar-bindings))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
230 ;;; Turn on recording of which commands get rebound,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
231 ;;; for the sake of the next call to precompute-menubar-bindings.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
232 ;(setq define-key-rebound-commands nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
233
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
234
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
235 ;; Note: all compiled Lisp files loaded above this point
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
236 ;; must be among the ones parsed by make-docfile
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
237 ;; to construct DOC. Any that are not processed
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
238 ;; for DOC will not have doc strings in the dumped XEmacs.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
239
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
240 ;; Don't bother with these if we're running temacs, i.e. if we're
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
241 ;; just debugging don't waste time finding doc strings.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
242
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
243 ;; purify-flag is nil if called from loadup-el.el.
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
244 (when purify-flag
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
245 (message "Finding pointers to doc strings...")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
246 (Snarf-documentation "DOC")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
247 (message "Finding pointers to doc strings...done")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
248 (Verify-documentation))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
249
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
250 ;; Note: You can cause additional libraries to be preloaded
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
251 ;; by writing a site-init.el that loads them.
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
252 ;; See also "site-load" above.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
253 (if (stringp site-start-file)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
254 (load "site-init" t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
255 (setq current-load-list nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
256 (garbage-collect)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
257
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
258 ;;; At this point, we're ready to resume undo recording for scratch.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
259 (buffer-enable-undo "*scratch*")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
260
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
261 ;; Dump into the name `xemacs' (only)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
262 (when (member "dump" command-line-args)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
263 (message "Dumping under the name xemacs")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
264 (condition-case () (delete-file "xemacs") (file-error nil))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
265 (when (fboundp 'really-free)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
266 (really-free))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
267 (dump-emacs "xemacs" "temacs")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
268 (kill-emacs))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
269
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
270 (when (member "run-temacs" command-line-args)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
271 (message "\nBootstrapping from temacs...")
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
272 (setq purify-flag nil)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
273 ;; Remove all args up to and including "run-temacs"
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
274 (apply #'run-emacs-from-temacs (cdr (member "run-temacs" command-line-args)))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
275 ;; run-emacs-from-temacs doesn't actually return anyway.
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
276 (kill-emacs))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
277
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
278 ;; Avoid error if user loads some more libraries now.
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
279 (setq purify-flag nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
280
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
281 ;; XEmacs change
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
282 ;; If you are using 'recompile', then you should have used -l loadup-el.el
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
283 ;; so that the .el files always get loaded (the .elc files may be out-of-
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
284 ;; date or bad).
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
285 (when (member "recompile" command-line-args)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
286 (let ((command-line-args-left (cdr (member "recompile" command-line-args))))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
287 (batch-byte-recompile-directory)
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
288 (kill-emacs)))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
289
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
290 ;; For machines with CANNOT_DUMP defined in config.h,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
291 ;; this file must be loaded each time Emacs is run.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
292 ;; So run the startup code now.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
293
70
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
294 (when (not (fboundp 'dump-emacs))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
295 ;; Avoid loading loadup.el a second time!
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
296 (setq command-line-args (cdr (cdr command-line-args)))
131b0175ea99 Import from CVS: tag r20-0b30
cvs
parents: 50
diff changeset
297 (eval top-level))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
298
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
299 ;;; loadup.el ends here