From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#59424: bug#59358: 29.0.50; failing to load .eln for init file sets user-init-file to warnings.el Date: Sun, 27 Nov 2022 21:26:11 +0200 Message-ID: <838rjwp5bg.fsf@gnu.org> References: <834juwbasq.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30535"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 59424@debbugs.gnu.org, akrl@sdf.org To: Juanma Barranquero Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Nov 27 20:26:23 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ozNIE-0007k9-Ku for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 27 Nov 2022 20:26:22 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ozNHz-0001TY-Mg; Sun, 27 Nov 2022 14:26:07 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ozNHw-0001T8-UJ for bug-gnu-emacs@gnu.org; Sun, 27 Nov 2022 14:26:05 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ozNHw-0001gS-IN for bug-gnu-emacs@gnu.org; Sun, 27 Nov 2022 14:26:04 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ozNHu-0008D2-Gd for bug-gnu-emacs@gnu.org; Sun, 27 Nov 2022 14:26:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 27 Nov 2022 19:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 59424 X-GNU-PR-Package: emacs Original-Received: via spool by 59424-submit@debbugs.gnu.org id=B59424.166957715731550 (code B ref 59424); Sun, 27 Nov 2022 19:26:02 +0000 Original-Received: (at 59424) by debbugs.gnu.org; 27 Nov 2022 19:25:57 +0000 Original-Received: from localhost ([127.0.0.1]:43813 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ozNHo-0008Co-Nr for submit@debbugs.gnu.org; Sun, 27 Nov 2022 14:25:57 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:52928) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ozNHm-0008Ci-RE for 59424@debbugs.gnu.org; Sun, 27 Nov 2022 14:25:55 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ozNHe-0001fv-66; Sun, 27 Nov 2022 14:25:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=miOxKyWwcbzGvrZB96dzOu9M7XJzZ+zl5i0PK4KMD18=; b=Kgn0nB8rq9Tc N157+I49hlO/l2nsKbDxh26A/jwl3xPQJxpL8gZUWW0NSy/IFhVDgtCYwswZWFcZizl1StSTXvVlP EJyJVbqjF29MEYOTp6SRDU2rdg7Io1U9PHC/52FEw3QYLHyELmS+EtHVSZh1fxx/lLtoE952HBGbc jDf2QqNLOgDqFLYHZO7g8BX/KTuCnM8pRKQGcRz3uDffZ0Xf70e92O0zgRLpJ3XH4HOHh6KwcGQ0Q LK3R/aDYWO3ArXDgMgqcsL8iCb7h3k2F5rGpywi/X//5OrrQjbEnfYmuV5W80q6xFUKcpmR/1s2CG JIc/MGrlPzbqwK6oNoz6ug==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ozNHc-0001S5-M0; Sun, 27 Nov 2022 14:25:45 -0500 In-Reply-To: (message from Juanma Barranquero on Sun, 27 Nov 2022 20:01:25 +0100) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:249243 Archived-At: > From: Juanma Barranquero > Date: Sun, 27 Nov 2022 20:01:25 +0100 > Cc: 59424@debbugs.gnu.org > > On Fri, Nov 18, 2022 at 3:24 PM Eli Zaretskii wrote: > > I think the solution to that is to special-case ".emacs", in > maybe_swap_for_eln, as a file name that doesn't have to have the .el > extension for this purpose. > > I've been fiddling with maybe_swap_for_eln for a while to try to special-case .emacs and make comp > native-compile it, but I reached a point where it was getting a bit out of hand in the kludgey department. > > I think that's better implemented by someone more knowledgeable with the native-compiler machinery. I'm probably missing something, because it looks like this is the place to do it: /* Search eln in the eln-cache directories. */ Lisp_Object eln_path_tail = Vnative_comp_eln_load_path; Lisp_Object src_name = Fsubstring (*filename, Qnil, make_fixnum (-1)); <<<<<<<<<<<<<<<< The idea is to use Fsubstring (*filename, Qnil, make_fixnum (-3)) instead of the above if '*filename' ends in ".emacs.elc" (which you can establish by using the same suffix_p that is used above this code to verify the ".elc" extension). But since you say there's more here than meets the eye, I'm wondering what did I miss?