From unknown Fri Jun 20 18:14:37 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#47800 <47800@debbugs.gnu.org> To: bug#47800 <47800@debbugs.gnu.org> Subject: Status: [native-comp] could not resolve realpath of "emacs" Reply-To: bug#47800 <47800@debbugs.gnu.org> Date: Sat, 21 Jun 2025 01:14:37 +0000 retitle 47800 [native-comp] could not resolve realpath of "emacs" reassign 47800 emacs submitter 47800 Dario Gjorgjevski severity 47800 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 15 10:09:37 2021 Received: (at submit) by debbugs.gnu.org; 15 Apr 2021 14:09:37 +0000 Received: from localhost ([127.0.0.1]:38789 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX2gb-0002DY-6F for submit@debbugs.gnu.org; Thu, 15 Apr 2021 10:09:37 -0400 Received: from lists.gnu.org ([209.51.188.17]:41798) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX2gW-0002DN-Dc for submit@debbugs.gnu.org; Thu, 15 Apr 2021 10:09:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:57736) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lX2gW-0007J3-8t for bug-gnu-emacs@gnu.org; Thu, 15 Apr 2021 10:09:32 -0400 Received: from mail-ej1-x633.google.com ([2a00:1450:4864:20::633]:46659) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lX2gU-0008BM-Nt for bug-gnu-emacs@gnu.org; Thu, 15 Apr 2021 10:09:32 -0400 Received: by mail-ej1-x633.google.com with SMTP id u21so37068673ejo.13 for ; Thu, 15 Apr 2021 07:09:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:mime-version; bh=EE4ZT/UZTsX1ry4cunTzOjy2jDZ08nzyEMTBqkvQh7U=; b=UPCcyYmJpg5UG47xg6PkvkivIpXrAYfPZnhGa/wcR4CfmUmQobUFbEZX7HJUKMmO1r Xw33iefh+lpz4f57v+ZmpgtYpIRbESaMQOYpuNooTbQOJGWQNsY1fg5o0sdKQlmbr9ee O4g9ioQf4/wBGWy0OPXGtbUrlpWd4Zgmze/6oe56bqL9wk123FXD1vUh7DUF1xMRuiqu aCHTFaavsURi52AVb2WucR/xdW/koolkYOSUYPs+KLrPuqmUWYzNb+KFD+QsXmqEvurV DUTI4EhD/WlV7xv4Aa0CfIqDoS1nwW1F8FK/mTiTx+PdpE26glqIbSfMBmEvPEJOquQB Z64A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=EE4ZT/UZTsX1ry4cunTzOjy2jDZ08nzyEMTBqkvQh7U=; b=Wj2VJuOWW073+KPxD/vVXS4+J6beQ04KCw95I621G4z4CGnQRG6YkdSn/dIX2oiYLs NJMB0jovtVgGpBGkeijhdZ/NDL4M2OnlNbmWimhNjFAl+PHkkpZ2GBsN5LIvjtQmKul7 xO6xDRQUmLUTLrJNghP2sRDUgzQ23PslP4AxeVSCYbS6lrNeH34h6uWZht3RbJSWcI70 zk5fyh3qsOkt+mbsU9EVXAfE6kNkk9By2EcWThj5fWAwQyckpuHcuxtYLO6XPWdTrPBp SxoNmDjfm6CF5xS1BH/0XCJS54VydbGapKbfwApCcla3NGsB6lL9O/5As9cVOKb8M/oe Kuyg== X-Gm-Message-State: AOAM531j1S1cy/Pb5GeVtim49oBXKKrAooIm8LHQwb/4CCguVY6Zt/QT 3TtnoU6LVO9acF8MQXDSX4ENfhu0Gx1TvQ== X-Google-Smtp-Source: ABdhPJxBLJVWcB//LZHHS112gqQdsDmN2uiPQq3Ro58RN6PQWUC5i84lJwe8YNxv2HE9PLs+B9OSEQ== X-Received: by 2002:a17:906:9385:: with SMTP id l5mr3663221ejx.32.1618495767566; Thu, 15 Apr 2021 07:09:27 -0700 (PDT) Received: from ZALANDO-31298 ([212.86.35.51]) by smtp.gmail.com with ESMTPSA id r10sm2030499ejd.112.2021.04.15.07.09.26 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 15 Apr 2021 07:09:26 -0700 (PDT) From: Dario Gjorgjevski To: bug-gnu-emacs@gnu.org Subject: [native-comp] could not resolve realpath of "emacs" Date: Thu, 15 Apr 2021 16:09:26 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2a00:1450:4864:20::633; envelope-from=dario.gjorgjevski@gmail.com; helo=mail-ej1-x633.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Hi, I install and symlink Emacs via Stow; i.e., Emacs is installed in $HOME/.local/stow/emacs and then stowed into $HOME/.local. Therefore, $HOME/.local/bin/emacs -> ../stow/emacs/bin/emacs $HOME/.local/libexec/emacs/28.0.50 -> ../../stow/emacs/libexec/emacs/28.0.50 and so on. Since commit 0c1fc9d, running "emacs" in the terminal gives me an error: could not resolve realpath of "emacs": No such file or directory Also, $ which emacs $HOME/.local/bin/emacs However, running "$HOME/.local/bin/emacs" works just fine, as does "$HOME/.local/stow/emacs/bin/emacs". "emacsclient" also runs fine. There are no problems prior to commit 0c1fc9d. Best regards, Dario -- $ keyserver=hkps://hkps.pool.sks-keyservers.net $ keyid=744A4F0B4F1C9371 $ gpg --keyserver $keyserver --search-keys $keyid From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 15 10:17:51 2021 Received: (at 47800) by debbugs.gnu.org; 15 Apr 2021 14:17:52 +0000 Received: from localhost ([127.0.0.1]:38804 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX2oY-0002QM-V3 for submit@debbugs.gnu.org; Thu, 15 Apr 2021 10:17:51 -0400 Received: from smtp-1.orcon.net.nz ([60.234.4.34]:35881) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX2oW-0002QD-Jz for 47800@debbugs.gnu.org; Thu, 15 Apr 2021 10:17:49 -0400 Received: from [101.53.216.162] (port=52296 helo=[192.168.20.103]) by smtp-1.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1lX2oU-0003jW-Cp; Fri, 16 Apr 2021 02:17:47 +1200 Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" To: Dario Gjorgjevski , 47800@debbugs.gnu.org References: From: Phil Sainty Message-ID: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> Date: Fri, 16 Apr 2021 02:17:46 +1200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit X-GeoIP: NZ X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: 2.9 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Hi Dario. See also: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128 Content analysis details: (2.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.34 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -0.0 NICE_REPLY_A Looks like a legit reply (A) X-Debbugs-Envelope-To: 47800 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.9 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Hi Dario. See also: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128 Content analysis details: (1.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.34 listed in list.dnswl.org] 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager -0.0 NICE_REPLY_A Looks like a legit reply (A) Hi Dario. See also: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128 From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 15 10:26:52 2021 Received: (at 47800) by debbugs.gnu.org; 15 Apr 2021 14:26:52 +0000 Received: from localhost ([127.0.0.1]:38832 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX2xI-0002fX-Hm for submit@debbugs.gnu.org; Thu, 15 Apr 2021 10:26:52 -0400 Received: from mail-ed1-f54.google.com ([209.85.208.54]:41912) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX2xG-0002fJ-71 for 47800@debbugs.gnu.org; Thu, 15 Apr 2021 10:26:51 -0400 Received: by mail-ed1-f54.google.com with SMTP id z1so28318619edb.8 for <47800@debbugs.gnu.org>; Thu, 15 Apr 2021 07:26:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=KDebPkIjP04GaqZYNtrhXrOl67VUKacySturMiDv2+Y=; b=ciyPatLpBf+KJYOfjZynfI7f54sfy8TsBSvcPueBqdaziE9bP7rX+tUm53o8tLtJft /Gwv/CKwuRLtU7CIKvHpDPN8UbhpLHmXA5B0xRh6NZM0RxRCvTI6y213ZCgtlqJczIkB gAIni3YWMsSiZS5lq7Qm+Z2W3K62DeRKrB67tIINbUvKLBU5xQJkAPNEXVL9HzmFin2S dOjxoWiyegjKzFRBKnvTzuGg6McQxne8i2c8IAwUtLQx+UFa6+kDM49ipkWew7NJhjje mBt6oPQx0JBD4UuDPXx5BaKcBoEvE1/lTRySXk/L4iCrqaDGObMYhx/yujGsEB5INSOB wu5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=KDebPkIjP04GaqZYNtrhXrOl67VUKacySturMiDv2+Y=; b=hcfScBP2WDC94Q6u2/m7TEvQ6gVCR6Hb2FmiIhlTqnDA6JI5S7ZH4om+ZTlxyDPkif e/ouFfh990qlvgzYn1UrnZ0d3g0zFVtrH8MLNIkggvUBgN9VqpqPkiXH+kit64MRZ0UK AWztyFwtm32SzGfcHx5Lov23WUjNLVW7A6B0B2qXjdMZ422ukD+WDHalNIKVk/OnzKE+ ub5q979v2VQjDC59Mk5wbWLoWPJ+tsF5UT/Sdnfy/xf/G3s+Cc3j1r2Y/YJu9WpqaaR7 0H2vBRwQDoRTkQiSYpBAJdfLt/8OGdHZQ+2GEv4ZoVzxFQp4dqGg7ZAaNHiB/Tezq/5+ jS9g== X-Gm-Message-State: AOAM532dqYUCvGoYtS4nurxdKCdfF4ehFuI+LxswqbSX/s15RsUNtt3Q Ry0oqDqLtnlcovuXsBuS7UCqKrvTd/5/tQ== X-Google-Smtp-Source: ABdhPJz0vkO0SlkthNRE+fmvBXUGu77FWujvHClt/Mvnxlcgu3zLgTHKhcC2umQ6YrwyF5B5nyOWHA== X-Received: by 2002:a50:f696:: with SMTP id d22mr4572302edn.320.1618496804342; Thu, 15 Apr 2021 07:26:44 -0700 (PDT) Received: from ZALANDO-31298 ([212.86.35.51]) by smtp.gmail.com with ESMTPSA id t1sm2623533eds.53.2021.04.15.07.26.43 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 15 Apr 2021 07:26:43 -0700 (PDT) From: Dario Gjorgjevski To: Phil Sainty Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> Date: Thu, 15 Apr 2021 16:26:43 +0200 In-Reply-To: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> (Phil Sainty's message of "Fri, 16 Apr 2021 02:17:46 +1200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) > Hi Dario. See also: > > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128 Thanks Phil. What Eli wrote in message#28 there describes the issue very well. I would also like to point out that $ cd $HOME/.local/bin $ emacs works. (Note that it's "emacs" and not "./emacs", but there are no problems with the latter either.) I guess this can be closed in favor of bug#44128. Best regards, Dario -- $ keyserver=hkps://hkps.pool.sks-keyservers.net $ keyid=744A4F0B4F1C9371 $ gpg --keyserver $keyserver --search-keys $keyid From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 15 10:44:54 2021 Received: (at 47800) by debbugs.gnu.org; 15 Apr 2021 14:44:54 +0000 Received: from localhost ([127.0.0.1]:38849 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX3Ek-00036f-0Q for submit@debbugs.gnu.org; Thu, 15 Apr 2021 10:44:54 -0400 Received: from eggs.gnu.org ([209.51.188.92]:54808) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX3Ei-00036S-0M for 47800@debbugs.gnu.org; Thu, 15 Apr 2021 10:44:52 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:37809) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lX3Ec-0004Ja-P6; Thu, 15 Apr 2021 10:44:46 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3448 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lX3Ec-0005nB-6W; Thu, 15 Apr 2021 10:44:46 -0400 Date: Thu, 15 Apr 2021 17:44:40 +0300 Message-Id: <83lf9jy5d3.fsf@gnu.org> From: Eli Zaretskii To: Dario Gjorgjevski In-Reply-To: (message from Dario Gjorgjevski on Thu, 15 Apr 2021 16:09:26 +0200) Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Dario Gjorgjevski > Date: Thu, 15 Apr 2021 16:09:26 +0200 > > I install and symlink Emacs via Stow; i.e., Emacs is installed in > $HOME/.local/stow/emacs and then stowed into $HOME/.local. Therefore, > > $HOME/.local/bin/emacs -> ../stow/emacs/bin/emacs > $HOME/.local/libexec/emacs/28.0.50 -> ../../stow/emacs/libexec/emacs/28.0.50 > > and so on. Since commit 0c1fc9d, running "emacs" in the terminal gives > me an error: > > could not resolve realpath of "emacs": No such file or directory I think this is a duplicate of bug#44128, in its latest incarnation. From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 15 11:08:24 2021 Received: (at 47800) by debbugs.gnu.org; 15 Apr 2021 15:08:24 +0000 Received: from localhost ([127.0.0.1]:38899 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX3bU-0003iF-6j for submit@debbugs.gnu.org; Thu, 15 Apr 2021 11:08:24 -0400 Received: from eggs.gnu.org ([209.51.188.92]:34198) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lX3bQ-0003i0-UJ for 47800@debbugs.gnu.org; Thu, 15 Apr 2021 11:08:22 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:38339) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lX3bL-0001Vg-O0; Thu, 15 Apr 2021 11:08:15 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:4939 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lX3bF-0005Im-Ml; Thu, 15 Apr 2021 11:08:13 -0400 Date: Thu, 15 Apr 2021 18:08:01 +0300 Message-Id: <83im4ny4a6.fsf@gnu.org> From: Eli Zaretskii To: Dario Gjorgjevski In-Reply-To: (message from Dario Gjorgjevski on Thu, 15 Apr 2021 16:26:43 +0200) Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Dario Gjorgjevski > Date: Thu, 15 Apr 2021 16:26:43 +0200 > Cc: 47800@debbugs.gnu.org > > > Hi Dario. See also: > > > > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128 > > Thanks Phil. What Eli wrote in message#28 there describes the issue > very well. Does the untested patch below fix the problem? diff --git a/src/emacs.c b/src/emacs.c index a256564..7eaaa28 100644 --- a/src/emacs.c +++ b/src/emacs.c @@ -846,7 +846,11 @@ load_pdump_find_executable (char const *argv0, ptrdiff_t *candidate_size) struct stat st; if (file_access_p (candidate, X_OK) && stat (candidate, &st) == 0 && S_ISREG (st.st_mode)) - return candidate; + { + if (lstat (candidate, &st) == 0 && S_ISLNK (st.st_mode)) + return realpath (candidate, NULL); + return candidate; + } *candidate = '\0'; } while (*path++ != '\0'); From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 04:57:34 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 08:57:34 +0000 Received: from localhost ([127.0.0.1]:40012 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKI9-00075G-TS for submit@debbugs.gnu.org; Fri, 16 Apr 2021 04:57:34 -0400 Received: from mail-ej1-f53.google.com ([209.85.218.53]:44026) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKI5-00074z-43 for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 04:57:31 -0400 Received: by mail-ej1-f53.google.com with SMTP id l4so40997941ejc.10 for <47800@debbugs.gnu.org>; Fri, 16 Apr 2021 01:57:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=KdV4BL7D6Buwb1wzF9I9853N3LQ4pAEZHQleawVhLAk=; b=n1/tHa5jqbjdqXScHQcfLga82FVoDRJh5Razx2oJftef69lib3Ld2QmTQFvsaABcv1 kqC1ccWSTXKsTbPQkX0KvGTiyhQq/qeFK7ZMOh4TVnOWWwNAL1f+ynUUXY2F89uWP9yb lxGxSd32EhibcX9sums4uPxbDPEI3ULvtubAvvRWxWdEUM9kxZzbYY24vRD8Ak/Qm5L8 39ggqAVZYYyJznqggqtYJSyo29RDX3ds8DRNwg9hj33MQkodWV4YJ2yB4oC4rm0olIl5 eS2gKGnEiTgPwtZMu3sK83HddIndtgbd/RtUGsjfNxAK/lJn6iCfpnTWIejh01GtwrZ6 1KVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=KdV4BL7D6Buwb1wzF9I9853N3LQ4pAEZHQleawVhLAk=; b=ZfKZRCexnImH783E3I4m2xMnONzUZNg65w1CbwCsw2h14oAtH/XSt0glS1n6gPwLOp frAyUUWdqQa7YLKBd4c60iEALJ5RowrsCiXo3hz79FGrGuM/aj5pmv8p+kTtM1OB4Ido CohYzVwaD3jiJi8/1MyU4Fn+0h/Z2bmvdJOyltusioHZh2RYl287tm/keOxAmxx0LaYe DgXbpUJUgjQgyWK/D8f+FSmUujBVW8Vtk7UFM0LkGCulhe63ponAMZbBpQq3vJAhNem+ T3GIH/4Mu4b4T+cuo/qHmfwwiIIcLp5+CblPaZrEkoT4LyT+i2GGRphly2HE0ENV13JN 5RyQ== X-Gm-Message-State: AOAM532UY/upxMyLSfSwEJ2SvWZvAGrR8CcJRbVJ/9CllZ9Kab7t6PLO 4PEwAQ/INMUPuMa7zLNJ1me7Z6jNAGyxIg== X-Google-Smtp-Source: ABdhPJyx07sRC8frEC3qFFTm9tr5vG7hl+H7rXLzGII/dPCjcQZefV6+1FWphJfmgvl6K297ipSA3w== X-Received: by 2002:a17:906:dfd6:: with SMTP id jt22mr7337900ejc.161.1618563443166; Fri, 16 Apr 2021 01:57:23 -0700 (PDT) Received: from ZALANDO-31298 ([79.140.121.176]) by smtp.gmail.com with ESMTPSA id e12sm4905473edv.11.2021.04.16.01.57.22 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 16 Apr 2021 01:57:22 -0700 (PDT) From: Dario Gjorgjevski To: Eli Zaretskii Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> Date: Fri, 16 Apr 2021 10:57:22 +0200 In-Reply-To: <83im4ny4a6.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 15 Apr 2021 18:08:01 +0300") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain > Does the untested patch below fix the problem? Hi Eli, Thanks for the patch. Unfortunately it does not help as the raw_name variable in set_invocation_vars is still not resolved according to PATH. The patch I am attaching to this message _does_ resolve the issue, but I am not sure about Windows. Best regards, Dario --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=resolve-raw_name.patch Content-Description: Resolve raw_name according to PATH diff --git a/src/emacs.c b/src/emacs.c index a256564..16fdc3c 100644 --- a/src/emacs.c +++ b/src/emacs.c @@ -460,8 +460,81 @@ real_filename (char *filename) return real_name; } -/* Set `invocation-name' `invocation-directory'. */ +/* Find a name (absolute or relative) of the Emacs executable whose + name (as passed into this program) is ARGV0. Called early in + initialization by portable dumper loading code, so avoid Lisp and + associated machinery. Return a heap-allocated string giving a name + of the Emacs executable, or an empty heap-allocated string or NULL + if not found. Store into *CANDIDATE_SIZE a lower bound on the size + of any heap allocation. */ +static char * +find_executable (char const *argv0, ptrdiff_t *candidate_size) +{ + *candidate_size = 0; + + /* Use xstrdup etc. to allocate storage, so as to call our private + implementation of malloc, since the caller calls our free. */ +#ifdef WINDOWSNT + char *prog_fname = w32_my_exename (); + return prog_fname ? xstrdup (prog_fname) : NULL; +#else /* !WINDOWSNT */ + char *candidate = NULL; + + /* If the executable name contains a slash, we have some kind of + path already, so just copy it. */ + eassert (argv0); + if (strchr (argv0, DIRECTORY_SEP)) + return xstrdup (argv0); + ptrdiff_t argv0_length = strlen (argv0); + + const char *path = getenv ("PATH"); + if (!path) + { + /* Default PATH is implementation-defined, so we don't know how + to conduct the search. */ + return NULL; + } + + /* Actually try each concatenation of a path element and the + executable basename. */ + do + { + static char const path_sep[] = { SEPCHAR, '\0' }; + ptrdiff_t path_part_length = strcspn (path, path_sep); + const char *path_part = path; + path += path_part_length; + if (path_part_length == 0) + { + path_part = "."; + path_part_length = 1; + } + ptrdiff_t needed = path_part_length + 1 + argv0_length + 1; + if (*candidate_size <= needed) + { + xfree (candidate); + candidate = xpalloc (NULL, candidate_size, + needed - *candidate_size + 1, -1, 1); + } + memcpy (candidate + 0, path_part, path_part_length); + candidate[path_part_length] = DIRECTORY_SEP; + memcpy (candidate + path_part_length + 1, argv0, argv0_length + 1); + struct stat st; + if (file_access_p (candidate, X_OK) + && stat (candidate, &st) == 0 && S_ISREG (st.st_mode)) + { + if (lstat (candidate, &st) == 0 && S_ISLNK (st.st_mode)) + return realpath (candidate, NULL); + return candidate; + } + *candidate = '\0'; + } + while (*path++ != '\0'); + + return candidate; +#endif /* !WINDOWSNT */ +} +/* Set `invocation-name' `invocation-directory'. */ static void set_invocation_vars (char *argv0, char const *original_pwd) { @@ -486,7 +559,9 @@ set_invocation_vars (char *argv0, char const *original_pwd) raw_name = build_unibyte_string (argv0); } #else - raw_name = build_unibyte_string (argv0); + ptrdiff_t bufsize; + char *executable = find_executable (argv0, &bufsize); + raw_name = build_unibyte_string (executable); #endif /* Add /: to the front of the name @@ -785,76 +860,6 @@ dump_error_to_string (int result) } } -/* Find a name (absolute or relative) of the Emacs executable whose - name (as passed into this program) is ARGV0. Called early in - initialization by portable dumper loading code, so avoid Lisp and - associated machinery. Return a heap-allocated string giving a name - of the Emacs executable, or an empty heap-allocated string or NULL - if not found. Store into *CANDIDATE_SIZE a lower bound on the size - of any heap allocation. */ -static char * -load_pdump_find_executable (char const *argv0, ptrdiff_t *candidate_size) -{ - *candidate_size = 0; - - /* Use xstrdup etc. to allocate storage, so as to call our private - implementation of malloc, since the caller calls our free. */ -#ifdef WINDOWSNT - char *prog_fname = w32_my_exename (); - return prog_fname ? xstrdup (prog_fname) : NULL; -#else /* !WINDOWSNT */ - char *candidate = NULL; - - /* If the executable name contains a slash, we have some kind of - path already, so just copy it. */ - eassert (argv0); - if (strchr (argv0, DIRECTORY_SEP)) - return xstrdup (argv0); - ptrdiff_t argv0_length = strlen (argv0); - - const char *path = getenv ("PATH"); - if (!path) - { - /* Default PATH is implementation-defined, so we don't know how - to conduct the search. */ - return NULL; - } - - /* Actually try each concatenation of a path element and the - executable basename. */ - do - { - static char const path_sep[] = { SEPCHAR, '\0' }; - ptrdiff_t path_part_length = strcspn (path, path_sep); - const char *path_part = path; - path += path_part_length; - if (path_part_length == 0) - { - path_part = "."; - path_part_length = 1; - } - ptrdiff_t needed = path_part_length + 1 + argv0_length + 1; - if (*candidate_size <= needed) - { - xfree (candidate); - candidate = xpalloc (NULL, candidate_size, - needed - *candidate_size + 1, -1, 1); - } - memcpy (candidate + 0, path_part, path_part_length); - candidate[path_part_length] = DIRECTORY_SEP; - memcpy (candidate + path_part_length + 1, argv0, argv0_length + 1); - struct stat st; - if (file_access_p (candidate, X_OK) - && stat (candidate, &st) == 0 && S_ISREG (st.st_mode)) - return candidate; - *candidate = '\0'; - } - while (*path++ != '\0'); - - return candidate; -#endif /* !WINDOWSNT */ -} - static void load_pdump (int argc, char **argv, char const *original_pwd) { @@ -906,7 +911,7 @@ load_pdump (int argc, char **argv, char const *original_pwd) encoding the system natively uses for filesystem access, so there's no need for character set conversion. */ ptrdiff_t bufsize; - dump_file = load_pdump_find_executable (argv[0], &bufsize); + dump_file = find_executable (argv[0], &bufsize); /* If we couldn't find our executable, go straight to looking for the dump in the hardcoded location. */ --=-=-= Content-Type: text/plain -- $ keyserver=hkps://hkps.pool.sks-keyservers.net $ keyid=744A4F0B4F1C9371 $ gpg --keyserver $keyserver --search-keys $keyid --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 05:08:16 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 09:08:16 +0000 Received: from localhost ([127.0.0.1]:40021 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKSV-0007M4-Hd for submit@debbugs.gnu.org; Fri, 16 Apr 2021 05:08:16 -0400 Received: from mail-ed1-f52.google.com ([209.85.208.52]:35472) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKST-0007Ls-Mm for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 05:08:14 -0400 Received: by mail-ed1-f52.google.com with SMTP id x4so31408457edd.2 for <47800@debbugs.gnu.org>; Fri, 16 Apr 2021 02:08:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=yTBq5OoWXs6TUEemYFUvK41MyWHqlyExdxwTmXDgmI8=; b=eupRJRs5Vhk02+Lo004RRidIyzQ6r1BfZD2088B7dWI0hya/cVPWc7e0xtDldz161i 3MzxxsulP8l9aK0rhRHuTqlfapeqd2RvRpjagXVbMwi6LTkISVg2f31+O7DJkFmZPHn7 +r1E+VjevgVmY49bZ0Qbk7z+LqgQ1uXWsw3UxDJz6LQzWz/ezkQdEY2B7QT8CgfylY1q WJwDhlxBSvtEAScHJ8KAW4hiEOBhLyBVpgIxooaMCLlYpaT084VvJTbT/JbG3WYC9kWN XGAe52/iT6vahfh8aOQvS159kFt+MJykCIsuOu0rSdR3zW/8zsr3DM8ykQW+SqQwNCg4 VGCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=yTBq5OoWXs6TUEemYFUvK41MyWHqlyExdxwTmXDgmI8=; b=My1SpDPXoVzkhiu0/wRF88g24SiXSm48KTUSK0XBSOhcMVYKGDtLIDwKRTosgzj7yl KudNELEcCW16yirdSlAWOJTNX5HRl99ssbvh+NBwkflYbY257PX+JGnxoUySVGiDVG5X LLCsCAf9IJ4piEpk8oKBNhHVmg+BmCJ7LoKncoy+CVWb1uXXcaKc84TmO3q8iXeXPLfY sPPDVqG31Z/cpgkrWy/1bGKZMy8Q5qISNsYETN+sO42ocVh2rVW1ggQfO6BePSWdLRwX QwjRWY+gToKY+OTY+IQk1CjSlaaCzuVrhLOJL2JdSL2iZ2V3BcElp7bytlNe7nAhbAYa V4zw== X-Gm-Message-State: AOAM5304Mcu8hFyKxc3PjgPuuvY6IZbx8lvhsia98GUo53zG4JpjTTXs 4/ZrGAtLWoVElv+aRvkfySk/cq/SnkqAgQ== X-Google-Smtp-Source: ABdhPJygGj5i9MlRuERCIsHH+qfFnHQ7VP6PeWUch5ODlnyAZoKg2QsHN5gyrJejuvvf10vP4JlaPQ== X-Received: by 2002:a50:ed17:: with SMTP id j23mr8584540eds.260.1618564088025; Fri, 16 Apr 2021 02:08:08 -0700 (PDT) Received: from ZALANDO-31298 ([79.140.121.176]) by smtp.gmail.com with ESMTPSA id b21sm3960554ejz.123.2021.04.16.02.08.07 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 16 Apr 2021 02:08:07 -0700 (PDT) From: Dario Gjorgjevski To: Eli Zaretskii Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> Date: Fri, 16 Apr 2021 11:08:07 +0200 In-Reply-To: (Dario Gjorgjevski's message of "Fri, 16 Apr 2021 10:57:22 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) I suppose one should also check the return value of find_executable before using it for raw_name. -- $ keyserver=hkps://hkps.pool.sks-keyservers.net $ keyid=744A4F0B4F1C9371 $ gpg --keyserver $keyserver --search-keys $keyid From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 05:23:26 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 09:23:26 +0000 Received: from localhost ([127.0.0.1]:40039 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKhC-0007in-IN for submit@debbugs.gnu.org; Fri, 16 Apr 2021 05:23:26 -0400 Received: from mail-ed1-f52.google.com ([209.85.208.52]:39642) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKh9-0007iY-N7 for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 05:23:25 -0400 Received: by mail-ed1-f52.google.com with SMTP id g17so30721758edm.6 for <47800@debbugs.gnu.org>; Fri, 16 Apr 2021 02:23:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=tbwnzuS3WnEg43eqLhyT6NJVhN3Zl3xF+u3KYKi2MHk=; b=mh/mbaEufnc5PoOYUuFb8zHPfXpRfUrTJ2IP9WQGCjnVzsUdtB7l3pAOx3POotld+m 6fylh9yiKLUEbYdCLBxLGalFxY6ny2SGxdynj7hHoU8HZ2+a4mv3AcIOtwt9slvlB64W cWXSYtG0sLCAqyRRuw4ilafiaDFwDPFLmJ8cjMfaNZy1SyWwLoW0Uory+oNIzzTrZ6CR Iyd5R4Jp+z6vSUjVPVISM/aLkHyVSxFmrUAi0PDRLE+cPu5sXihi9I8qK3ZBvz9M8als Ogxgt3LK+KA3skEV8o5r1JwdARFW9hg34uFB7fRUaTFBMBVZDRJ1/rktjlZ6k4uhEQw0 M5OA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=tbwnzuS3WnEg43eqLhyT6NJVhN3Zl3xF+u3KYKi2MHk=; b=uj22/55ACeItzlYowVaPDFE7pJWgM+M2CYovTUML5Lmo9/NM9Mm3Ji9IDqVFZwnDG2 yrm8Ml5rhTLH2g8NANjUoe3Bf0u8vEYsZpELrgEM8rVGFGNv7N8Cu0o8pqMCNm+MRxtE whbXNuLLIiHcBXi99jrNMN3HWh/3GVwm/NbsI5u+C/CG4dn5DmZUgYYSUjA1QlffOwQ6 jwM4cqD7R3ELCR+yntB5z48l0+ghRqWDnzYJ8x++i4jpigIkNJXEe97yyFo7cCp/x+g4 D4IXbttbzbTOPk7x3IB1yvJsP+b/rVb0IJkarezZCr1QVEizimyXHJBxZrLX5Q1E8N9D h1Gw== X-Gm-Message-State: AOAM533mQo5siQ6hLEJZXXldOT8eESDc7eczIydaXEUrO73+CCZ4xl8n mGILq0j5e2fTIOcAz7ujf4rqW2qF0qw+Hg== X-Google-Smtp-Source: ABdhPJxyoeXBcE/01bMTHjqz/j7dUYAT1fAW8mszAqMfdvwGEtymsmgGLkf2h+SD3b993KBfsv2DAw== X-Received: by 2002:a05:6402:17f7:: with SMTP id t23mr207326edy.76.1618564997891; Fri, 16 Apr 2021 02:23:17 -0700 (PDT) Received: from ZALANDO-31298 ([79.140.121.176]) by smtp.gmail.com with ESMTPSA id f19sm4907492edu.12.2021.04.16.02.23.17 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 16 Apr 2021 02:23:17 -0700 (PDT) From: Dario Gjorgjevski To: Eli Zaretskii Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> Date: Fri, 16 Apr 2021 11:23:17 +0200 In-Reply-To: (Dario Gjorgjevski's message of "Fri, 16 Apr 2021 11:08:07 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Also, the more I look at the patch I attached above, the worse it seems, so... But I can at least confirm that the issue is that raw_name is not resolved according to PATH prior to the call of real_filename in char *filename = real_filename (SSDATA (raw_name)); Best regards, Dario -- $ keyserver=hkps://hkps.pool.sks-keyservers.net $ keyid=744A4F0B4F1C9371 $ gpg --keyserver $keyserver --search-keys $keyid From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 05:27:53 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 09:27:54 +0000 Received: from localhost ([127.0.0.1]:40053 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKlV-0007qA-Oy for submit@debbugs.gnu.org; Fri, 16 Apr 2021 05:27:53 -0400 Received: from mx.sdf.org ([205.166.94.24]:50840) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKlU-0007q2-Kn for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 05:27:53 -0400 Received: from mab (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTPS id 13G9RpDg017663 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO); Fri, 16 Apr 2021 09:27:52 GMT From: Andrea Corallo To: Dario Gjorgjevski Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> Date: Fri, 16 Apr 2021 09:27:51 +0000 In-Reply-To: (Dario Gjorgjevski's message of "Fri, 16 Apr 2021 11:23:17 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, Eli Zaretskii , 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Dario Gjorgjevski writes: Hi Dario, thanks for the patch. > Also, the more I look at the patch I attached above, the worse it seems, > so... Why? > But I can at least confirm that the issue is that raw_name is not > resolved according to PATH prior to the call of real_filename in > > char *filename = real_filename (SSDATA (raw_name)); I agree that's the issue. Thanks Andrea From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 05:37:59 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 09:37:59 +0000 Received: from localhost ([127.0.0.1]:40058 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKvG-00085F-Nd for submit@debbugs.gnu.org; Fri, 16 Apr 2021 05:37:58 -0400 Received: from mail-ed1-f52.google.com ([209.85.208.52]:37652) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXKvE-00084z-BQ for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 05:37:58 -0400 Received: by mail-ed1-f52.google.com with SMTP id s15so31492802edd.4 for <47800@debbugs.gnu.org>; Fri, 16 Apr 2021 02:37:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=gn48ye9PZZjIY0VnBuCAcVxLaBwg7+bmW0PlgQ9Per8=; b=rmw6ocUiOhme+xmIlssG5YY2Vb/DaoydgJXIfrhLPY5JGc5ouTZdhP7BaWWMvBXZ8C EdW2reXTYhFD+lCO/RTSacObuXiTgj2Eyhkb9I3cHBxw9BOJOorGxIL0PP9WEnERGDPH 9a0TF1GUJgZp7pzOLXjHXr/+x3ZAYybmpzQlMMWBpMBmOLetqAWEmvZ389yRFbburbk5 GZWLtX5Vfm5+7YrPN/e4w6X3EOuX7eWTfsNPUCI3agaC/L4mutE/22Fvq7OvOs5DzGow ORCqjifqi2hKkGU2LDwErJOTc9PNn0iXYOCVOwB+AeYsRe+OwPvXmLIFpM8mh2osTWde 3nAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=gn48ye9PZZjIY0VnBuCAcVxLaBwg7+bmW0PlgQ9Per8=; b=IZzHG9BtEIZGTXaTVK0ihitXH00hqV4ch7mmQIdxEhxBQsSp23H5wXbaexIsCTswdR BmqFVOYcKFPdLMOGd/3fJ8U5vfOYjD0E4jc8Q5f8U/6oOPJpa/aNFv7QbvWbRV8/XMQt Nz5TIXP5IDvzM5JnYhQMd3JY+ai7no/dRI06mf863PWbCMoUWf0gT9pHWPFeDAVIcsBD 915vTZkM1Dpe+aOCOc5hz/jRNU9soHNbN1dJR0xLb4AfYGVnJ2pSbZI7B5jsc+g37TPC 7Rqm3yM9wQKtqijwMcZMZUrjnZD1GoPe1SBhZk1NtbkiojaeJMerJ3+sQs70emGfUlPy HDdQ== X-Gm-Message-State: AOAM5310e8aLT7ZxS26Ox19yAYfyCjDmxm/AGPdcjiVXf+qIVq7nHdC7 r7cHoVhH4kk+ab/y69Ff7LgSUxe73GJ189jk X-Google-Smtp-Source: ABdhPJwSBP2kT/IDoqPLkUFxjh95Nd6r08BehTsmjd4YSDUOQR6DOd7uEg2VN9irXsHHy5rdbgyjag== X-Received: by 2002:a05:6402:4314:: with SMTP id m20mr8714378edc.5.1618565870310; Fri, 16 Apr 2021 02:37:50 -0700 (PDT) Received: from ZALANDO-31298 ([79.140.121.176]) by smtp.gmail.com with ESMTPSA id v19sm3180301ejy.78.2021.04.16.02.37.49 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 16 Apr 2021 02:37:49 -0700 (PDT) From: Dario Gjorgjevski To: Andrea Corallo Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> Date: Fri, 16 Apr 2021 11:37:49 +0200 In-Reply-To: (Andrea Corallo's message of "Fri, 16 Apr 2021 09:27:51 +0000") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, Eli Zaretskii , 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Andrea, >> Also, the more I look at the patch I attached above, the worse it seems, >> so... > > Why? These are the points that make me suspicious: 1. I am not sure if the subsequent call to Ffind_file_name_handler would work correctly. 2. There is already a search over exec_path happening immediately afterwards. 3. Moreover, I am not sure what real_filename would do when a handler is found and raw_name is prefixed by slash-colon. Best regards, Dario -- $ keyserver=hkps://hkps.pool.sks-keyservers.net $ keyid=744A4F0B4F1C9371 $ gpg --keyserver $keyserver --search-keys $keyid From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 06:04:54 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 10:04:54 +0000 Received: from localhost ([127.0.0.1]:40071 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXLLJ-0000HR-QF for submit@debbugs.gnu.org; Fri, 16 Apr 2021 06:04:54 -0400 Received: from mail2.sha-bang.de ([78.47.120.114]:49916 helo=mail.sha-bang.de) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXLLG-0000HG-Um for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 06:04:52 -0400 Received: from tammy.sha-bang.de (dyndsl-089-166-178-102.ewe-ip-backbone.de [89.166.178.102]) by mail.sha-bang.de (Postfix) with ESMTPSA id A3DC1271 for <47800@debbugs.gnu.org>; Fri, 16 Apr 2021 12:04:49 +0200 (CEST) Received: by tammy.sha-bang.de (Postfix, from userid 1000) id 3BD265A79; Fri, 16 Apr 2021 11:53:58 +0200 (CEST) From: wilde@sha-bang.de To: 47800@debbugs.gnu.org Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (berkeley-unix) Date: Fri, 16 Apr 2021 11:53:58 +0200 Message-ID: <874kg6pnbd.fsf@tammy.lan.sha-bang.de> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 47800 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi *, FWIW: when /proc/self/exe exists it is a symlink to the currently running executable, that should make the implementation of find_executable() in these cases straight forward. Basically: realpath ("/proc/self/exe", NULL); should do the job. /proc/self/run exists per default on most (all?) GNU/Linux Systems and on my i386 NetBSD 9.1 per default. In case of *BSD this might be a Linux compatibility feature but I'm not sure -- needs checking. cheers sascha From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 06:57:08 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 10:57:08 +0000 Received: from localhost ([127.0.0.1]:40119 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXM9r-0001f8-T3 for submit@debbugs.gnu.org; Fri, 16 Apr 2021 06:57:08 -0400 Received: from smtp-4.orcon.net.nz ([60.234.4.59]:36749) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXM9o-0001ey-Jl for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 06:57:07 -0400 Received: from [101.53.216.162] (port=57648 helo=[192.168.20.103]) by smtp-4.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1lXM9b-00075I-LE; Fri, 16 Apr 2021 22:56:52 +1200 Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" To: Andrea Corallo References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> From: Phil Sainty Message-ID: <4f0bd59b-f669-e22d-e8c7-3325d5c45dcf@orcon.net.nz> Date: Fri, 16 Apr 2021 22:56:51 +1200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit X-GeoIP: NZ X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: 2.9 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 16/04/21 9:27 pm, Andrea Corallo wrote: > Dario Gjorgjevski writes: >> But I can at least confirm that the issue is that raw_name is not >> resolved according to PATH prior to the call of real_fi [...] Content analysis details: (2.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.59 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -0.0 NICE_REPLY_A Looks like a legit reply (A) X-Debbugs-Envelope-To: 47800 Cc: Dario Gjorgjevski , Eli Zaretskii , 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.9 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 16/04/21 9:27 pm, Andrea Corallo wrote: > Dario Gjorgjevski writes: >> But I can at least confirm that the issue is that raw_name is not >> resolved according to PATH prior to the call of real_fi [...] Content analysis details: (1.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.59 listed in list.dnswl.org] 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager -0.0 NICE_REPLY_A Looks like a legit reply (A) On 16/04/21 9:27 pm, Andrea Corallo wrote: > Dario Gjorgjevski writes: >> But I can at least confirm that the issue is that raw_name is not >> resolved according to PATH prior to the call of real_filename in >> >> char *filename = real_filename (SSDATA (raw_name)); > > I agree that's the issue. My (perhaps naive) impression is that set_invocation_vars should be using load_pdump_find_executable (or a copy of the result that it already established) to establish what argv0 is referring to? https://debbugs.gnu.org/cgi/bugreport.cgi?bug=46790#38 may have been driving at the same point. In https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128#49 I'm seeing load_pdump_find_executable successfully figuring out the genuine path to the executable every time. From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 07:32:46 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 11:32:46 +0000 Received: from localhost ([127.0.0.1]:40190 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXMiM-0004hH-1b for submit@debbugs.gnu.org; Fri, 16 Apr 2021 07:32:46 -0400 Received: from smtp-4.orcon.net.nz ([60.234.4.59]:39133) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXMiK-0004h9-GJ for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 07:32:45 -0400 Received: from [101.53.216.162] (port=4606 helo=[192.168.20.103]) by smtp-4.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1lXMiI-00004s-DX; Fri, 16 Apr 2021 23:32:43 +1200 Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" From: Phil Sainty To: Andrea Corallo References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> <4f0bd59b-f669-e22d-e8c7-3325d5c45dcf@orcon.net.nz> Message-ID: <041d8d6a-7ab2-6e26-a86f-31a82cb3a518@orcon.net.nz> Date: Fri, 16 Apr 2021 23:32:42 +1200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <4f0bd59b-f669-e22d-e8c7-3325d5c45dcf@orcon.net.nz> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit X-GeoIP: NZ X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: 2.9 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 16/04/21 10:56 pm, Phil Sainty wrote: > In https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128#49 I'm > seeing load_pdump_find_executable successfully figuring out the > genuine path to the executa [...] Content analysis details: (2.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.59 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -0.0 NICE_REPLY_A Looks like a legit reply (A) X-Debbugs-Envelope-To: 47800 Cc: Dario Gjorgjevski , 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.9 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 16/04/21 10:56 pm, Phil Sainty wrote: > In https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128#49 I'm > seeing load_pdump_find_executable successfully figuring out the > genuine path to the executa [...] Content analysis details: (1.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.59 listed in list.dnswl.org] 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager -0.0 NICE_REPLY_A Looks like a legit reply (A) On 16/04/21 10:56 pm, Phil Sainty wrote: > In https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44128#49 I'm > seeing load_pdump_find_executable successfully figuring out the > genuine path to the executable every time. Clarification: It's only figuring it out on account of Eli's patch: https://lists.gnu.org/archive/html/bug-gnu-emacs/2021-04/msg00678.html So as Eli said subsequently: "It moves one step closer, AFAICT: the real file name of the Emacs executable is now correctly identified." -- https://lists.gnu.org/archive/html/bug-gnu-emacs/2021-04/msg00715.html So IIUC, firstly we want that patch, and *then* that result can be used by set_invocation_vars ? From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 08:32:47 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 12:32:47 +0000 Received: from localhost ([127.0.0.1]:40230 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXNeR-000693-7n for submit@debbugs.gnu.org; Fri, 16 Apr 2021 08:32:47 -0400 Received: from eggs.gnu.org ([209.51.188.92]:36270) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXNeP-00068q-IO for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 08:32:46 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:39639) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXNeJ-00046s-3U; Fri, 16 Apr 2021 08:32:40 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:4246 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXNeI-0003Cz-Em; Fri, 16 Apr 2021 08:32:38 -0400 Date: Fri, 16 Apr 2021 15:32:29 +0300 Message-Id: <83tuo6wgte.fsf@gnu.org> From: Eli Zaretskii To: Andrea Corallo In-Reply-To: (message from Andrea Corallo on Fri, 16 Apr 2021 09:27:51 +0000) Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, dario.gjorgjevski@gmail.com, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Andrea Corallo > Cc: Eli Zaretskii , psainty@orcon.net.nz, 47800@debbugs.gnu.org > Date: Fri, 16 Apr 2021 09:27:51 +0000 > > > But I can at least confirm that the issue is that raw_name is not > > resolved according to PATH prior to the call of real_filename in > > > > char *filename = real_filename (SSDATA (raw_name)); > > I agree that's the issue. I think the issue is slightly more complex. Andrea, is native-compilation supported with unexec, or only with pdumper? If the former, where in the code and when do we load the preloaded *.eln files? are they dumped into the Emacs executable? If we don't support native-compilation with unexec, we should reject that combination in configure, right? From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 14:33:01 2021 Received: (at control) by debbugs.gnu.org; 16 Apr 2021 18:33:01 +0000 Received: from localhost ([127.0.0.1]:41690 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXTH2-0005Ba-PS for submit@debbugs.gnu.org; Fri, 16 Apr 2021 14:33:00 -0400 Received: from eggs.gnu.org ([209.51.188.92]:60006) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXTH0-0005BO-TB for control@debbugs.gnu.org; Fri, 16 Apr 2021 14:32:59 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:46163) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXTGv-0004lf-LZ for control@debbugs.gnu.org; Fri, 16 Apr 2021 14:32:53 -0400 Received: from rgm by fencepost.gnu.org with local (Exim 4.82) (envelope-from ) id 1lXTGl-0005dk-80 for control@debbugs.gnu.org; Fri, 16 Apr 2021 14:32:43 -0400 Subject: control message for bug 47825 To: X-Mailer: mail (GNU Mailutils 2.99.98) Message-Id: From: Glenn Morris Date: Fri, 16 Apr 2021 14:32:43 -0400 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) merge 47800 47825 From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 15:23:58 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 19:23:58 +0000 Received: from localhost ([127.0.0.1]:41725 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXU4L-0008WB-QL for submit@debbugs.gnu.org; Fri, 16 Apr 2021 15:23:58 -0400 Received: from mx.sdf.org ([205.166.94.24]:52783) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXU4I-0008W2-Sb for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 15:23:56 -0400 Received: from mab (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTPS id 13GJNp6H026190 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO); Fri, 16 Apr 2021 19:23:52 GMT From: Andrea Corallo To: Eli Zaretskii Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> <83tuo6wgte.fsf@gnu.org> Date: Fri, 16 Apr 2021 19:23:51 +0000 In-Reply-To: <83tuo6wgte.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 16 Apr 2021 15:32:29 +0300") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, dario.gjorgjevski@gmail.com, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> From: Andrea Corallo >> Cc: Eli Zaretskii , psainty@orcon.net.nz, 47800@debbugs.gnu.org >> Date: Fri, 16 Apr 2021 09:27:51 +0000 >> >> > But I can at least confirm that the issue is that raw_name is not >> > resolved according to PATH prior to the call of real_filename in >> > >> > char *filename = real_filename (SSDATA (raw_name)); >> >> I agree that's the issue. > > I think the issue is slightly more complex. That's very possible today I had really no time to reproduce and investigate this in details sorry. > Andrea, is native-compilation supported with unexec, or only with > pdumper? Only pdumper. > If the former, where in the code and when do we load the > preloaded *.eln files? are they dumped into the Emacs executable? We re-load the eln for each compilation unit around pdumper.c:5277. The position of the eln is already stored in CU object (formed in loadup.el:467). > If we don't support native-compilation with unexec, we should reject > that combination in configure, right? That's correct. Thanks Andrea From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 15:38:48 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 19:38:48 +0000 Received: from localhost ([127.0.0.1]:41735 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXUIi-0000QH-Ds for submit@debbugs.gnu.org; Fri, 16 Apr 2021 15:38:48 -0400 Received: from eggs.gnu.org ([209.51.188.92]:45802) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXUId-0000Pz-0o for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 15:38:46 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47236) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXUIV-0001Ig-7I; Fri, 16 Apr 2021 15:38:37 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2564 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXUIU-00010f-J8; Fri, 16 Apr 2021 15:38:35 -0400 Date: Fri, 16 Apr 2021 22:38:28 +0300 Message-Id: <83pmyuvx3f.fsf@gnu.org> From: Eli Zaretskii To: Andrea Corallo In-Reply-To: (message from Andrea Corallo on Fri, 16 Apr 2021 19:23:51 +0000) Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> <83tuo6wgte.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, dario.gjorgjevski@gmail.com, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Andrea Corallo > Cc: dario.gjorgjevski@gmail.com, psainty@orcon.net.nz, 47800@debbugs.gnu.org > Date: Fri, 16 Apr 2021 19:23:51 +0000 > > >> > char *filename = real_filename (SSDATA (raw_name)); > >> > >> I agree that's the issue. > > > > I think the issue is slightly more complex. > > That's very possible today I had really no time to reproduce and > investigate this in details sorry. > > > Andrea, is native-compilation supported with unexec, or only with > > pdumper? > > Only pdumper. OK, that simplifies the solution. The problem we need to solve is that we have two decisions that run in parallel, but are not really synchronized: where to look for the pdumper file and where to look for the *.eln files. These two must correspond to each other, but currently they have little in common, which is a problem waiting to bite us. The other issue is the reliance on Vinvocation_directory. To rely on it, we must change how and when it is computed, and that will most probably change its value in some use cases. So I think we need to leave the Vinvocation_directory calculation as it was before, in init_cmdargs, and use other variables to tell pdumper_load how to resolve the native-lisp directory when restoring from the pdumper file. I'm currently working on making these changes, and hope to have a solution which will solve all the known issues with symlinks etc. From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 16 16:07:05 2021 Received: (at 47800) by debbugs.gnu.org; 16 Apr 2021 20:07:05 +0000 Received: from localhost ([127.0.0.1]:41744 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXUk5-00015X-35 for submit@debbugs.gnu.org; Fri, 16 Apr 2021 16:07:05 -0400 Received: from mx.sdf.org ([205.166.94.24]:64366) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXUk2-00015P-NR for 47800@debbugs.gnu.org; Fri, 16 Apr 2021 16:07:03 -0400 Received: from mab (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTPS id 13GK71QD029273 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO); Fri, 16 Apr 2021 20:07:01 GMT From: Andrea Corallo To: Eli Zaretskii Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> <83tuo6wgte.fsf@gnu.org> <83pmyuvx3f.fsf@gnu.org> Date: Fri, 16 Apr 2021 20:07:01 +0000 In-Reply-To: <83pmyuvx3f.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 16 Apr 2021 22:38:28 +0300") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, dario.gjorgjevski@gmail.com, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> From: Andrea Corallo >> Cc: dario.gjorgjevski@gmail.com, psainty@orcon.net.nz, 47800@debbugs.gnu.org >> Date: Fri, 16 Apr 2021 19:23:51 +0000 >> >> >> > char *filename = real_filename (SSDATA (raw_name)); >> >> >> >> I agree that's the issue. >> > >> > I think the issue is slightly more complex. >> >> That's very possible today I had really no time to reproduce and >> investigate this in details sorry. >> >> > Andrea, is native-compilation supported with unexec, or only with >> > pdumper? >> >> Only pdumper. > > OK, that simplifies the solution. > > The problem we need to solve is that we have two decisions that run in > parallel, but are not really synchronized: where to look for the > pdumper file and where to look for the *.eln files. These two must > correspond to each other, but currently they have little in common, > which is a problem waiting to bite us. > > The other issue is the reliance on Vinvocation_directory. To rely on > it, we must change how and when it is computed, and that will most > probably change its value in some use cases. So I think we need to > leave the Vinvocation_directory calculation as it was before, in > init_cmdargs, and use other variables to tell pdumper_load how to > resolve the native-lisp directory when restoring from the pdumper > file. > > I'm currently working on making these changes, and hope to have a > solution which will solve all the known issues with symlinks etc. Thanks, I'm sorry in the last day I could not help more with this issue. Andrea From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 03:13:36 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 07:13:36 +0000 Received: from localhost ([127.0.0.1]:42194 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXf96-0004yt-HD for submit@debbugs.gnu.org; Sat, 17 Apr 2021 03:13:36 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50136) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXf94-0004yf-8B for 47800@debbugs.gnu.org; Sat, 17 Apr 2021 03:13:35 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:58447) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXf8x-0005w6-KX; Sat, 17 Apr 2021 03:13:27 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:1217 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXf8w-0002vU-PR; Sat, 17 Apr 2021 03:13:27 -0400 Date: Sat, 17 Apr 2021 10:13:24 +0300 Message-Id: <83k0p1wfhn.fsf@gnu.org> From: Eli Zaretskii To: Andrea Corallo In-Reply-To: (message from Andrea Corallo on Fri, 16 Apr 2021 20:07:01 +0000) Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> <83tuo6wgte.fsf@gnu.org> <83pmyuvx3f.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, dario.gjorgjevski@gmail.com, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Andrea Corallo > Cc: dario.gjorgjevski@gmail.com, psainty@orcon.net.nz, 47800@debbugs.gnu.org > Date: Fri, 16 Apr 2021 20:07:01 +0000 > > > I'm currently working on making these changes, and hope to have a > > solution which will solve all the known issues with symlinks etc. > > Thanks, I'm sorry in the last day I could not help more with this issue. That's okay, we should have done this earlier. It does mean we will postpone the merge of the branch for a few days, as I'd like to see that at least most of the issues with symlinks and other "unusual" installation methods work. From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 03:39:43 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 07:39:44 +0000 Received: from localhost ([127.0.0.1]:42208 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXfYK-0005cW-DD for submit@debbugs.gnu.org; Sat, 17 Apr 2021 03:39:43 -0400 Received: from mx.sdf.org ([205.166.94.24]:53327) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXfYF-0005cJ-2l for 47800@debbugs.gnu.org; Sat, 17 Apr 2021 03:39:39 -0400 Received: from mab (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTPS id 13H7dXs0020558 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO); Sat, 17 Apr 2021 07:39:33 GMT From: Andrea Corallo To: Eli Zaretskii Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> <83tuo6wgte.fsf@gnu.org> <83pmyuvx3f.fsf@gnu.org> <83k0p1wfhn.fsf@gnu.org> Date: Sat, 17 Apr 2021 07:39:33 +0000 In-Reply-To: <83k0p1wfhn.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 17 Apr 2021 10:13:24 +0300") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, dario.gjorgjevski@gmail.com, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> From: Andrea Corallo >> Cc: dario.gjorgjevski@gmail.com, psainty@orcon.net.nz, 47800@debbugs.gnu.org >> Date: Fri, 16 Apr 2021 20:07:01 +0000 >> >> > I'm currently working on making these changes, and hope to have a >> > solution which will solve all the known issues with symlinks etc. >> >> Thanks, I'm sorry in the last day I could not help more with this issue. > > That's okay, we should have done this earlier. It does mean we will > postpone the merge of the branch for a few days, as I'd like to see > that at least most of the issues with symlinks and other "unusual" > installation methods work. That's sensible, thanks Andrea From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 09:59:04 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 13:59:04 +0000 Received: from localhost ([127.0.0.1]:44068 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlTU-0000vL-2m for submit@debbugs.gnu.org; Sat, 17 Apr 2021 09:59:04 -0400 Received: from eggs.gnu.org ([209.51.188.92]:49046) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlTS-0000uk-VB; Sat, 17 Apr 2021 09:59:03 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:33782) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXlTL-00037F-7w; Sat, 17 Apr 2021 09:58:55 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2431 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXlTF-0001m5-R1; Sat, 17 Apr 2021 09:58:52 -0400 Date: Sat, 17 Apr 2021 16:58:40 +0300 Message-Id: <83a6pxvwq7.fsf@gnu.org> From: Eli Zaretskii To: jonas@bernoul.li, psainty@orcon.net.nz, wilde@sha-bang.de, Dario Gjorgjevski In-Reply-To: <83sg3qw9m7.fsf@gnu.org> (message from Eli Zaretskii on Fri, 16 Apr 2021 18:08:00 +0300) Subject: Re: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: 44128@debbugs.gnu.org, 47800@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Date: Fri, 16 Apr 2021 18:08:00 +0300 > From: Eli Zaretskii > Cc: psainty@orcon.net.nz, akrl@sdf.org, 44128@debbugs.gnu.org, eli@gnu.org > > > From: Jonas Bernoulli > > Date: Fri, 16 Apr 2021 15:21:47 +0200 > > Cc: 44128@debbugs.gnu.org, eli@gnu.org > > > > Andrea Corallo writes: > > > > > I've pushed 0c1fc9d581 that seams to work for me, please have a try. > > > > Unfortunately this still doesn't work (as of f9c1008ced): > > > > $ emacs > > emacs: could not resolve realpath of "emacs": No such file or directory > > $ which emacs > > /usr/local/bin/emacs > > $ ls -l /usr/local/bin/emacs > > lrwxrwxrwx 1 root staff 55 Apr 16 14:51 /usr/local/bin/emacs -> /home/jonas/git/src/emacs/feature > > > > But this works: > > > > $ /home/jonas/git/src/emacs/feature/native-comp/src/emacs > > > > And so does: > > > > $ cat /usr/local/bin/emacs > > #!/bin/sh > > /home/jonas/git/src/emacs/feature/native-comp/src/emacs "$@" > > $ emacs > > Thanks, I think I understand the issues, and I'm working on a fix. Please try the latest native-comp branch. If it still doesn't solve the problem with installing Emacs via symlinks, or if there are some adverse side-effects of the changes I made, please report the details. In a nutshell, Emacs should now decide where to look for its pdumper file and where to look for the *.eln files in a synchronized manner. I hope I got all the varieties of the symlinks involved correctly (but I couldn't test all the possible variants, only some of them). Please be sure to test both installed and uninstalled binaries, and please verify that comp-eln-load-path has the right value after Emacs loads in both cases (the last element of the list should in each case reflect where the *.eln files will be looked for). TIA From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 10:00:57 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 14:00:57 +0000 Received: from localhost ([127.0.0.1]:44075 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlVI-0000zf-V8 for submit@debbugs.gnu.org; Sat, 17 Apr 2021 10:00:57 -0400 Received: from eggs.gnu.org ([209.51.188.92]:49348) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlVG-0000zO-7W for 47800@debbugs.gnu.org; Sat, 17 Apr 2021 10:00:55 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:33826) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXlVA-0004J6-W9; Sat, 17 Apr 2021 10:00:49 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2557 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXlVA-0007FV-4F; Sat, 17 Apr 2021 10:00:48 -0400 Date: Sat, 17 Apr 2021 17:00:42 +0300 Message-Id: <838s5hvwmt.fsf@gnu.org> From: Eli Zaretskii To: wilde@sha-bang.de In-Reply-To: <874kg6pnbd.fsf@tammy.lan.sha-bang.de> (wilde@sha-bang.de) Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <874kg6pnbd.fsf@tammy.lan.sha-bang.de> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: wilde@sha-bang.de > Date: Fri, 16 Apr 2021 11:53:58 +0200 > > FWIW: when /proc/self/exe exists it is a symlink to the currently > running executable, that should make the implementation of > find_executable() in these cases straight forward. > > Basically: > realpath ("/proc/self/exe", NULL); > should do the job. This was discussed, but AFAIR people felt uneasy with using it. From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 10:13:45 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 14:13:46 +0000 Received: from localhost ([127.0.0.1]:44097 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlhh-0001JN-JB for submit@debbugs.gnu.org; Sat, 17 Apr 2021 10:13:45 -0400 Received: from smtp-1.orcon.net.nz ([60.234.4.34]:45885) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlhR-0001Iq-1u; Sat, 17 Apr 2021 10:13:44 -0400 Received: from [101.53.216.162] (port=27625 helo=[192.168.20.103]) by smtp-1.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1lXlhH-0002kl-D4; Sun, 18 Apr 2021 02:13:19 +1200 Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start To: Eli Zaretskii References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> From: Phil Sainty Message-ID: <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> Date: Sun, 18 Apr 2021 02:13:19 +1200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <83a6pxvwq7.fsf@gnu.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 8bit X-GeoIP: NZ X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, Dario Gjorgjevski , 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.9 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 18/04/21 1:58 am, Eli Zaretskii wrote: > Please try the latest native-comp branch. Unfortunately that didn't compile for me: CC emacs.o emacs.c: In function ‘load_pdump’: emacs.c:903:3: error: a label can only be part of a statement and a declaration is not a statement 903 | const char *argv0_base = "emacs"; | ^~~~~ Ma [...] Content analysis details: (1.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.34 listed in list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) -0.0 SPF_PASS SPF: sender matches SPF record -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager -0.0 NICE_REPLY_A Looks like a legit reply (A) On 18/04/21 1:58 am, Eli Zaretskii wrote: > Please try the latest native-comp branch. Unfortunately that didn't compile for me: CC emacs.o emacs.c: In function ‘load_pdump’: emacs.c:903:3: error: a label can only be part of a statement and a declaration is not a statement 903 | const char *argv0_base = "emacs"; | ^~~~~ Makefile:385: recipe for target 'emacs.o' failed make[1]: *** [emacs.o] Error 1 $ gcc --version gcc (Ubuntu 10.1.0-2ubuntu1~18.04) 10.1.0 Copyright (C) 2020 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. My 'configure' result was: Configured for 'x86_64-pc-linux-gnu'. Where should the build process find the source code? . What compiler should emacs be built with? gcc -g3 -O2 Should Emacs use the GNU version of malloc? no (The GNU allocators don't work with this system configuration.) Should Emacs use a relocating allocator for buffers? no Should Emacs use mmap(2) for buffer allocation? no What window system should Emacs use? x11 What toolkit should Emacs use? LUCID Where do we find X Windows header files? Standard dirs Where do we find X Windows libraries? Standard dirs Does Emacs use -lXaw3d? yes Does Emacs use -lXpm? yes Does Emacs use -ljpeg? yes Does Emacs use -ltiff? yes Does Emacs use a gif library? yes -lgif Does Emacs use a png library? yes -lpng16 -lz Does Emacs use -lrsvg-2? yes Does Emacs use cairo? yes Does Emacs use -llcms2? yes Does Emacs use imagemagick? no Does Emacs use native APIs for images? no Does Emacs support sound? no Does Emacs use -lgpm? no Does Emacs use -ldbus? yes Does Emacs use -lgconf? no Does Emacs use GSettings? yes Does Emacs use a file notification library? yes -lglibc (inotify) Does Emacs use access control lists? no Does Emacs use -lselinux? no Does Emacs use -lgnutls? yes Does Emacs use -lxml2? yes Does Emacs use -lfreetype? yes Does Emacs use HarfBuzz? yes Does Emacs use -lm17n-flt? no Does Emacs use -lotf? no Does Emacs use -lxft? no Does Emacs use -lsystemd? no Does Emacs use -ljansson? yes Does Emacs use the GMP library? yes Does Emacs directly use zlib? yes Does Emacs have dynamic modules support? yes Does Emacs use toolkit scroll bars? yes Does Emacs support Xwidgets? no Does Emacs have threading support in lisp? yes Does Emacs support the portable dumper? yes Does Emacs support legacy unexec dumping? no Which dumping strategy does Emacs use? pdumper Does Emacs have native lisp compiler? yes From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 10:17:19 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 14:17:19 +0000 Received: from localhost ([127.0.0.1]:44104 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXll8-0001PW-IV for submit@debbugs.gnu.org; Sat, 17 Apr 2021 10:17:19 -0400 Received: from eggs.gnu.org ([209.51.188.92]:52222) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXll6-0001PI-0n for 47800@debbugs.gnu.org; Sat, 17 Apr 2021 10:17:16 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:34073) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXlkz-0005zb-Oz; Sat, 17 Apr 2021 10:17:09 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3663 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXlkz-0004ks-83; Sat, 17 Apr 2021 10:17:09 -0400 Date: Sat, 17 Apr 2021 17:16:59 +0300 Message-Id: <835z0lvvvo.fsf@gnu.org> From: Eli Zaretskii To: Andrea Corallo In-Reply-To: (message from Andrea Corallo on Fri, 16 Apr 2021 19:23:51 +0000) Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" References: <86f92666-5978-14b7-9d55-f87cb9010f3f@orcon.net.nz> <83im4ny4a6.fsf@gnu.org> <83tuo6wgte.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: psainty@orcon.net.nz, dario.gjorgjevski@gmail.com, 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Andrea Corallo > Cc: dario.gjorgjevski@gmail.com, psainty@orcon.net.nz, 47800@debbugs.gnu.org > Date: Fri, 16 Apr 2021 19:23:51 +0000 > > > If we don't support native-compilation with unexec, we should reject > > that combination in configure, right? > > That's correct. Oh, I see we already do that. I guess that's what you were trying to say, but I misunderstood... Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 10:30:13 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 14:30:13 +0000 Received: from localhost ([127.0.0.1]:44126 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlxY-0001k6-QD for submit@debbugs.gnu.org; Sat, 17 Apr 2021 10:30:13 -0400 Received: from eggs.gnu.org ([209.51.188.92]:54650) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXlxX-0001ir-PX; Sat, 17 Apr 2021 10:30:08 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:34334) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXlxR-0005o3-AT; Sat, 17 Apr 2021 10:30:01 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:4453 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXlxP-000591-GM; Sat, 17 Apr 2021 10:30:01 -0400 Date: Sat, 17 Apr 2021 17:29:51 +0300 Message-Id: <8335vpvva8.fsf@gnu.org> From: Eli Zaretskii To: Phil Sainty In-Reply-To: <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> (message from Phil Sainty on Sun, 18 Apr 2021 02:13:19 +1200) Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Cc: jonas@bernoul.li, wilde@sha-bang.de, > Dario Gjorgjevski , 44128@debbugs.gnu.org, > 47800@debbugs.gnu.org, akrl@sdf.org > From: Phil Sainty > Date: Sun, 18 Apr 2021 02:13:19 +1200 > > CC emacs.o > emacs.c: In function ‘load_pdump’: > emacs.c:903:3: error: a label can only be part of a statement and a declaration is not a statement > 903 | const char *argv0_base = "emacs"; > | ^~~~~ > Makefile:385: recipe for target 'emacs.o' failed > make[1]: *** [emacs.o] Error 1 How about now? From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 11:00:26 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 15:00:26 +0000 Received: from localhost ([127.0.0.1]:44152 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXmQs-0002Rx-Cm for submit@debbugs.gnu.org; Sat, 17 Apr 2021 11:00:26 -0400 Received: from smtp-1.orcon.net.nz ([60.234.4.34]:57353) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXmQp-0002Rj-7r; Sat, 17 Apr 2021 11:00:23 -0400 Received: from [101.53.216.162] (port=14615 helo=[192.168.20.103]) by smtp-1.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1lXmQk-0004W5-Bu; Sun, 18 Apr 2021 03:00:18 +1200 Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start To: Eli Zaretskii References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> From: Phil Sainty Message-ID: <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> Date: Sun, 18 Apr 2021 03:00:17 +1200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <8335vpvva8.fsf@gnu.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 8bit X-GeoIP: NZ X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: 2.9 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 18/04/21 2:29 am, Eli Zaretskii wrote: > How about now? This time it compiled; but with the following warnings, and when I run it from the installed location (whether using the absolute path or a symlink) I get a seg fault / core dump: Content analysis details: (2.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.34 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -0.0 NICE_REPLY_A Looks like a legit reply (A) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.9 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 18/04/21 2:29 am, Eli Zaretskii wrote: > How about now? This time it compiled; but with the following warnings, and when I run it from the installed location (whether using the absolute path or a symlink) I get a seg fault / core dump: Content analysis details: (1.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [101.53.216.162 listed in zen.spamhaus.org] -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [60.234.4.34 listed in list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (psainty[at]orcon.net.nz) -0.0 SPF_PASS SPF: sender matches SPF record -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager -0.0 NICE_REPLY_A Looks like a legit reply (A) On 18/04/21 2:29 am, Eli Zaretskii wrote: > How about now? This time it compiled; but with the following warnings, and when I run it from the installed location (whether using the absolute path or a symlink) I get a seg fault / core dump: $ /home/phil/emacs/native-comp/usr/local/bin/emacs --version Segmentation fault (core dumped) Running the uninstalled version works: $ ./src/emacs --version GNU Emacs 28.0.50 Copyright (C) 2021 Free Software Foundation, Inc. GNU Emacs comes with ABSOLUTELY NO WARRANTY. You may redistribute copies of GNU Emacs under the terms of the GNU General Public License. For more information about these matters, see the file named COPYING. -Phil (finished for the night, but can test more tomorrow) CC emacs.o In function ‘load_pdump’, inlined from ‘main’ at emacs.c:1289:5: emacs.c:920:13: warning: argument 1 null where non-null expected [-Wnonnull] 920 | needed += strlen (strip_suffix) - strlen (suffix) + strlen (go_up); | ^~~~~~~~~~~~~~~~~~~~~ In file included from ../lib/string.h:41, from lisp.h:29, from emacs.c:33: emacs.c: In function ‘main’: /usr/include/string.h:384:15: note: in a call to function ‘strlen’ declared here 384 | extern size_t strlen (const char *__s) | ^~~~~~ In file included from /usr/include/stdio.h:862, from ../lib/stdio.h:43, from lisp.h:4731, from emacs.c:33: In function ‘sprintf’, inlined from ‘load_pdump’ at emacs.c:927:3, inlined from ‘main’ at emacs.c:1289:5: /usr/include/x86_64-linux-gnu/bits/stdio2.h:33:10: warning: ‘%s’ directive argument is null [-Wformat-overflow=] 33 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 34 | __bos (__s), __fmt, __va_arg_pack ()); | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 11:12:28 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 15:12:28 +0000 Received: from localhost ([127.0.0.1]:44159 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXmcW-0002jK-04 for submit@debbugs.gnu.org; Sat, 17 Apr 2021 11:12:28 -0400 Received: from eggs.gnu.org ([209.51.188.92]:32920) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXmcP-0002iy-TG; Sat, 17 Apr 2021 11:12:22 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:34860) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXmcI-00064k-6O; Sat, 17 Apr 2021 11:12:14 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3058 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXmcG-0007oW-Ov; Sat, 17 Apr 2021 11:12:13 -0400 Date: Sat, 17 Apr 2021 18:12:04 +0300 Message-Id: <83y2dhuerf.fsf@gnu.org> From: Eli Zaretskii To: Phil Sainty In-Reply-To: <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> (message from Phil Sainty on Sun, 18 Apr 2021 03:00:17 +1200) Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, > dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org > From: Phil Sainty > Date: Sun, 18 Apr 2021 03:00:17 +1200 > > On 18/04/21 2:29 am, Eli Zaretskii wrote: > > How about now? > > This time it compiled; but with the following warnings, and > when I run it from the installed location (whether using the > absolute path or a symlink) I get a seg fault / core dump: Sorry about that. Next try, please. From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 11:39:39 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 15:39:39 +0000 Received: from localhost ([127.0.0.1]:44173 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXn2p-0003NA-1u for submit@debbugs.gnu.org; Sat, 17 Apr 2021 11:39:39 -0400 Received: from mail-wm1-f47.google.com ([209.85.128.47]:40884) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXn2m-0003Mq-8R; Sat, 17 Apr 2021 11:39:37 -0400 Received: by mail-wm1-f47.google.com with SMTP id y124-20020a1c32820000b029010c93864955so18066263wmy.5; Sat, 17 Apr 2021 08:39:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=QmCqA0EYvYvh6d9SCu/LJWjH1AYlD6qYq2kpgfRsxVg=; b=HQM672q4E/E5VXHsP3neKaGCN4SNNBEf0pJxHvBI4mqMahMzX/H4nuuK8MzPm1I4M1 SB49XhrJdl+a4a5/doPH7RftuLILSCRfgZgWPmPCJ3drKQHKUD0IT0Mn61xKxnSf38R1 yYgzJt53lB6jZNOhja2/5rNsVZoarjb2o2RHWYZhFpy5CLfijZc8qgF+jT1f+WsZFAYM 0zqElRLJrXvDFcispxfwVM1pGYLdmFwRPLh5LLZ++dmygEI6kmtv28JD969l8kcCcu5m yuSnVNh6Ki+mX9QBnNEvbeWWj4U3J3tyeRCXuTA8utWe8VXvw4j1oSVFtd055f8PcwjI kz7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=QmCqA0EYvYvh6d9SCu/LJWjH1AYlD6qYq2kpgfRsxVg=; b=KB/dO+c7kq/bIHyHZhx157qTYZ7GT9ddrDZjDYosfX1koPYez4BTgucFODsp7d6ovG QDlzHCDZCE1ri0X55DbvKvZZY29PKRtSUf1PwkLIjxq76AAVJsEikYEizysuz0DRd8Mi /Ji6ghOFut9NrmmNj0IWfLEtnbUxPbaRGPaCjDw4rbWZqnRQD64i2m2pSr3uVOmd36C8 ADT4aZYwTyeFEpMzgb6aweivEqt1aaVUsBxa1Ee7fxLGW5Q2KDOwU/DDVDLFCNp2Tz6z 98TsBagqjYjgqLMVxJiroPcCM2Q9BAOItfM/QjqXaLUPq//uYlHIu01jW64dIvCDMqou ReMw== X-Gm-Message-State: AOAM531wmKdourQNNmcL24mtE8Ioex+r/uWYh3SNRdpFRsN7BQwpPNEH XhDzkiR4K0bokafUNeS7sBE= X-Google-Smtp-Source: ABdhPJygEvZj5KzeEiqVlwHTu+70EunLqsLMFoN9/rVgbtdIN4IRv+K7fv2B0XszzMKs3zLyx5HIVw== X-Received: by 2002:a7b:c7c8:: with SMTP id z8mr13652043wmk.112.1618673970456; Sat, 17 Apr 2021 08:39:30 -0700 (PDT) Received: from ZALANDO-31298 (p200300e97702ce9f88de2b8d6d20f032.dip0.t-ipconnect.de. [2003:e9:7702:ce9f:88de:2b8d:6d20:f032]) by smtp.gmail.com with ESMTPSA id v7sm15450437wrs.2.2021.04.17.08.39.29 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 17 Apr 2021 08:39:30 -0700 (PDT) From: Dario Gjorgjevski To: Eli Zaretskii Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> Date: Sat, 17 Apr 2021 17:39:28 +0200 In-Reply-To: <83y2dhuerf.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 17 Apr 2021 18:12:04 +0300") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, Phil Sainty , 47800@debbugs.gnu.org, wilde@sha-bang.de, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) > Sorry about that. Next try, please. Hi Eli, The most recent commit, b8d3860, works fine here. (I previously had the same segfault as Phil.) Many thanks for all your work! Best regards, Dario -- $ keyserver=hkps://hkps.pool.sks-keyservers.net $ keyid=744A4F0B4F1C9371 $ gpg --keyserver $keyserver --search-keys $keyid From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 11:49:02 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 15:49:02 +0000 Received: from localhost ([127.0.0.1]:44184 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXnBt-0003aw-H1 for submit@debbugs.gnu.org; Sat, 17 Apr 2021 11:49:02 -0400 Received: from eggs.gnu.org ([209.51.188.92]:37188) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXnBl-0003aX-1S; Sat, 17 Apr 2021 11:48:56 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:35387) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXnBc-00073O-Vo; Sat, 17 Apr 2021 11:48:45 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:1309 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXnBc-0005EI-6u; Sat, 17 Apr 2021 11:48:44 -0400 Date: Sat, 17 Apr 2021 18:48:33 +0300 Message-Id: <83wnt0vrn2.fsf@gnu.org> From: Eli Zaretskii To: Dario Gjorgjevski In-Reply-To: (message from Dario Gjorgjevski on Sat, 17 Apr 2021 17:39:28 +0200) Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, wilde@sha-bang.de, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Dario Gjorgjevski > Cc: Phil Sainty , jonas@bernoul.li, > wilde@sha-bang.de, 47800@debbugs.gnu.org, 44128@debbugs.gnu.org, > akrl@sdf.org > Date: Sat, 17 Apr 2021 17:39:28 +0200 > > The most recent commit, b8d3860, works fine here. (I previously had the > same segfault as Phil.) Great, thanks for testing. From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 15:12:53 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 19:12:53 +0000 Received: from localhost ([127.0.0.1]:44610 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqNB-0000MP-J5 for submit@debbugs.gnu.org; Sat, 17 Apr 2021 15:12:53 -0400 Received: from mail2.sha-bang.de ([78.47.120.114]:50059 helo=mail.sha-bang.de) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqN9-0000MF-1i for 47800@debbugs.gnu.org; Sat, 17 Apr 2021 15:12:52 -0400 Received: from tammy.sha-bang.de (tammy.sha-bang.de [IPv6:2001:470:69d1:bad:227:eff:fe11:1a71]) by mail.sha-bang.de (Postfix) with ESMTPSA id 44AA026F; Sat, 17 Apr 2021 21:12:49 +0200 (CEST) Received: by tammy.sha-bang.de (Postfix, from userid 1000) id 241285A79; Sat, 17 Apr 2021 21:12:48 +0200 (CEST) From: wilde@sha-bang.de To: Eli Zaretskii Subject: Re: bug#47800: [native-comp] could not resolve realpath of "emacs" In-Reply-To: <838s5hvwmt.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 17 Apr 2021 17:00:42 +0300") References: <874kg6pnbd.fsf@tammy.lan.sha-bang.de> <838s5hvwmt.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (berkeley-unix) Date: Sat, 17 Apr 2021 21:12:48 +0200 Message-ID: <87blacbu8f.fsf@tammy.lan.sha-bang.de> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 47800 Cc: 47800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii wrote: >> From: wilde@sha-bang.de >> Date: Fri, 16 Apr 2021 11:53:58 +0200 >> >> FWIW: when /proc/self/exe exists it is a symlink to the currently >> running executable, that should make the implementation of >> find_executable() in these cases straight forward. >> >> Basically: >> realpath ("/proc/self/exe", NULL); >> should do the job. > > This was discussed, but AFAIR people felt uneasy with using it. I wonder why -- but thats not too important as long as we have a reliable solution anyway. :) From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 15:15:33 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 19:15:34 +0000 Received: from localhost ([127.0.0.1]:44628 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqPl-0000Rs-Gw for submit@debbugs.gnu.org; Sat, 17 Apr 2021 15:15:33 -0400 Received: from mail2.sha-bang.de ([78.47.120.114]:50062 helo=mail.sha-bang.de) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqPd-0000RW-OY; Sat, 17 Apr 2021 15:15:29 -0400 Received: from tammy.sha-bang.de (dyndsl-089-166-176-213.ewe-ip-backbone.de [89.166.176.213]) by mail.sha-bang.de (Postfix) with ESMTPSA id 4914E26F; Sat, 17 Apr 2021 21:15:25 +0200 (CEST) Received: by tammy.sha-bang.de (Postfix, from userid 1000) id C36975A79; Sat, 17 Apr 2021 21:15:24 +0200 (CEST) From: wilde@sha-bang.de To: Eli Zaretskii Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start In-Reply-To: <83wnt0vrn2.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 17 Apr 2021 18:48:33 +0300") References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <83wnt0vrn2.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (berkeley-unix) Date: Sat, 17 Apr 2021 21:15:24 +0200 Message-ID: <877dl0bu43.fsf@tammy.lan.sha-bang.de> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, Dario Gjorgjevski , 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii wrote: >> From: Dario Gjorgjevski >> Cc: Phil Sainty , jonas@bernoul.li, >> wilde@sha-bang.de, 47800@debbugs.gnu.org, 44128@debbugs.gnu.org, >> akrl@sdf.org >> Date: Sat, 17 Apr 2021 17:39:28 +0200 >> >> The most recent commit, b8d3860, works fine here. (I previously had the >> same segfault as Phil.) > > Great, thanks for testing. I'm very happy to confirm that 75c898e (one past b8d3860) also works as expected on NetBSD 9.1. Thanks a lot for fixing this! From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 15:19:29 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 19:19:29 +0000 Received: from localhost ([127.0.0.1]:44648 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqTZ-0000Yn-B1 for submit@debbugs.gnu.org; Sat, 17 Apr 2021 15:19:29 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51752) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqTS-0000YN-UL; Sat, 17 Apr 2021 15:19:23 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:38853) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXqTN-0001uH-3w; Sat, 17 Apr 2021 15:19:17 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2533 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lXqTJ-00034k-PP; Sat, 17 Apr 2021 15:19:15 -0400 Date: Sat, 17 Apr 2021 22:18:59 +0300 Message-Id: <83h7k4vhwc.fsf@gnu.org> From: Eli Zaretskii To: wilde@sha-bang.de In-Reply-To: <877dl0bu43.fsf@tammy.lan.sha-bang.de> (wilde@sha-bang.de) Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <83wnt0vrn2.fsf@gnu.org> <877dl0bu43.fsf@tammy.lan.sha-bang.de> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: wilde@sha-bang.de > Cc: Dario Gjorgjevski , psainty@orcon.net.nz, > jonas@bernoul.li, 47800@debbugs.gnu.org, 44128@debbugs.gnu.org, > akrl@sdf.org > Date: Sat, 17 Apr 2021 21:15:24 +0200 > > Eli Zaretskii wrote: > > >> From: Dario Gjorgjevski > >> Cc: Phil Sainty , jonas@bernoul.li, > >> wilde@sha-bang.de, 47800@debbugs.gnu.org, 44128@debbugs.gnu.org, > >> akrl@sdf.org > >> Date: Sat, 17 Apr 2021 17:39:28 +0200 > >> > >> The most recent commit, b8d3860, works fine here. (I previously had the > >> same segfault as Phil.) > > > > Great, thanks for testing. > > I'm very happy to confirm that 75c898e (one past b8d3860) also works as > expected on NetBSD 9.1. Thanks for testing this. From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 15:32:35 2021 Received: (at 47800) by debbugs.gnu.org; 17 Apr 2021 19:32:35 +0000 Received: from localhost ([127.0.0.1]:44682 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqgE-0000uj-NX for submit@debbugs.gnu.org; Sat, 17 Apr 2021 15:32:34 -0400 Received: from mail2.sha-bang.de ([78.47.120.114]:50075 helo=mail.sha-bang.de) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXqg6-0000uN-2C; Sat, 17 Apr 2021 15:32:29 -0400 Received: from tammy.sha-bang.de (dyndsl-089-166-176-213.ewe-ip-backbone.de [89.166.176.213]) by mail.sha-bang.de (Postfix) with ESMTPSA id 2FE7D26F; Sat, 17 Apr 2021 21:32:24 +0200 (CEST) Received: by tammy.sha-bang.de (Postfix, from userid 1000) id BC6D95A79; Sat, 17 Apr 2021 21:32:23 +0200 (CEST) From: wilde@sha-bang.de To: Eli Zaretskii Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start In-Reply-To: <83h7k4vhwc.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 17 Apr 2021 22:18:59 +0300") References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <83wnt0vrn2.fsf@gnu.org> <877dl0bu43.fsf@tammy.lan.sha-bang.de> <83h7k4vhwc.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (berkeley-unix) Date: Sat, 17 Apr 2021 21:32:23 +0200 Message-ID: <875z0k7lmg.fsf@tammy.lan.sha-bang.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii wrote: >> From: wilde@sha-bang.de >> Cc: Dario Gjorgjevski , psainty@orcon.net.= nz, >> jonas@bernoul.li, 47800@debbugs.gnu.org, 44128@debbugs.gnu.org, >> akrl@sdf.org >> Date: Sat, 17 Apr 2021 21:15:24 +0200 >>=20 >> Eli Zaretskii wrote: >>=20 >> >> From: Dario Gjorgjevski >> >> Cc: Phil Sainty , jonas@bernoul.li, >> >> wilde@sha-bang.de, 47800@debbugs.gnu.org, 44128@debbugs.gnu.org, >> >> akrl@sdf.org >> >> Date: Sat, 17 Apr 2021 17:39:28 +0200 >> >>=20 >> >> The most recent commit, b8d3860, works fine here. (I previously had = the >> >> same segfault as Phil.) >> > >> > Great, thanks for testing. >>=20 >> I'm very happy to confirm that 75c898e (one past b8d3860) also works as >> expected on NetBSD 9.1. > > Thanks for testing this. My pleasure. However, on my test build (for this issue) on GNU/Linux unfortunately I do still see issues: # The situation after setup # (build with --prefix=3D/home/wilde/apps/emacs-native-dev and installed # with make install): % ls -l `which emacs` lrwxrwxrwx 1 wilde wilde 13 Apr 17 21:21 /home/wilde/apps/emacs-native-dev/= bin/emacs -> emacs-28.0.50* % ls -l `which emacs-28.0.50`=20 -rwxr-xr-x 1 wilde wilde 25866768 Apr 17 21:21 /home/wilde/apps/emacs-nativ= e-dev/bin/emacs-28.0.50* # The problem: % emacs=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 emacs: /home/wilde/apps/emacs-native-dev/libexec/emacs/28.0.50/x86_64-p/hom= e/wilde/apps/emacs-native-dev/libexec/emacs/28.0.50/x86_64-pc-linux-gnu/../= native-lisp/28.0.50-f13b7cda/preloaded/frame-aa2cd9f8-88c2b85c.eln: cannot = open shared object file: No such file or directory 1 wilde@marklar[~/src/stdsrc/emacs-native-comp_BUILD] # What works: % emacs-28.0.50 # =E2=86=92 emacs starts fine. FWIW, The file not found when invoked using the symlink "emasc" is at: /home/wilde/apps/emacs-native-dev/lib/emacs/28.0.50/native-lisp/28.0.50-f13= b7cda/preloaded/frame-aa2cd9f8-88c2b85c.eln cheers sascha From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 17 23:40:56 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 03:40:56 +0000 Received: from localhost ([127.0.0.1]:45017 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXyIp-0008IG-VC for submit@debbugs.gnu.org; Sat, 17 Apr 2021 23:40:56 -0400 Received: from eggs.gnu.org ([209.51.188.92]:47780) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lXyIn-0008Hx-Lw; Sat, 17 Apr 2021 23:40:54 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:45500) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXyIg-0004XJ-NW; Sat, 17 Apr 2021 23:40:46 -0400 Received: from rms by fencepost.gnu.org with local (Exim 4.82) (envelope-from ) id 1lXyId-00044h-OK; Sat, 17 Apr 2021 23:40:44 -0400 Content-Type: text/plain; charset=Utf-8 From: Richard Stallman To: Eli Zaretskii In-Reply-To: <83a6pxvwq7.fsf@gnu.org> (message from Eli Zaretskii on Sat, 17 Apr 2021 16:58:40 +0300) Subject: Re: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> Message-Id: Date: Sat, 17 Apr 2021 23:40:43 -0400 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, wilde@sha-bang.de, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: rms@gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) [[[ To any NSA and FBI agents reading my email: please consider ]]] [[[ whether defending the US Constitution against all enemies, ]]] [[[ foreign or domestic, requires you to follow Snowden's example. ]]] The version of master that I am running is from Dec 5. I always run it through a symlink. So I think the bug was introduced since then. -- Dr Richard Stallman Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org) From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 18 02:59:14 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 06:59:14 +0000 Received: from localhost ([127.0.0.1]:45176 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY1Og-00054l-92 for submit@debbugs.gnu.org; Sun, 18 Apr 2021 02:59:14 -0400 Received: from eggs.gnu.org ([209.51.188.92]:37352) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY1Of-00054V-0v; Sun, 18 Apr 2021 02:59:09 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47429) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lY1OX-0002hP-FV; Sun, 18 Apr 2021 02:59:01 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:1407 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lY1OI-0004S8-TG; Sun, 18 Apr 2021 02:58:47 -0400 Date: Sun, 18 Apr 2021 09:58:27 +0300 Message-Id: <834kg4ulik.fsf@gnu.org> From: Eli Zaretskii To: rms@gnu.org In-Reply-To: (message from Richard Stallman on Sat, 17 Apr 2021 23:40:43 -0400) Subject: Re: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, wilde@sha-bang.de, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Richard Stallman > Cc: jonas@bernoul.li, psainty@orcon.net.nz, wilde@sha-bang.de, > dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, > 47800@debbugs.gnu.org, akrl@sdf.org > Date: Sat, 17 Apr 2021 23:40:43 -0400 > > The version of master that I am running is from Dec 5. > I always run it through a symlink. > > So I think the bug was introduced since then. You are not running the native-comp branch, that's why you don't see the problem. The problem doesn't exist on the master branch, even not today. From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 18 03:40:30 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 07:40:30 +0000 Received: from localhost ([127.0.0.1]:45205 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY22g-00064y-3f for submit@debbugs.gnu.org; Sun, 18 Apr 2021 03:40:30 -0400 Received: from smtp-3.orcon.net.nz ([60.234.4.44]:43085) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY22d-00064k-WC; Sun, 18 Apr 2021 03:40:28 -0400 Received: from [101.53.216.162] (port=55237 helo=[192.168.20.103]) by smtp-3.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1lY22W-00032y-Lv; Sun, 18 Apr 2021 19:40:20 +1200 Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start From: Phil Sainty To: Eli Zaretskii References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> Message-ID: Date: Sun, 18 Apr 2021 19:40:20 +1200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit X-GeoIP: NZ X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Thank you Eli, this looks good to me too. I tested with the following set of symlinks: /home/phil/bin/emacs -> /home/phil/emacs/native-comp/usr/local/bin/emacs /home/phil/bin/emacs-native-comp -> /home/phil/emacs/native-comp/usr/local/bin/emacs /home/phil/bin/emacs-28.0.50 -> /home/phil/emacs/native-comp/usr/local/bin/emacs-28.0.50 /home/phil/bin/emacs-native-comp-28.0.50 -> /home/phil/emacs/native-comp/usr/local/bin/emacs-28.0.50 /home/phil/bin/emacs-native-comp-uninstalled -> /home/phil/emacs/native-comp/shallow-repository/src/emacs For each of those symlinks, and also the absolute paths for the link targets, I tested running them from multiple directories. These included the directories of the real binaries, plus two other directories containing a file or sub-directory named 'emacs': drwxrwxr-x 25 phil phil 4096 Mar 28 23:30 /home/phil/emacs -rw-rw-r-- 1 phil phil 0 Apr 18 11:34 /tmp/emacs In each test I ran --batch --eval "(prin1 comp-eln-load-path)" $ (for dir in / /home /home/phil /home/phil/bin /home/phil/emacs /home/phil/emacs/native-comp/usr/local/bin /home/phil/emacs/native-comp/shallow-repository/src /tmp; do echo; echo $dir; cd $dir; for E in emacs emacs-native-comp emacs-28.0.50 emacs-native-comp-28.0.50 /home/phil/emacs/native-comp/usr/local/bin/emacs /home/phil/emacs/native-comp/usr/local/bin/emacs-28.0.50 emacs-native-comp-uninstalled /home/phil/emacs/native-comp/shallow-repository/src/emacs; do $E --batch --eval "(prin1 comp-eln-load-path)"; echo " -- $E"; done; done) Nothing failed, and for every directory the output was the same: ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs-native-comp ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs-28.0.50 ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs-native-comp-28.0.50 ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- /home/phil/emacs/native-comp/usr/local/bin/emacs ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- /home/phil/emacs/native-comp/usr/local/bin/emacs-28.0.50 ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/shallow-repository/native-lisp/") -- emacs-native-comp-uninstalled ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/shallow-repository/native-lisp/") -- /home/phil/emacs/native-comp/shallow-repository/src/emacs -Phil From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 18 04:10:33 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 08:10:34 +0000 Received: from localhost ([127.0.0.1]:45227 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY2Vh-0006n0-JM for submit@debbugs.gnu.org; Sun, 18 Apr 2021 04:10:33 -0400 Received: from eggs.gnu.org ([209.51.188.92]:43730) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY2Vb-0006md-U7; Sun, 18 Apr 2021 04:10:24 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47875) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lY2VU-0002rS-Lv; Sun, 18 Apr 2021 04:10:16 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:1802 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lY2VT-0004IE-Od; Sun, 18 Apr 2021 04:10:16 -0400 Date: Sun, 18 Apr 2021 11:09:56 +0300 Message-Id: <83y2dgt3mz.fsf@gnu.org> From: Eli Zaretskii To: Phil Sainty In-Reply-To: (message from Phil Sainty on Sun, 18 Apr 2021 19:40:20 +1200) Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Phil Sainty > Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, > dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org > Date: Sun, 18 Apr 2021 19:40:20 +1200 > > $ (for dir in / /home /home/phil /home/phil/bin /home/phil/emacs /home/phil/emacs/native-comp/usr/local/bin /home/phil/emacs/native-comp/shallow-repository/src /tmp; do echo; echo $dir; cd $dir; for E in emacs emacs-native-comp emacs-28.0.50 emacs-native-comp-28.0.50 /home/phil/emacs/native-comp/usr/local/bin/emacs /home/phil/emacs/native-comp/usr/local/bin/emacs-28.0.50 emacs-native-comp-uninstalled /home/phil/emacs/native-comp/shallow-repository/src/emacs; do $E --batch --eval "(prin1 comp-eln-load-path)"; echo " -- $E"; done; done) > > Nothing failed, and for every directory the output was the same: > > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs-native-comp > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs-28.0.50 > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- emacs-native-comp-28.0.50 > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- /home/phil/emacs/native-comp/usr/local/bin/emacs > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/usr/local/lib/emacs/28.0.50/native-lisp/") -- /home/phil/emacs/native-comp/usr/local/bin/emacs-28.0.50 > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/shallow-repository/native-lisp/") -- emacs-native-comp-uninstalled > ("/home/phil/.emacs.d/eln-cache/" "/home/phil/emacs/native-comp/shallow-repository/native-lisp/") -- /home/phil/emacs/native-comp/shallow-repository/src/emacs Thanks for testing, this looks very promising. From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 18 04:43:09 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 08:43:09 +0000 Received: from localhost ([127.0.0.1]:45266 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY31J-0001Il-Gp for submit@debbugs.gnu.org; Sun, 18 Apr 2021 04:43:09 -0400 Received: from eggs.gnu.org ([209.51.188.92]:47614) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY31C-0001I8-Up; Sun, 18 Apr 2021 04:43:03 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:48277) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lY314-00067x-W8; Sun, 18 Apr 2021 04:42:55 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3852 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lY313-0007pP-T6; Sun, 18 Apr 2021 04:42:54 -0400 Date: Sun, 18 Apr 2021 11:42:32 +0300 Message-Id: <83wnt0t24n.fsf@gnu.org> From: Eli Zaretskii To: wilde@sha-bang.de In-Reply-To: <875z0k7lmg.fsf@tammy.lan.sha-bang.de> (wilde@sha-bang.de) Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <83wnt0vrn2.fsf@gnu.org> <877dl0bu43.fsf@tammy.lan.sha-bang.de> <83h7k4vhwc.fsf@gnu.org> <875z0k7lmg.fsf@tammy.lan.sha-bang.de> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: wilde@sha-bang.de > Cc: dario.gjorgjevski@gmail.com, psainty@orcon.net.nz, jonas@bernoul.li, > 47800@debbugs.gnu.org, 44128@debbugs.gnu.org, akrl@sdf.org > Date: Sat, 17 Apr 2021 21:32:23 +0200 > > % ls -l `which emacs` > lrwxrwxrwx 1 wilde wilde 13 Apr 17 21:21 /home/wilde/apps/emacs-native-dev/bin/emacs -> emacs-28.0.50* > % ls -l `which emacs-28.0.50` > -rwxr-xr-x 1 wilde wilde 25866768 Apr 17 21:21 /home/wilde/apps/emacs-native-dev/bin/emacs-28.0.50* > > # The problem: > > % emacs > emacs: /home/wilde/apps/emacs-native-dev/libexec/emacs/28.0.50/x86_64-p/home/wilde/apps/emacs-native-dev/libexec/emacs/28.0.50/x86_64-pc-linux-gnu/../native-lisp/28.0.50-f13b7cda/preloaded/frame-aa2cd9f8-88c2b85c.eln: cannot open shared object file: No such file or directory There's something here that I'm missing. The file name it tries is clearly a result of some invalid concatenation of string, but I don't quite see how that could happen. Can you step through the code with GDB? If yes, I will ask to show values of some variables, and that will hopefully pinpoint the buggy code. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 18 05:02:24 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 09:02:24 +0000 Received: from localhost ([127.0.0.1]:45288 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY3Jw-0001mJ-1z for submit@debbugs.gnu.org; Sun, 18 Apr 2021 05:02:24 -0400 Received: from eggs.gnu.org ([209.51.188.92]:49872) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY3Ju-0001m2-H1; Sun, 18 Apr 2021 05:02:23 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:48380) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lY3Jn-0000tG-CD; Sun, 18 Apr 2021 05:02:15 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:1076 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lY3Jm-0001zX-Ay; Sun, 18 Apr 2021 05:02:14 -0400 Date: Sun, 18 Apr 2021 12:01:54 +0300 Message-Id: <83v98kt18d.fsf@gnu.org> From: Eli Zaretskii To: wilde@sha-bang.de In-Reply-To: <83wnt0t24n.fsf@gnu.org> (message from Eli Zaretskii on Sun, 18 Apr 2021 11:42:32 +0300) Subject: Re: bug#44128: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <83wnt0vrn2.fsf@gnu.org> <877dl0bu43.fsf@tammy.lan.sha-bang.de> <83h7k4vhwc.fsf@gnu.org> <875z0k7lmg.fsf@tammy.lan.sha-bang.de> <83wnt0t24n.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Date: Sun, 18 Apr 2021 11:42:32 +0300 > From: Eli Zaretskii > Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, > dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org > > Can you step through the code with GDB? If yes, I will ask to show > values of some variables, and that will hopefully pinpoint the buggy > code. But before you do anything else, please try the latest branch, where I fixed some thinko. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 18 08:24:20 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 12:24:20 +0000 Received: from localhost ([127.0.0.1]:45656 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY6TM-000793-2Y for submit@debbugs.gnu.org; Sun, 18 Apr 2021 08:24:20 -0400 Received: from mail2.sha-bang.de ([78.47.120.114]:50127 helo=mail.sha-bang.de) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY6TK-00078p-7U; Sun, 18 Apr 2021 08:24:19 -0400 Received: from tammy.sha-bang.de (dyndsl-188-118-148-253.ewe-ip-backbone.de [188.118.148.253]) by mail.sha-bang.de (Postfix) with ESMTPSA id 6C88726F; Sun, 18 Apr 2021 14:24:16 +0200 (CEST) Received: by tammy.sha-bang.de (Postfix, from userid 1000) id CB8C45A79; Sun, 18 Apr 2021 14:24:15 +0200 (CEST) From: wilde@sha-bang.de To: Eli Zaretskii Subject: Re: bug#44128: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start In-Reply-To: <83v98kt18d.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 18 Apr 2021 12:01:54 +0300") References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <83wnt0vrn2.fsf@gnu.org> <877dl0bu43.fsf@tammy.lan.sha-bang.de> <83h7k4vhwc.fsf@gnu.org> <875z0k7lmg.fsf@tammy.lan.sha-bang.de> <83wnt0t24n.fsf@gnu.org> <83v98kt18d.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (berkeley-unix) Date: Sun, 18 Apr 2021 14:24:15 +0200 Message-ID: <87lf9f4w7k.fsf@tammy.lan.sha-bang.de> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii wrote: >> Date: Sun, 18 Apr 2021 11:42:32 +0300 >> From: Eli Zaretskii >> Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, >> dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org >> >> Can you step through the code with GDB? If yes, I will ask to show >> values of some variables, and that will hopefully pinpoint the buggy >> code. > > But before you do anything else, please try the latest branch, where I > fixed some thinko. That latest change fixed it for me. Once again, may thanks for your work! cheers sascha From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 18 09:01:25 2021 Received: (at 47800) by debbugs.gnu.org; 18 Apr 2021 13:01:26 +0000 Received: from localhost ([127.0.0.1]:45678 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY73F-00082M-Gn for submit@debbugs.gnu.org; Sun, 18 Apr 2021 09:01:25 -0400 Received: from eggs.gnu.org ([209.51.188.92]:58710) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY730-00081q-L8; Sun, 18 Apr 2021 09:01:11 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:50958) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lY72s-0004S1-PR; Sun, 18 Apr 2021 09:01:02 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:4245 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lY72r-0008NE-1W; Sun, 18 Apr 2021 09:01:02 -0400 Date: Sun, 18 Apr 2021 16:00:39 +0300 Message-Id: <83pmyru4qw.fsf@gnu.org> From: Eli Zaretskii To: wilde@sha-bang.de In-Reply-To: <87lf9f4w7k.fsf@tammy.lan.sha-bang.de> (wilde@sha-bang.de) Subject: Re: bug#44128: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <83wnt0vrn2.fsf@gnu.org> <877dl0bu43.fsf@tammy.lan.sha-bang.de> <83h7k4vhwc.fsf@gnu.org> <875z0k7lmg.fsf@tammy.lan.sha-bang.de> <83wnt0t24n.fsf@gnu.org> <83v98kt18d.fsf@gnu.org> <87lf9f4w7k.fsf@tammy.lan.sha-bang.de> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: wilde@sha-bang.de > Cc: jonas@bernoul.li, psainty@orcon.net.nz, 47800@debbugs.gnu.org, > dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org > Date: Sun, 18 Apr 2021 14:24:15 +0200 > > > But before you do anything else, please try the latest branch, where I > > fixed some thinko. > > That latest change fixed it for me. Great, then I think we are good. I just hope Jonas will be able to test in his configuration as well. From debbugs-submit-bounces@debbugs.gnu.org Mon Apr 19 10:37:53 2021 Received: (at 47800) by debbugs.gnu.org; 19 Apr 2021 14:37:53 +0000 Received: from localhost ([127.0.0.1]:51533 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lYV29-0008C3-0V for submit@debbugs.gnu.org; Mon, 19 Apr 2021 10:37:53 -0400 Received: from mail.hostpark.net ([212.243.197.30]:59500) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lYV23-0008Bj-2p; Mon, 19 Apr 2021 10:37:51 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.hostpark.net (Postfix) with ESMTP id 6F1AF165CD; Mon, 19 Apr 2021 16:37:45 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=bernoul.li; h= content-type:content-type:mime-version:message-id:date:date :references:in-reply-to:subject:subject:from:from:received :received; s=sel2011a; t=1618843063; bh=oNa6gFZcAbGBw9lOARImUPZA UZkMYxKOyoOW/RTw9+A=; b=Qjv4nwwPZQJMMlYfFdFiv3SeVKFd8TyttvAre72Z DgUTpuemw2FpaOXJCi6ezybfUgPCUMahEJczE8DNWyXlH2Zg74Nylx4GmCIFZGnx /ZuYCcsexS/LYVapAp4KsFfAwwJr3H0xnUBP6/3gx0foZtf25++JTDGfjpWH7lDy FDQ= X-Virus-Scanned: by Hostpark/NetZone Mailprotection at hostpark.net Received: from mail.hostpark.net ([127.0.0.1]) by localhost (mail0.hostpark.net [127.0.0.1]) (amavisd-new, port 10224) with ESMTP id QGiooBw8XeR9; Mon, 19 Apr 2021 16:37:43 +0200 (CEST) Received: from customer (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.hostpark.net (Postfix) with ESMTPSA id 3A038165D6; Mon, 19 Apr 2021 16:37:43 +0200 (CEST) From: Jonas Bernoulli To: Eli Zaretskii , Phil Sainty Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start In-Reply-To: <83y2dhuerf.fsf@gnu.org> References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> Date: Mon, 19 Apr 2021 16:37:41 +0200 Message-ID: <87fszmibm2.fsf@bernoul.li> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800 Cc: wilde@sha-bang.de, dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, 47800@debbugs.gnu.org, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Eli Zaretskii writes: >> Cc: jonas@bernoul.li, wilde@sha-bang.de, 47800@debbugs.gnu.org, >> dario.gjorgjevski@gmail.com, 44128@debbugs.gnu.org, akrl@sdf.org >> From: Phil Sainty >> Date: Sun, 18 Apr 2021 03:00:17 +1200 >> >> On 18/04/21 2:29 am, Eli Zaretskii wrote: >> > How about now? >> >> This time it compiled; but with the following warnings, and >> when I run it from the installed location (whether using the >> absolute path or a symlink) I get a seg fault / core dump: > > Sorry about that. Next try, please. Now it works for me too. Thanks! From debbugs-submit-bounces@debbugs.gnu.org Mon Apr 19 10:52:30 2021 Received: (at 47800-done) by debbugs.gnu.org; 19 Apr 2021 14:52:30 +0000 Received: from localhost ([127.0.0.1]:51594 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lYVGI-0000A3-0U for submit@debbugs.gnu.org; Mon, 19 Apr 2021 10:52:30 -0400 Received: from eggs.gnu.org ([209.51.188.92]:59496) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lYVGG-00009k-R5; Mon, 19 Apr 2021 10:52:29 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:42416) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lYVG8-0005Tk-Q0; Mon, 19 Apr 2021 10:52:20 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:4604 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1lYVG8-0006Qs-5e; Mon, 19 Apr 2021 10:52:20 -0400 Date: Mon, 19 Apr 2021 17:52:02 +0300 Message-Id: <83im4is4x9.fsf@gnu.org> From: Eli Zaretskii To: Jonas Bernoulli In-Reply-To: <87fszmibm2.fsf@bernoul.li> (message from Jonas Bernoulli on Mon, 19 Apr 2021 16:37:41 +0200) Subject: Re: bug#47800: bug#44128: [feature/native-comp] When invoking a symlink to the 'emacs' binary Emacs fails to start References: <87eelri6l8.fsf@bernoul.li> <87k0p2xt3o.fsf@bernoul.li> <83sg3qw9m7.fsf@gnu.org> <83a6pxvwq7.fsf@gnu.org> <51b70f75-1e60-7f0f-2614-923bc1b3ba6b@orcon.net.nz> <8335vpvva8.fsf@gnu.org> <22f456c6-459f-d928-59e3-7616896ffac6@orcon.net.nz> <83y2dhuerf.fsf@gnu.org> <87fszmibm2.fsf@bernoul.li> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 47800-done Cc: 44128-done@debbugs.gnu.org, 47800-done@debbugs.gnu.org, psainty@orcon.net.nz, wilde@sha-bang.de, dario.gjorgjevski@gmail.com, akrl@sdf.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > >> This time it compiled; but with the following warnings, and > >> when I run it from the installed location (whether using the > >> absolute path or a symlink) I get a seg fault / core dump: > > > > Sorry about that. Next try, please. > > Now it works for me too. > Thanks! Thanks, so I think we can close this issue now. Thanks to everybody who reported their results and tried my buggy code. From unknown Fri Jun 20 18:14:37 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 18 May 2021 11:24:03 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator