use-package icon indicating copy to clipboard operation
use-package copied to clipboard

Can't install use-package to Emacs 27.1 (void-function: (lisp-data-mode)) on Rocky Linux

Open emakei opened this issue 1 year ago • 2 comments

autoload-generate-file-autoloads: use-package-pkg.el:0:0: error: void-function: (lisp-data-mode)

Just try M-x package-install RET use-package

emakei avatar Sep 29 '24 18:09 emakei

I am not a emacs expert, but leaving this for the next poor soul that runs into this.. I was able to work around this issue using this hack

(unless (or (fboundp 'lisp-data-mode)
            (not enable-local-variables))
  ;; Work around the fact that transient's autogenerated package header declares mode:
  ;; lisp-data, which is only present in Emacs 28+, thus breaking the loading of deps
  (message "Old Emacs version, remapping lisp-data-mode")
  (defalias 'lisp-data-mode 'emacs-lisp-mode))

hyperlogic avatar Mar 19 '25 02:03 hyperlogic

This sounds like either:

  • https://bugs.gnu.org/76264 on GNU ELPA; or
  • melpa/melpa#9193 on MELPA.

Both should be fixed, modulo waiting for affected packages to be rebuilt. Either way, it doesn't look specific to use-package.

Is this still an issue? If so, please provide more details about your Emacs version, configured package archives, packages being installed, etc.

basil-conto avatar Mar 20 '25 01:03 basil-conto