Package cl is deprecated

Hi! Suddenly, lkb mode in emacs ceased to work. When I enter “M x lkb”, I get the following message:

Package cl is deprecated

Lkb mode is not loaded. This seems strange to me, because I didn’t change anything in my system (Ubuntu). I suspect the error is caused by the fact that emacs was automatically updated to a new version:

GNU Emacs 28.1 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.24.20, cairo version 1.16.0)
of 2022-04-06

I would much appreciate any hints on how to solve this problem.
Leonel

@lionel Yes, it seems that the package cl was deprecated in emacs 27. I hadn’t noticed this since the emacs versions I have installed are based on 25.3 (latest version of macOS Aquamacs) and 26.3 (this year’s UW Ubuntu+LKB).

The ‘classic’ LKB in the LOGON distribution uses the Franz eli system for emacs integration. The cl dependency was fixed in September 2021 https://github.com/franzinc/eli/issues/1 so you could download a new version from there.

LKB-FOS uses slime for emacs integration. At present it bundles slime 2.26.1, which requires the package cl. Upgrading to slime 2.27 (released in January) removes this dependency. You can upgrade by replacing the file emacs/slime.el in your LKB-FOS directory with https://raw.githubusercontent.com/slime/slime/master/slime.el . After M-x lkb you’ll get a warning about a version mismatch, which you can just answer with ‘y’.

Thanks, @johnca. I first tried the second solution but now I get:

Loading cua-base (native compiled elisp)…done
For information about GNU Emacs and the GNU system, type C-h C-a.
Eager macro-expansion failure: (wrong-number-of-arguments (3 . 4) 2) [2 times]
define-obsolete-variable-alias: Wrong number of arguments: (3 . 4), 2

Hmm, some sort of incompatibility. I think this reddit thread is relevant: https://www.reddit.com/r/emacs/comments/kqb9s9/cannot_recompile_packagess_error_wrong_number_of/ . Could you try the solution suggested there?

1 Like

Great, @johnca , this worked for me! Many thanks.

Thanks, @lionel, I’m glad it worked.

I’ve looked into this further, and here’s a better fix than the reddit solution: replace your current file emacs/lib/hyperspec.el with https://raw.githubusercontent.com/slime/slime/master/lib/hyperspec.el

1 Like

Thanks, @johnca . This also worked. After loading LKB with M x lkb, the following message appeared:

Versions differ: 2.27 (slime) vs. 2.26.1 (swank). Continue? (y or n)

I entered “y” and and could normally work with LKB from within emacs.