Subject: bug#63260: 29.0.90; Regression installing/activating packages without autoloads

From: Eli Zaretskii <[email-masked]>
Date: Sun, 07 May 2023 16:21:01 +0300

> From: Philip Kaludercic <[email-masked]>
> Cc: [email-masked],  [email-masked],  [email-masked]
> Date: Sun, 07 May 2023 13:12:47 +0000
> 
> One hack might just be to check if `loaddefs-generate' has generated
> anything at all or not, and if that is not the case to do so manually in
> package.el.  The reason this doesn't seem nice, is that we'd have to
> make the fact that `loaddefs-generate' does not generate a OUTPUT-FILE
> if there is no file with autoloads explicit, and finding a justification
> for that is difficult.  Alternatively, this could be done inside of
> `loaddefs-generate'?  Something like

Assuming it solves the issue and doesn't break anything, the latter
sounds good to me, better than the alternatives.

> +    ;; HACK: If no file with autoloads were found, but EXTRA-DATA was
> +    ;; passed, we still want to generate a file.

The comment says "EXTRA-DATA was passed", but this added snipped will
also run if EXTRA-DATA was NOT passed, but the OUTPUT-FILE doesn't
exist, right?

And I would explain in the comment the real-life situations where this
is needed, and why, rather than just explaining in English what the
code does.

Thanks.