From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9F964C433DB for ; Mon, 1 Mar 2021 11:23:17 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E803764DE0 for ; Mon, 1 Mar 2021 11:23:16 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E803764DE0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=tls.msk.ru Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:46916 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lGgdv-0005WI-Ge for qemu-devel@archiver.kernel.org; Mon, 01 Mar 2021 06:23:15 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:54936) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lGgXn-0001Py-B5 for qemu-devel@nongnu.org; Mon, 01 Mar 2021 06:16:55 -0500 Received: from isrv.corpit.ru ([86.62.121.231]:51531) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lGgXk-00029O-9m for qemu-devel@nongnu.org; Mon, 01 Mar 2021 06:16:54 -0500 Received: from tsrv.corpit.ru (tsrv.tls.msk.ru [192.168.177.2]) by isrv.corpit.ru (Postfix) with ESMTP id F3C5A400F2; Mon, 1 Mar 2021 14:16:47 +0300 (MSK) Received: from [192.168.177.99] (mjt.vpn.tls.msk.ru [192.168.177.99]) by tsrv.corpit.ru (Postfix) with ESMTP id CB64DDA; Mon, 1 Mar 2021 14:16:47 +0300 (MSK) Subject: Re: [PATCH] linux-user: manage binfmt-misc preserve-arg[0] flag To: John Paul Adrian Glaubitz , Laurent Vivier , qemu-devel@nongnu.org References: <20210222105004.1642234-1-laurent@vivier.eu> <0ee2b107-1533-3098-9797-040633964300@physik.fu-berlin.de> <09fefe8c-c3bb-1303-9e85-d207c6ec4ffc@msgid.tls.msk.ru> <1f1c6fa9-a9cc-b169-1c9a-57008752efb4@physik.fu-berlin.de> <644a53ea-852e-b60c-973d-10e37096d99e@msgid.tls.msk.ru> <6b0c8faf-98c8-29f7-a6be-7901b94deb38@physik.fu-berlin.de> From: Michael Tokarev Message-ID: <185ce154-c34e-a417-69db-3d1da5609468@msgid.tls.msk.ru> Date: Mon, 1 Mar 2021 14:16:47 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 MIME-Version: 1.0 In-Reply-To: <6b0c8faf-98c8-29f7-a6be-7901b94deb38@physik.fu-berlin.de> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Received-SPF: none client-ip=86.62.121.231; envelope-from=mjt@tls.msk.ru; helo=isrv.corpit.ru X-Spam_score_int: -68 X-Spam_score: -6.9 X-Spam_bar: ------ X-Spam_report: (-6.9 / 5.0 requ) BAYES_00=-1.9, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_HI=-5, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Helge Deller Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" 01.03.2021 14:07, John Paul Adrian Glaubitz wrote: > On 3/1/21 11:40 AM, Michael Tokarev wrote: >> 01.03.2021 13:35, John Paul Adrian Glaubitz wrote: >> .. >>> I have been trying to get qemu-user working with sbuild as it is shipped in Debian >>> unstable now but I didn't have any success. >>> >>> Do you have some instructions somewhere how to get qemu-user working with sbuild? >> >> Have you seen #983087 which I fixed yesterday? > > Thanks, but it doesn't help, unfortunately. > > Do I need to use qemu-user-static or qemu-user-binfmt? Oh. You tried to use qemu-user, not qemu-user-static.. Well. In order for it to work it should be registered with the in-kernel binfmt-misc subsystem. qemu-user-static package does this automatically for you, but qemu-user does not, for that with qemu-user you'll have to additionally install qemu-user-binfmt package. But I guess it wont work with qemu-user even if it is registered (by means of installing qemu-user-binfmt or manual registration or whatever), - because regular qemu-user binaries aren't statically linked and hence require all the shared libraries within the chroot in order to run. I never tried to use regular (non-static) qemu-user with foreign chroot, and I suspect it wont work because of that very reason, and at least extra setup is needed (like copying appropriate /lib/ld.so and libc&glib&Co to the chroot). This is all about how qemu-user works, be it debian or any other distribution, - it is basically the same. I can only guess the wiki page you mentioned is wrong here. Thanks, /mjt