From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Wilhelm Kirschbaum Newsgroups: gmane.emacs.bugs Subject: bug#49864: 28.0.50; Fails to start after "make install" Date: Thu, 5 Aug 2021 17:21:36 +0200 Message-ID: References: <83r1f9l8xu.fsf@gnu.org> <83pmusjsfg.fsf@gnu.org> <83o8acjrky.fsf@gnu.org> <83mtpwjpa7.fsf@gnu.org> <83im0kj9ry.fsf@gnu.org> <83h7g4j8dj.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000040464f05c8d17aba" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33715"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 49864@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Aug 05 17:22:12 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mBfCF-0008Y9-MP for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 05 Aug 2021 17:22:11 +0200 Original-Received: from localhost ([::1]:53652 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mBfCE-0000yv-JP for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 05 Aug 2021 11:22:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:43792) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mBfC6-0000ut-Vg for bug-gnu-emacs@gnu.org; Thu, 05 Aug 2021 11:22:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:36557) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mBfC6-0001lW-38 for bug-gnu-emacs@gnu.org; Thu, 05 Aug 2021 11:22:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mBfC5-0000U6-VK for bug-gnu-emacs@gnu.org; Thu, 05 Aug 2021 11:22:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Wilhelm Kirschbaum Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 05 Aug 2021 15:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49864 X-GNU-PR-Package: emacs Original-Received: via spool by 49864-submit@debbugs.gnu.org id=B49864.16281769161848 (code B ref 49864); Thu, 05 Aug 2021 15:22:01 +0000 Original-Received: (at 49864) by debbugs.gnu.org; 5 Aug 2021 15:21:56 +0000 Original-Received: from localhost ([127.0.0.1]:48103 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBfBz-0000Th-Je for submit@debbugs.gnu.org; Thu, 05 Aug 2021 11:21:56 -0400 Original-Received: from mail-lf1-f54.google.com ([209.85.167.54]:39590) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBfBy-0000TV-HO for 49864@debbugs.gnu.org; Thu, 05 Aug 2021 11:21:55 -0400 Original-Received: by mail-lf1-f54.google.com with SMTP id t9so11842924lfc.6 for <49864@debbugs.gnu.org>; Thu, 05 Aug 2021 08:21:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=lZ9OoC1VlVvSKX/DYEUz/GAQqAVajt4Q8PIPVBxi7MQ=; b=fAher7ueIuvA9iUanrTSB8pz0oLO7C5bze81xIHGBJUVzLDHl3xNLASt44TJVKGk84 vAHtU9FxkGBcOt2+yISk/VATzvJdVXj0vng6AVDClnRxcwVpP6TjPsrBb0u4lv8yHRun UAWyHkjorqmr1elPWD4ntJItk47Yw3KP4Xz2ih6XBjBK5qXXOiVwCEMJlHyg6N82sNBl E2rVojv9NjrL67bFaAXqExmJo/mdrV5l89h0okBPdzfyO1TNePggglfjf7hyTXtfQcHz EyVsU679zmZQDFcX5MKXsA1c2ayQfoxKYl3FBekM+k/3Kb29fUPOn8VCdUq5kmeoPr6L C2Og== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=lZ9OoC1VlVvSKX/DYEUz/GAQqAVajt4Q8PIPVBxi7MQ=; b=BosXJ+2dGCCtXdaXoWcJSRnv9W3iPs2ATasfR3/7QT6d9VLEmJ6LgnRVl1IKLSLHP2 mFBw2BOuXF+ZJKziiABbGeptgIA/1GRv+pGLALWpPdDSZpA1uDblgwHMIZ0PTxZG6J0g 5hcHRc0YHHVfZsNixR2buf/17P16sG+RpLMQZtRsjwvE8tnyXVG1gyV0PPKp8TRsEhVa 202Vx8Wp5JV9LlQOlhV8nMHFu96fBo3SEE+EuAsFG+2gQ/a0hTlmEnU1nndqYT0CH94e xD9ClTlS0g4Uc14F35aCIfjI3qyWoDpSEnPNTy1/M9KQfD1BuxTgMuxz/L37+qzGBSVH OSbg== X-Gm-Message-State: AOAM531uuKCUEGsVXWnPu3JYUPx9qoLMcNTJIqAsSL1rD3fyqMMJgalA yLRsmNL3T70VxckiUdjCetwuGRs5iSenZvYPecc= X-Google-Smtp-Source: ABdhPJy80uEX0LZPCx+LD0MtYDjHz9Es84wdBysy1VKyB04/yjcdkFTMYuftubCK9K2GNer8h5IfdQgFu3q9MjAbUMs= X-Received: by 2002:a05:6512:1084:: with SMTP id j4mr4243586lfg.586.1628176908304; Thu, 05 Aug 2021 08:21:48 -0700 (PDT) In-Reply-To: <83h7g4j8dj.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:211243 Archived-At: --00000000000040464f05c8d17aba Content-Type: text/plain; charset="UTF-8" Thanks for your patience, I appreciate the effort trying to solve this. Here is the gdb log: 1561 return XSTRING (string)->u.s.data; (gdb) n 5321 if (file_access_p (fndata, F_OK)) (gdb) step file_access_p ( file=file@entry=0x555555cf8838 "/usr/local/libexec/emacs/28.0.50/x86_64-pc-linux-gnu/../../../../bin/../lib/emacs/28.0.50/native-lisp/28.0.50-864bf4e5/preloaded/window-0d1b8b93-dcb2375f.eln", amode=amode@entry=0) at fileio.c:162 162 if (faccessat (AT_FDCWD, file, amode, AT_EACCESS) == 0) (gdb) next dump_do_dump_relocation (dump_base=, reloc=...) at pdumper.c:5325 5325 eln_fname = make_uninit_string (execdir_len + fn2_len); (gdb) p (int)errno $1 = 13 I can indeed access /usr/local/libexec/emacs/28.0.50/x86_64-pc-linux-gnu/../../../../bin/../lib/emacs/28.0.50/native-lisp/28.0.50-864bf4e5/preloaded/window-0d1b8b93-dcb2375f.eln but only as root. Which seems wrong. I can start emacs as sudo ( have not even checked this before ) Which is then probably a umask issue as this folder's permission seems wrong: /usr/local/lib $ sudo ls -lah emacs total 12K drwx------ 3 root root 4.0K Aug 3 23:00 . drwxr-xr-x 4 root root 4.0K Aug 3 23:00 .. drwx------ 3 root root 4.0K Aug 3 23:00 28.0.50 sudo ls -lah emacs/28.0.50 total 12K drwx------ 3 root root 4.0K Aug 3 23:00 . drwx------ 3 root root 4.0K Aug 3 23:00 .. drwx------ 3 root root 4.0K Aug 3 23:00 native-lisp Yes the file exists, but I cannot access it as a non-root ( should have checked before ). I can remove the folder and re-install and the permission is the same as above. On Thu, Aug 5, 2021 at 4:04 PM Eli Zaretskii wrote: > > Date: Thu, 05 Aug 2021 16:33:53 +0300 > > From: Eli Zaretskii > > Cc: 49864@debbugs.gnu.org > > > > 162 if (faccessat (AT_FDCWD, file, amode, AT_EACCESS) == 0) > > > > That shows the file name it is trying to access in the list of > > arguments of the function. As far as I understand from the other > > information you posted, that file does exist on your system, is that > > right? Because you said the file below does exist: > > > > > /usr/local/lib/emacs/28.0.50/native-lisp/28.0.50-864bf4e5/preloaded/window-0d1b8b93-dcb2375f.eln > > > > But for some reason, the faccessat call fails. We need to understand > > why. > > > > > (gdb) p errno > > > 'errno' has unknown type; cast it to its declared type > > > > To work around the problem with errno's type, try this: > > > > (gdb) p (int)errno > > To clarify: please print the value of errno as above _after_ stepping > over the call to faccessat, i.e. when GDB shows this: > > 162 if (faccessat (AT_FDCWD, file, amode, AT_EACCESS) == 0) > (gdb) next > 175 return false; > --00000000000040464f05c8d17aba Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks for your patience, I appreciate the effort trying t= o solve this.

Here is the gdb log:
1561 =C2=A0r= eturn XSTRING (string)->u.s.data;
(gdb) n
5321 =C2=A0 =C2=A0if (= file_access_p (fndata, F_OK))
(gdb) step
file_access_p (
=C2=A0 = =C2=A0 file=3Dfile@entry=3D0x555555cf8838 "/usr/local/libexec/emacs/28= .0.50/x86_64-pc-linux-gnu/../../../../bin/../lib/emacs/28.0.50/native-lisp/= 28.0.50-864bf4e5/preloaded/window-0d1b8b93-dcb2375f.eln", amode=3Damod= e@entry=3D0) at fileio.c:162
162 =C2=A0if (faccessat (AT_FDCWD, file, a= mode, AT_EACCESS) =3D=3D 0)
(gdb) next
dump_do_dump_relocation (dump_= base=3D<optimized out>, reloc=3D...) at pdumper.c:5325
5325 eln_= fname =3D make_uninit_string (execdir_len + fn2_len);
(gdb) p (int)errno=
$1 =3D 13

I can indeed access /usr/local/l= ibexec/emacs/28.0.50/x86_64-pc-linux-gnu/../../../../bin/../lib/emacs/28.0.= 50/native-lisp/28.0.50-864bf4e5/preloaded/window-0d1b8b93-dcb2375f.eln but = only as root. Which seems wrong. I can start emacs as sudo ( have not even = checked this before )

Which is then probably a umask issu= e as this folder's permission seems wrong:
=C2=A0/usr/local/lib $ su= do ls -lah emacs
total 12K
drwx------ 3 root root 4.0K Aug =C2=A03 23= :00 .
drwxr-xr-x 4 root root 4.0K Aug =C2=A03 23:00 ..
drwx------ 3 r= oot root 4.0K Aug =C2=A03 23:00 28.0.50

sudo ls -l= ah emacs/28.0.50
total 12K
drwx------ 3 root root 4.0K Aug =C2=A03 23= :00 .
drwx------ 3 root root 4.0K Aug =C2=A03 23:00 ..
drwx------ 3 r= oot root 4.0K Aug =C2=A03 23:00 native-lisp

Yes th= e file exists, but I cannot access it as a non-root ( should have checked b= efore ). I can remove the folder and re-install and the permission is the s= ame as above.


On Thu, Aug 5, 2021 at 4:04 PM Eli Z= aretskii <eliz@gnu.org> wrote:
> Date: Thu, 05= Aug 2021 16:33:53 +0300
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 49864@d= ebbugs.gnu.org
>
>=C2=A0 =C2=A0162=C2=A0 =C2=A0 =C2=A0 =C2=A0if (faccessat (AT_FDCWD, fil= e, amode, AT_EACCESS) =3D=3D 0)
>
> That shows the file name it is trying to access in the list of
> arguments of the function.=C2=A0 As far as I understand from the other=
> information you posted, that file does exist on your system, is that > right?=C2=A0 Because you said the file below does exist:
>
>=C2=A0 =C2=A0/usr/local/lib/emacs/28.0.50/native-lisp/28.0.50-864bf4e5/= preloaded/window-0d1b8b93-dcb2375f.eln
>
> But for some reason, the faccessat call fails.=C2=A0 We need to unders= tand
> why.
>
> > (gdb) p errno
> > 'errno' has unknown type; cast it to its declared type >
> To work around the problem with errno's type, try this:
>
>=C2=A0 =C2=A0(gdb) p (int)errno

To clarify: please print the value of errno as above _after_ stepping
over the call to faccessat, i.e. when GDB shows this:

=C2=A0 162=C2=A0 =C2=A0 =C2=A0 =C2=A0if (faccessat (AT_FDCWD, file, amode, = AT_EACCESS) =3D=3D 0)
=C2=A0 (gdb) next
=C2=A0 175=C2=A0 =C2=A0 =C2=A0 =C2=A0return false;
--00000000000040464f05c8d17aba--