From 2587aac798f064807cf8884a04eaf274508d9ace Mon Sep 17 00:00:00 2001 From: Rob Browning Date: Mon, 4 Apr 2011 22:46:22 -0500 Subject: [PATCH] Run debian-startup and set debian-emacs-flavor Emacs runs debian-startup and sets debian-emacs-flavor. * Emacs runs debian-startup during the startup process unless site-run-file is false. * The global variable debian-emacs-flavor is bound to 'emacs. Author: Rob Browning Gbp-Pq: Name 0002-Run-debian-startup-and-set-debian-emacs-flavor.patch --- lisp/startup.el | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/lisp/startup.el b/lisp/startup.el index eb1e027d2cb..ccfcfee8f0e 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -438,6 +438,10 @@ Warning Warning!!! Pure space overflow !!!Warning Warning :type 'directory :initialize #'custom-initialize-delay) +(defconst debian-emacs-flavor 'emacs + "A symbol representing the particular debian flavor of emacs running. +Something like 'emacs, 'xemacs21, etc.") + (defun normal-top-level-add-subdirs-to-load-path () "Recursively add all subdirectories of `default-directory' to `load-path'. More precisely, this uses only the subdirectories whose names @@ -1472,7 +1476,14 @@ please check its value") ;; Sites should not disable the startup screen. ;; Only individuals should disable the startup screen. (let ((inhibit-startup-screen inhibit-startup-screen)) - (load site-run-file t t))) + (progn + ;; This form has been added by Debian to load all the + ;; debian package snippets (dh-elpa, etc.). It's in here + ;; because we want -q to kill it too. + (if (load "debian-startup" t t nil) + (debian-startup debian-emacs-flavor)) + ;; This is the normal upstream behavior + (load site-run-file t t)))) ;; Load that user's init file, or the default one, or none. (startup--load-user-init-file -- 2.30.2