Commit 0f75c62a authored by Chong Yidong's avatar Chong Yidong
Browse files

Two fixes for elpa packages overriding built-in ones.

* emacs-lisp/package.el (package-initialize): Ensure that
obsoleted built-in packages are not in package-activated-list
during activation.
(describe-package-1): Make the "installed" status override
"built-in".
parent b29f5b7b
2010-11-02 Chong Yidong <cyd@stupidchicken.com>
* emacs-lisp/package.el (package-initialize): Ensure that
obsoleted built-in packages are not in package-activated-list
during activation.
(describe-package-1): Make the "installed" status override
"built-in".
2010-11-01 Vinicius Jose Latorre <viniciusjl@ig.com.br>
 
* subr.el (version-separator, version-regexp-alist): Remove '*'
......
......@@ -1020,15 +1020,17 @@ makes them available for download."
The variable `package-load-list' controls which packages to load."
(interactive)
(require 'finder-inf nil t)
(setq package-alist package--builtins)
(setq package-activated-list (mapcar #'car package-alist))
(setq package-obsolete-alist nil)
(setq package-alist package--builtins
package-activated-list (mapcar #'car package-alist)
package-obsolete-alist nil)
(package-load-all-descriptors)
(package-read-all-archive-contents)
;; "Deactivate" obsoleted built-in packages
(dolist (elt package-obsolete-alist)
(delq (car elt) package-activated-list))
;; Try to activate all our packages.
(mapc (lambda (elt)
(package-activate (car elt) (package-desc-vers (cdr elt))))
package-alist))
(dolist (elt package-alist)
(package-activate (car elt) (package-desc-vers (cdr elt)))))
;;;; Package description buffer.
......@@ -1073,10 +1075,10 @@ The variable `package-load-list' controls which packages to load."
;; This package is loaded (i.e. in `package-alist').
(progn
(setq version (package-version-join (package-desc-vers desc)))
(cond (built-in
(princ "a built-in package.\n\n"))
((setq pkg-dir (package--dir package-name version))
(cond ((setq pkg-dir (package--dir package-name version))
(insert "an installed package.\n\n"))
(built-in
(princ "a built-in package.\n\n"))
(t ;; This normally does not happen.
(insert "a deleted package.\n\n")
(setq version nil))))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment