unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Andrea Corallo <acorallo@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: No Wayman <iarchivedmywholelife@gmail.com>, 64226@debbugs.gnu.org
Subject: bug#64226: 30.0.50; emacs-lisp-native-compile-and-load permission error
Date: Sun, 25 Jun 2023 10:44:09 -0400	[thread overview]
Message-ID: <yp1ttuv7gau.fsf@fencepost.gnu.org> (raw)
In-Reply-To: <83o7l7327u.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 22 Jun 2023 19:12:53 +0300")

Eli Zaretskii <eliz@gnu.org> writes:

>> From: No Wayman <iarchivedmywholelife@gmail.com>
>> Cc: Andrea Corallo <acorallo@gnu.org>, 64226@debbugs.gnu.org
>> Date: Thu, 22 Jun 2023 11:44:33 -0400
>> 
>> I have reproduced from emacs -Q as well. Same error as above:
>> 
>> 
>> Compiling /home/n/.emacs.d/elpaca/repos/elpaca/elpaca.el...done
>> comp--native-compile: Native compiler error: 
>> "/home/n/.emacs.d/elpaca/repos/elpaca/elpaca.el", "Compiling 
>> /usr/lib/emacs/30.0.50/native-lisp/30.0.50-58a66af6/elpaca-0646d6fc-1256ece5.eln...
>> Creating file with prefix: Permission denied, 
>> /usr/lib/emacs/30.0.50/native-lisp/30.0.50-58a66af6/elpaca-0646d6fc-1256ece5
>> 
>> Error: permission-denied (\"Creating file with prefix\" 
>> \"Permission denied\" 
>> \"/usr/lib/emacs/30.0.50/native-lisp/30.0.50-58a66af6/elpaca-0646d6fc-1256ece5\")
>>   mapbacktrace(#f(compiled-function (evald func args flags) 
>>   #<bytecode 0x70d6f07f3ae8645>))
>>   debug-early-backtrace()
>>   debug-early(error (permission-denied \"Creating file with 
>>   prefix\" \"Permission denied\" 
>>   \"/usr/lib/emacs/30.0.50/native-lisp/30.0.50-58a66af6/elpaca-0646d6fc-1256ece5\"))
>>   make-temp-file(\"/usr/lib/emacs/30.0.50/native-lisp/30.0.50-58a66af6/elpaca-0646d6fc-1256ece5\" 
>>   nil \".eln.tmp\" nil)
>>   comp--compile-ctxt-to-file(\"/usr/lib/emacs/30.0.50/native-lisp/30.0.50-58a66af6/elpaca-0646d6fc-1256ece5.eln\")
>>   comp-compile-ctxt-to-file(\"/usr/lib/emacs/30.0.50/native-lisp/30.0.50-58a66af6/elpaca-0646d6fc-1256ece5.eln\")
>>   comp-final1()
>>   load-with-code-conversion(\"/tmp/emacs-int-comp-elpaca-0646d6fc-1256ece5-oSdhiB.el\" 
>>   \"/tmp/emacs-int-comp-elpaca-0646d6fc-1256ece5-oSdhiB.el\" nil 
>>   t)
>>   command-line-1((\"-l\" 
>>   \"/tmp/emacs-int-comp-elpaca-0646d6fc-1256ece5-oSdhiB.el\"))
>>   command-line()
>>   normal-top-level()
>>  
>> > I also don't understand why the backtrace above seems to imply 
>> > that
>> > you invoked Emacs like this:
>> >
>> >   emacs -l 
>> >   /tmp/emacs-int-comp-elpaca-0646d6fc-1256ece5-73Dpd0.el
>> 
>> > IOW, the backtrace doesn't show invocation of
>> > emacs-lisp-native-compile-and-load, it shows the attempt to load 
>> > an
>> > already-compiled .eln file.  What am I missing?  I added Andrea 
>> > to
>> > this discussion.
>> 
>> The compilation takes place in a subprocess, no?
>
> No, I don't think so, not with emacs-lisp-native-compile-and-load.
> Andrea, am I right?

We always invoke libgccjit in a subprocess, the difference between sync
and async is:

- in sync compilation we run all our compiler *but* libgccjit in process
  (libgccjit runs in a subprocess)

- in async all the compilation computation is done in a sub process.

The reason for running libgccjit always in a subprocess is that
unfortunatelly it leaks memory.

Best Regards

  Andrea





      parent reply	other threads:[~2023-06-25 14:44 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-21 16:58 bug#64226: 30.0.50; emacs-lisp-native-compile-and-load permission error No Wayman
2023-06-22 15:34 ` Eli Zaretskii
2023-06-22 15:44   ` No Wayman
2023-06-22 16:12     ` Eli Zaretskii
2023-06-22 16:22       ` No Wayman
2023-06-22 17:16         ` Eli Zaretskii
2023-06-22 17:21           ` No Wayman
2023-06-22 17:53             ` Eli Zaretskii
2023-06-25 15:02               ` Andrea Corallo
2023-07-01  8:36                 ` Eli Zaretskii
2023-07-01 15:28                   ` No Wayman
2023-07-01 15:41                     ` Eli Zaretskii
2023-07-01 19:14                       ` No Wayman
2023-07-02  5:59                         ` Eli Zaretskii
2023-07-02  6:08                           ` No Wayman
2023-07-03  8:50                           ` Andrea Corallo
2023-08-09 13:22                             ` Andrea Corallo
2023-08-09 15:24                               ` No Wayman
2023-08-09 16:29                                 ` Eli Zaretskii
2023-08-12  9:19                               ` Eli Zaretskii
2023-08-12 15:42                                 ` Andrea Corallo
2023-08-12 16:56                                   ` Andrea Corallo
2023-08-12 17:22                                     ` Eli Zaretskii
2023-06-25 14:44       ` Andrea Corallo [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=yp1ttuv7gau.fsf@fencepost.gnu.org \
    --to=acorallo@gnu.org \
    --cc=64226@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=iarchivedmywholelife@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).