From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6597265115990458368 X-Received: by 2002:a50:89ca:: with SMTP id h10-v6mr7856423edh.11.1536053629705; Tue, 04 Sep 2018 02:33:49 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a50:c8c9:: with SMTP id k9-v6ls9492498edh.1.gmail; Tue, 04 Sep 2018 02:33:49 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbovXYwCVG6U51Z5fQDlGYMTdmMuVE0NovrtKlH6Hm7hhUEmRCBRRPDlLaEQwzsb3X30ECe X-Received: by 2002:a50:8879:: with SMTP id c54-v6mr7844689edc.1.1536053629212; Tue, 04 Sep 2018 02:33:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536053629; cv=none; d=google.com; s=arc-20160816; b=usxEzbgtzEZsNvtUTTEgpRw4+FQxW0oqCOPczP9XvYuuOsgiUlcnzVgEmNwMNTFR+O iIJkpJKDFh78rvg1QPPlYE8fkZJGFHlxjCoJ9P/VUS9ElTHfAzVZ8ySkY86JcxVEG3GF ZgLrQSRVXRF3rseVx/xjYPEyo8kLE3rzCJdR7O1EOE+zKvw3hpp18Ny4hJoNkn3Mzjfe L3wQIv7G8W1sE1x4hwvxrYWar2u9+Fuh2r4q799aKdrSZjyf1MfxJwsZ/6aB32nvWxUm KGCgqdHXVNXplkDosP78mElr4jpoAZ2ze6+dXJ+BYX5KrnkEDYi1KgNmcEiFdL+MwR7x REdA== 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:to:subject :arc-authentication-results; bh=W8YhK8ry6Xa5VRwM8vpGvqQ1JSn6iexUZyZyo9JrRfA=; b=ZnNDsvDeeOVxN+b8QfkJYTpWmJEq9I9n3blhekdcPHkRmg0uXMGrR4QvnUb6MjQwCS OjyzukQhnyP+5WsD21C4f88jCw8VwA0xuW7eAdE0A/VP4sUb6J5EXD684nd1jvMH/AoX FqbQ1yDabM13FCSeUHpV9oXBsvAWpsWsfwqfIUG6YCV4hk5G40noKTOoboLPEnx/RMeC f4RvBAuctwSTyQ1+udYLAR9fnLAoglrocad/yBgZIu2dzpncaybNpS2wx+FqEkGlRcaL tAOrUogwadMaQhUoey5R3YC9+x1jNdZzgaUxfTE4fjWmp5P8P0vEHQP1mS6VRFGwKRs7 zg6Q== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of jan.kiszka@siemens.com designates 192.35.17.14 as permitted sender) smtp.mailfrom=jan.kiszka@siemens.com Return-Path: Received: from david.siemens.de (david.siemens.de. [192.35.17.14]) by gmr-mx.google.com with ESMTPS id b23-v6si583760edn.1.2018.09.04.02.33.49 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 04 Sep 2018 02:33:49 -0700 (PDT) Received-SPF: pass (google.com: domain of jan.kiszka@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 jan.kiszka@siemens.com designates 192.35.17.14 as permitted sender) smtp.mailfrom=jan.kiszka@siemens.com Received: from mail2.sbs.de (mail2.sbs.de [192.129.41.66]) by david.siemens.de (8.15.2/8.15.2) with ESMTPS id w849Xlcb009181 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 4 Sep 2018 11:33:48 +0200 Received: from [139.25.68.37] (md1q0hnc.ad001.siemens.net [139.25.68.37] (may be forged)) by mail2.sbs.de (8.15.2/8.15.2) with ESMTP id w849XlBS030762; Tue, 4 Sep 2018 11:33:47 +0200 Subject: Re: [RFC] Interface for installing bootloaders To: Claudius Heine , isar-users , Claudius Heine , Henning Schild , Andreas Reichel References: <0aeb9010-8fed-6094-ac12-41983c3831ae@siemens.com> <4ae0dc9d-7fa4-9fa0-7844-aab25579fdb7@siemens.com> From: Jan Kiszka Message-ID: Date: Tue, 4 Sep 2018 11:33:47 +0200 User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); de; rv:1.8.1.12) Gecko/20080226 SUSE/2.0.0.12-1.1 Thunderbird/2.0.0.12 Mnenhy/0.7.5.666 MIME-Version: 1.0 In-Reply-To: <4ae0dc9d-7fa4-9fa0-7844-aab25579fdb7@siemens.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-TUID: CZlg6Gqapl2H On 2018-09-04 11:27, Claudius Heine wrote: > Hi Jan, > > On 2018-09-04 09:17, [ext] Jan Kiszka wrote: >> Hi all, >> >> for installing a bootloader into an image, a number of packages have >> to be installed into the buildchroot. These can be prebuilt packages >> or packages we build via Isar. Currently, we only handle the case of >> WIC requiring prebuilt Debian packages, and that in a hacky way (no >> proper distro abstraction, unneeded installation of unused >> dependencies). This proposal aims at providing a more holistic solution: >> >> - Introduce new variables that express the two types of dependencies: >>     - BOOTLOADER_PREBUILT >>     - BOOTLOADER_CUSTOM >> >>    So there is no "WIC" in these, any imaging recipe can use them. >> >> - Imaging recipes (e.g. via classes/wic-img.bbclass) should >>     - install all packages from BOOTLOADER_PREBUILT and BOOTLOADER_CUSTOM >>       into the buildchroot >>     - DEPEND on all recipes in BOOTLOADER_CUSTOM >> >> - Define some common dependencies in conf/distro/${DISTRO}.conf: >>     - GRUB_PREBUILT >>     - GRUB_PREBUILT_append_${DISTRO_ARCH} >>     - SYSLINUX_PREBUILT >>     - ... >> >>    Those variables can then be used to initialize BOOTLOADER_PREBUILT as >>    needed and also replace those nasty BUILDCHROOT_PREINSTALL_WIC in >>    buildchroot-target.bb. >> >> - Set BOOTLOADER_PREBUILT or BOOTLOADER_CUSTOM in the >>    conf/machine/${MACHINE}.conf or some overriding conf file - basically >>    the same one that selects IMAGE_TYPE and WKS_FILE. >> >> Anything I missed? Better suggestions? Eventually, when we can derive >> bitbake recipe dependencies automatically from package dependencies, >> PREBUILT and CUSTOM could be folded together. Right now, we need that >> split. >> >> Jan > > I have a class that I use for the current project that allows installing > additional packages into the buildchroot from within the image. I didn't > had time to prepare patches for it for mainline isar. But maybe that > goes into to right direction. > > I attached it. Yeah, can serve as pattern. I'd just like to abstract away from the user that fact the bootloader deps go into buildchroot, i.e. the user interface shall not be BUILDCHROOT_EXTRA_INSTALL / BUILDCHROOT_BUILD_DEP in the context of bootloader installation. Jan