Subject: bug#46790: 28.0.50; make install with native-comp branch

From: Thierry Volpiatto <[email-masked]>
Date: Sun, 25 Apr 2021 18:21:41 +0000

Eli Zaretskii <[email-masked]> writes:

>> Cc: [email-masked], [email-masked]
>> From: Phil Sainty <[email-masked]>
>> Date: Mon, 26 Apr 2021 02:28:08 +1200
>> 
>> On 26/04/21 1:28 am, Eli Zaretskii wrote:
>> > In any case, what error messages do you see with async-start now?
>> > can you show those messages in their entirety?
>> 
>> Perhaps something like this will help?
>> 
>> emacs --batch -f package-initialize -l async \
>>   --eval "(message \"%s\" (executable-find \"emacs\"))" \
>>   --eval "(pp (async-get (async-start (lambda ()
>>           (list comp-eln-load-path (pdumper-stats))))))"
>
> If my reading of async.el is correct, it invoces the inferior Emacs
> like this:
>
>     (setq async--procvar
>           (async-start-process
>            "emacs" (file-truename
>                     (expand-file-name invocation-name
>                                       invocation-directory))
>            finish-func
>            async-quiet-switch "-l"
>            ;; Using `locate-library' ensure we use the right file
>            ;; when the .elc have been deleted.
>            (locate-library "async")
>            "-batch" "-f" "async-batch-invoke"
>            (if async-send-over-pipe
>                "<none>"
>              (with-temp-buffer
>                (async--insert-sexp (list 'quote sexp)) (buffer-string)))))
>
> Thierry, what does the below yield in the interactive session from
> which you invoke async-start?
>
>   M-: (file-truename (expand-file-name invocation-name invocation-directory)) RET

With my emacs started from PATH with "emacs" where emacs is a symlink:

    /usr/local/sbin/emacs-28.0.50/emacs-28.0.50

which is the correct path:

    (expand-file-name invocation-name invocation-directory)

==>/usr/local/bin/emacs

    (file-truename "/usr/local/bin/emacs")

==> /usr/local/sbin/emacs-28.0.50/emacs-28.0.50

-- 
Thierry