* lisp/startup.el (normal-top-level): Update eln-cache after
'user-emacs-directory' is set by --init-directory. Patch by
Jordan Isaacs <jordan@snowytrees.dev>. (Bug#75022)
(cherry picked from commit
b63ba892f9b28062a4ece9db7e4abd79a88ceea6)
(unwind-protect
(command-line)
+ (when (featurep 'native-compile)
+ (startup--update-eln-cache))
+
;; Do this again, in case .emacs defined more abbreviations.
(if default-directory
(setq default-directory (abbreviate-file-name default-directory)))