help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Updating Elisp files while Emacs is running


From: Phillip Lord
Subject: Re: Updating Elisp files while Emacs is running
Date: Mon, 14 Mar 2016 14:48:17 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)




Philipp Stephani <p.stephani2@gmail.com> writes:
> OS-level package managers such as Debian's dpkg generally replace files
> unconditionally when upgrading. Typically this is not a problem because
> running binaries will continue to use the in-memory image, and daemons can
> get restarted or sent a signal without user interaction. However, for Emacs
> the situation seems different: Emacs not only needs its (dumped) binary,
> but also relies on Elisp files. For Elisp files already loaded when the
> upgrade is running this typically doesn't cause problems, but when Elisp
> files aren't already loaded, replacing them causes problems because the
> directories containing them are versioned (see e.g. lispdir in configure.ac),
> so that when the version changes (even for minor changes, such as updating
> from the recent pretest-1 to pretest-2), the files are no longer at the
> expected location, and libraries can't be loaded any more, either manually
> or via autoloads. Similar things happen for system-wide ELPA packages (in
> the package-directory-list directories), because the names of these
> directories are also versioned. How could this be changed so that
> unattended upgrades changing the Emacs version are possible while Emacs is
> running? Could the Elisp file directories get names that don't include the
> version number (maybe hidden behind a configure option)? Is it possible to
> install system-wide ELPA packages into directories that don't contain
> version numbers? Or is there another way, e.g. using a signal to
> reinitialize the load-path and the package system? I'm aware these
> suggestions would still cause issues if e.g. Elisp files get moved around
> or the byte code format changes, but that seems to be comparatively rare.


I am not sure I see the issue. When updates to the core occur, then the
version number changes, so new files will not overwrite existing ones,
nor will the load-path be changed.

Likewise, for ELPA, as far as I know -- the load-path is set once during
package-initialize, so if a new version of a package gets added, Emacs
will run with the old.

If you want an existing Emacs to move to the new packages, that would be
hard to get right; only a restart is going to make sense here.

Why is that a problem?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]