On Wed, 23 Jul 2008 15:49:59 -0400, Stefan Monnier
<address@hidden> said:
> It strikes me that Debian's Emacsen seem to not be plain enough. I
> mean, Debian seems to change Emacs's startup.el even tho there's no
> need for it. Instead of changing startup.el to (load
> "debian-startup") and call some magic function in it, it'd be much
> better to leave Emacs's own startup code unchanged and simply provide
> a site-start.el that loads debian-startup as well as
> /etc/emacs/site-start.el and all the rest.
Well, site-start.el was deemed to be for site specific stuff,
and is shipped empty by the vendor (i.e., Debian). The Studd in
startup.el is only to cater to the vendor changes for third party Elisp
packages, and is not really a site specific change. This means that the
load-path is customized even when --no-site-file is specified.
> I can't see why this can't work just a well as the current setup, with
> the advantage of minimizing the difference between a plain Emacs and a
> Debian Emacs (and clearly documenting this difference since it's kept
> in a user-visible file rather than stashed in an internal source file
> only available if you install the emacs-el package).
Isn't there some issue with order of loading there? By modifying
startup.el, changes are made that allow setting load-path before _any_
action is taken, namely, language setting, window system
initialization, and option processing. So the two things are not
equivalent.
manoj
Here is the full extent of the change in startup.el
--8<---------------cut here---------------start------------->8---
@@ -381,6 +381,10 @@ from being initialized."
(defvar normal-top-level-add-subdirs-inode-list nil)
+(defconst debian-emacs-flavor 'emacs-snapshot
+ "A symbol representing the particular debian flavor of emacs running.
+Something like 'emacs20, 'xemacs20, etc.")
+
(defvar no-blinking-cursor nil)
(defvar default-frame-background-mode)
@@ -953,8 +957,13 @@ opening the first frame (e.g. open a connection to an X
server).")
;; should check init-file-user instead, since that is already set.
;; See cus-edit.el for an example.
(if site-run-file
- (load site-run-file t t))
-
+ (progn
+ ;; Load all the debian package snippets.
+ ;; It's in here because we want -q to kill it too.
+ (if (load "debian-startup" t t nil)
+ (debian-startup debian-emacs-flavor))
+ ;; Now the normal site file...
+ (load site-run-file t t nil)))
;; Sites should not disable this. Only individuals should disable
;; the startup screen.
(setq inhibit-startup-screen nil)
--8<---------------cut here---------------end--------------->8---
--
Forsan et haec olim meminisse juvabit.
Manoj Srivastava <address@hidden> <http://www.golden-gryphon.com/>
1024D/BF24424C print 4966 F272 D093 B493 410B 924B 21BA DABB BF24 424C