NEW: For a prettier blog interface, see the Wordpress version!

http://www.emacswiki.org/cgi-bin/wiki/ may be more updated.

Tasks

How do you get your newly built Emacs from CVS and Debian to work well together?

Package: emacscvs
Section: editors
Priority: standard
Architecture: any
Depends: emacsen-common (>= 1.4.10) 
Provides: emacsen, info-browser, mail-reader, news-reader, emacs21
Priority: standard
Description: Fake package of the GNU Emacs editor.
 GNU Emacs is the extensible self-documenting text editor. This is the equivs package for fake Emacs CVS.
(I added a Provides: emacs21 for packages that explicitely check for emacs21.)
--- startup.el  5 Sep 2002 00:19:49 -0000       1.306
+++ startup.el  8 Sep 2002 08:28:57 -0000
@@ -356,6 +356,10 @@
 
 (defvar normal-top-level-add-subdirs-inode-list nil)
 
+(defconst debian-emacs-flavor 'emacscvs
+  "A symbol representing the particular debian flavor of emacs running.
+  Something like 'emacs20, 'xemacs20, etc.")
+  
 (defun normal-top-level-add-subdirs-to-load-path ()
   "Add all subdirectories of current directory to `load-path'.
 More precisely, this uses only the subdirectories whose names
@@ -872,8 +876,15 @@
     ;; Run the site-start library if it exists.  The point of this file is
     ;; that it is run before .emacs.  There is no point in doing this after
     ;; .emacs; that is useless.
-    (if site-run-file 
-       (load site-run-file t t))
+    ;; Debian version of site-start.
+        (if site-run-file
+          (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 message.

You can safely remove your old Emacs version now. Any new Debian Emacs packages you install should automatically get bytecompiled for Emacs CVS unless it makes an explicit check against emacs21. If you find this bothersome, you may want to change the flavor to emacs21 instead - just make sure you hold the package.

This is just GREATTTTTTTTTTT! I was trying to find an emacs-cvs version debianized for so long :) Now I can make my own one. -- XavierMaillard (zeDek)


Or... Use equivs to make a fake emacs21 package. Make a control file with:

Package: emacs21
Section: editors
Version: 21.3
Priority: standard
Architecture: any
Depends: emacsen-common (>= 1.4.10) 
Provides: emacsen, info-browser, mail-reader, news-reader, emacs21
Priority: standard
Description: Fake package of the GNU Emacs editor.
 GNU Emacs is the extensible self-documenting text editor. This is the equivs package for fake Emacs 21.3.
Set the version number to the right one, though.

ln /usr/local/bin/emacs /usr/sbin/emacs21 -s

equivs-build control
dpkg -i emacs21_21.3_*.deb
echo emacs21 >> /var/lib/emacsen-common/installed-flavors
mkdir -p /etc/emacs21/site-start.d
/usr/lib/emacsen-common/emacs-install emacs21
Downside is that the two packages can't coexist. MarioLang says that this is a bad idea, though.

Why ? I personally want to use latest version of both Emacs and Gnus so I need to update everyday or so. AFAIK, there is no Emacs CVS package in Debian (even in Sid) and I don't want to use the one provided with Debian but still want to install 3rd party paquages in Debian. IMHO I don't have the choice. -- XavierMaillard


Another idea: just put this in your .emacs.el (it works for me):

 (let ((startup-file "/usr/share/emacs21/site-lisp/debian-startup.elc"))
   (if (and (or (not (fboundp 'debian-startup))
                (not (boundp  'debian-emacs-flavor)))
            (file-readable-p startup-file))
       (progn
         (load-file startup-file)
         (setq debian-emacs-flavor 'emacs21)
         (debian-startup debian-emacs-flavor))))

== Emacs From Source Without Debian Stuff ==

If you don't want to depend on emacsen-common and all that, try the following:

To create the fake package, apt-get install equivs, and create a file named "control" as follows:

Package: emacs-src
Section: editors
Priority: standard
Architecture: any
Provides: emacsen, info-browser, mail-reader, news-reader, emacs21
Priority: standard
Description: Fake package of the GNU Emacs editor.
 GNU Emacs is the extensible self-documenting text editor.
 This is the equivs package for a fake Emacs for those people
 that build Emacs from source locally.
This provides emacs21 for packages that explicitely check for emacs21, and it does not provide www-browser because w3 is not part of Emacs.

Run equivs-build control.

Run dpkg -i emacs-src*.deb

Done! Now you can apt-get install emacspeak without having to install emacs20 and emacsen-common.

Previous day | Next day

I'd love to hear about any questions, comments, suggestions or links that you might have. Your comments will not be posted on this website immediately, but will be e-mailed to me first. You can use this form to get in touch with me, or e-mail me at [email protected] .

Page: Emacs Cvs and Debian
Updated: 2004-12-11
NOTE: ANTI-SPAM MEASURE NOW IN PLACE. Please answer the following question with the right number in order to send me your comment.
What is two minus one? (hint: one ;) )
Name:
E-mail:
URL:
Comments: