From mboxrd@z Thu Jan 1 00:00:00 1970 From: Danny Milosavljevic Subject: Re: Rust 1.19 fails to build on i686 on =?UTF-8?Q?=E2=80=98stagin?= =?UTF-8?Q?g=E2=80=99?= Date: Mon, 18 Feb 2019 15:38:24 +0100 Message-ID: <20190218153824.58bc253f@scratchpost.org> References: <87k1ioq21m.fsf@gnu.org> <20190128162705.052961e4@scratchpost.org> <877eenrhbj.fsf@gnu.org> <20190130185900.7f3d30a9@scratchpost.org> <20190205122839.06b482db@scratchpost.org> <20190205123510.510731a6@scratchpost.org> <20190211223456.0779cf68@scratchpost.org> <87o97hz0ra.fsf@gmail.com> <20190212130658.2c1f2a23@scratchpost.org> <878sykbdgg.fsf@gmail.com> <87imxo9r0k.fsf@gmail.com> <87a7izhtqw.fsf@gmail.com> <20190214181401.661c0430@scratchpost.org> <87imxlju1l.fsf@gmail.com> <20190215115132.46844896@scratchpost.org> <87a7iwm2c5.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; boundary="Sig_/Tqt=8Upr=_Gd/C+s.aLJf2S"; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([209.51.188.92]:41385) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gvk42-0003aP-Sc for guix-devel@gnu.org; Mon, 18 Feb 2019 09:38:38 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gvk42-0006hj-0M for guix-devel@gnu.org; Mon, 18 Feb 2019 09:38:34 -0500 In-Reply-To: <87a7iwm2c5.fsf@gmail.com> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Chris Marusich Cc: Guix-devel --Sig_/Tqt=8Upr=_Gd/C+s.aLJf2S Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Hi Chris, On Sat, 16 Feb 2019 02:53:30 -0800 Chris Marusich wrote: > > (i.e. the things you did before, just inside a i686-linux guix > > environment. That only provides minimal--almost no--isolation from > > the host, so it should allow us to test whether the personality is the > > only possible culprit) =20 >=20 > Did you mean to say that by using a pure guix environment, we can > achieve a high degree of isolation? * "guix environment" provides very low isolation (almost none) * "guix environment --pure" provides better isolation by at least removing things from $PATH which aren't supposed to be there. * "guix environment -C" provides very good isolation by creating a new initially-empty container. What I meant is that "guix environment -s i686-linux" is very different from guix-daemon (especially it does not set the personality) and might allow us to proceed without error, or with a different error. But apparently the actual problem is that now it always succeeds. Today I think we should reproduce the guix-daemon environment as closely as possible in order to make it fail again--and then use the setup right before it started failing again. In this case if we wanted to have a similar environment to the guix-daemon, I think "guix environment -C" would be the most similar - and should fail. I'm not sure whether guix environment -C sets the personality. If not, then your program should be good for setting the personality. Your program could be simpler if it just used execv(argv[1], argv + 1) (or execv(argv[1], &argv[1])) instead of copying the argument vector; if one wants to skip elements at the front of an array, using the fact that arrays elements are sequential in C, without gaps, ordered by increasing index, can be very useful. > I tried what you suggested. The mrustc invocation still succeeded. So it always succeeds outside guix-daemon container (does that include "guix environment -C" ?), but doesn't succeed inside a guix-daemon container, is that correct? > Just for fun, I also made a simple wrapper program that lets me run > another program using the LINUX32 personality (see attached). I think I > programmed it correctly, but C is not (yet!) my forte, so if I made an > error, please let me know. >From within the same pure environment, I > used this wrapper program to invoke mrustc in the same way, and it > _still_ succeeded. That surprised me, since I expected it to fail. That's strange. Then maybe the personality is not the reason. > Can you think of any other way I can try to reproduce the issue? I'd try=20 guix environment -s i686-linux -C rust@1.19.0 And then try to build it in there (or only run the same steps you ran before--should be enough). Thanks for looking into it. Apparently it seems to be possible to get working--it's just a matter of tuning the environment (maybe even only by removing things). (If it is the personality, I suspect that it changes the system call interface and maybe mrustc assumes the x86_64 syscall interface at all times) --Sig_/Tqt=8Upr=_Gd/C+s.aLJf2S Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEds7GsXJ0tGXALbPZ5xo1VCwwuqUFAlxqw2AACgkQ5xo1VCww uqUsCAf/UFjC3b+rgtTiPRo4I1ecSacLMY11oARDERTOU59sGiAGFNdXOneJ3fjw iUaDJcuzNT3lG4iuZRc0ihi+j3S+zVBaGtpD8Jkc8FLXxWpQ4dpb2JatEMSxwYV8 wUK6rpE+n4nb114T44kvTZUAy+I3rLcsnZENk07aPvY/m1UFYpH/Vq4k/us/ybg7 NRCFbmOI2HmOOobu3eOTTUrU44dFP/vRNRAaeMBZOz+aoQWRumLgfeiL58jMjaiG B4VFFiP9CMuL+IwwOsDrdSofsTIHcaycq20XBtak+1S34dW+KdhzDczDcWumzd5g 7DyhY0045n4HjaCYyDOuwQHeXbdklg== =MY3g -----END PGP SIGNATURE----- --Sig_/Tqt=8Upr=_Gd/C+s.aLJf2S--