From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6478538670852800512 X-Received: by 10.28.132.134 with SMTP id g128mr177509wmd.24.1508414446915; Thu, 19 Oct 2017 05:00:46 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 10.28.66.197 with SMTP id k66ls1337650wmi.6.gmail; Thu, 19 Oct 2017 05:00:46 -0700 (PDT) X-Google-Smtp-Source: ABhQp+QfRW/5qxY6AuiZsXaqci7awjvVDkNlv+lbgkuZxmX1KdBIObRShdX/1YNAlrqPBL1rMubB X-Received: by 10.28.24.207 with SMTP id 198mr186257wmy.12.1508414446576; Thu, 19 Oct 2017 05:00:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1508414446; cv=none; d=google.com; s=arc-20160816; b=SrlAjI+Yb3ygOMzlfHHXn6VRBL0bZ9PIVRB6mifB5pWQ1dS0UrfyiyYJyzo0RWOm1j 4ggxbBejBXLqsQOFH1RUo/kAIOlDqu2OV6HzSk9GMzc+uN53RxsLGBosiQaeexfEHk4N 4kcK9VuqSjvRsADyE2wwpg0Wh4cQHeL7H/mEP40LURR/qkLzuh+xh+D7QruqqiRiNPUR HhaF+3dI4GchjYzvONek8olRfxLhRuLkyItsF3GEefKZtD95b0v6+AsfM+OGbygZlVwB CZvNtOxofonF2XuZmt6JwNPxHfh7TOsJBTBmP4yaA6GYgr/3OenjgqrL/FbMWcpBc+3U ZRfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:content-language:in-reply-to:mime-version :user-agent:date:message-id:from:references:cc:to:subject :arc-authentication-results; bh=55eI7R0fN4o1KYr16ODXV1dKvq9RMMBg5oPxdYV0sO0=; b=JB6hv3QFTeqb3wLjihkbTJKulVMxPVcIIt/XMi7Nn2NNXW2OlDb2J39uDoOevWP/KN wPNmkudwbz/SzJ9gfPgjfTtPKwN+GVUDj2vckTfTb3L8PS6Kf+dWTTGt7lZ6oXb2QRVi 5pA9YIDADPa5y/P3aeNRXRyIHcrZajl+csrzN3N2E4k+AFLd0xs1D+cK8vHiiMBxN0oP YVCbmiND+w9HEgEEHWMcvVVPlx7V4+ZzDOZqcGsRcx2HQN9G9fb+S1+B8962hIJDDIvA BC3zi5a7/g7/KYg2tYP1ZbUZ4Y3jPAMANm5pduHgAkkb4tLKjHiuuIgEfbzR27x1Zy9J ux7g== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of claudius.heine.ext@siemens.com designates 192.35.17.14 as permitted sender) smtp.mailfrom=claudius.heine.ext@siemens.com Return-Path: Received: from david.siemens.de (david.siemens.de. [192.35.17.14]) by gmr-mx.google.com with ESMTPS id 196si337792wmk.4.2017.10.19.05.00.46 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 19 Oct 2017 05:00:46 -0700 (PDT) Received-SPF: pass (google.com: domain of claudius.heine.ext@siemens.com designates 192.35.17.14 as permitted sender) client-ip=192.35.17.14; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of claudius.heine.ext@siemens.com designates 192.35.17.14 as permitted sender) smtp.mailfrom=claudius.heine.ext@siemens.com Received: from mail1.sbs.de (mail1.sbs.de [192.129.41.35]) by david.siemens.de (8.15.2/8.15.2) with ESMTPS id v9JC0jxg016943 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 19 Oct 2017 14:00:46 +0200 Received: from [139.25.68.223] (linux-ses-ext02.ppmd.siemens.net [139.25.68.223]) by mail1.sbs.de (8.15.2/8.15.2) with ESMTP id v9JC0jtH026207; Thu, 19 Oct 2017 14:00:45 +0200 Subject: Re: Introducing chroot tasks To: Ben Brenson , Henning Schild Cc: isar-users References: <81c9592a-74df-25d8-70ac-978f6ef1694e@siemens.com> <20171019111500.44f150f0@md1em3qc> From: Claudius Heine Message-ID: <0f1cc8e0-5c6c-9e35-7426-4e1380bf54e1@siemens.com> Date: Thu, 19 Oct 2017 14:00:45 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-TUID: vvSdrOsmGTqo Hi, On 10/19/2017 12:24 PM, Ben Brenson wrote: > 2017-10-19 11:15 GMT+02:00 Henning Schild : > >> On Thu, 19 Oct 2017 11:01:28 +0200 >> "[ext] Claudius Heine" wrote: >> >>> Hi Ben, >>> >>> On 10/19/2017 10:38 AM, 'Ben Brenson' via isar-users wrote: >>>> Hi, >>>> >>>> I want to submit some patches for defining and running chroot tasks >>>> within bitbake recipes. >>>> The following short example should show what I mean: >>>> >>>> Exampe recipe.bb: >>>> >>>> do_foo() { >>>> # Do something within chroot >>>> } >>>> do_foo[chroot] = "1" >>>> do_foo[id] = "${BUILDCHROOT_ID}" >>>> addtask do_foo after ... before ... >>>> >>>> >>>> By setting the chroot flag the task automatically will be executed >>>> within the chroot specified by the id flag. >>>> My isar (https://github.com/benbrenson/isar) fork already supports >>>> this feature, by using schroot. >>>> >>>> This will give much more flexibility and modularity to Isar. You >>>> will be able to append/prepend things to those tasks >>>> between layers easily. >>>> >>>> I have already seen, that there is another and better approach than >>>> schroot -> proot. >>>> I saw Alexander has already experimented with this feature, which >>>> seems to work. >>>> >>>> So before posting some patches here, maybe changing this feature to >>>> proot first would a better first-step? >>> >>> Yes. Since proot solves some more problems than schroot. >>> >>> Your implementation requires patching the bitbake code, so maybe we >>> should try to get those changes upstream to bitbake? >> >> IMHO, touching our copy of bitbake is an absolute NoGo! Such changes >> need to go upstream first. >> > Yeah I know, but using chroot tasks was never a use case for bitbake and > maybe will never be, I think. > I've never thought about using chroot tasks when running Yocto builds, but > that has changed very fast when switching to Isar. > So maybe within Isar we have a more reasoned use case for chroot tasks, and > if this feature works in isar, may be I have more chances to get those > changes upstream to bitbake? > > I can try to get those changes upstream first.... A version that is independent of the chroot implementation might be more useful upstream maybe. Call it a 'execution context' then you can specify if a specific task should be run in a chroot environment, in a ssh shell. Some repl or a programming language or the serial tty session might a bit to much though but maybe possible. Cheers, Claudius -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-54 Fax: (+49)-8142-66989-80 Email: ch@denx.de