From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 7330292884155924480 X-Forwarded-Encrypted: i=2; AJvYcCVDmlpIZnAw4YLRbvwevHiOJhwXTtQydVCmuMAJ+8HyggYoJ1MNvf/7gskxaJbRYx+fvW3MSzT97r+wGrIVLy2N61G/Txo4p6I7B5w= X-Received: by 2002:adf:fc49:0:b0:345:6cec:4e02 with SMTP id e9-20020adffc49000000b003456cec4e02mr9332079wrs.12.1713185283699; Mon, 15 Apr 2024 05:48:03 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a05:600c:4f89:b0:416:acb6:6109 with SMTP id n9-20020a05600c4f8900b00416acb66109ls1540960wmq.0.-pod-prod-00-eu-canary; Mon, 15 Apr 2024 05:48:01 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCX8rl3SOaeUld1hpzLivvJ5UTOUUV1f0uPnaxhG7J8G/i4o+vpGGgXSzOgoyz3yZmcs1dl9XoUO4GVSXTui30+ziTngj/EXlo57YjY= X-Google-Smtp-Source: AGHT+IEKs4ZRTJ5VKeObTcveML9MdAn7437fQajS4m5a1WBm8J3opVpCmn3l7ohicvykzH1jELil X-Received: by 2002:adf:f308:0:b0:343:7ed6:765a with SMTP id i8-20020adff308000000b003437ed6765amr9184074wro.20.1713185281359; Mon, 15 Apr 2024 05:48:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1713185281; cv=none; d=google.com; s=arc-20160816; b=AkbRCCwLkRd5WyRx3p/Eqye90HuKpJVqVrSOVZ921sPV5+8AURpQhQnb74t0q6lskG 3Eu+5wunXgm5wbWpA6n/aCpL8j3OMYboBACHTkn8H/s8+b6Sdo4drGWY+tuWb/tZuv4H wuLDGMDneyy2I2sOZnMWDwhCPK5q1WboOurNvXdqdrLzf3mu57iig5V6FusnXDoW7tBI aAXk1swmzPyrQPaNjPmQIkBpw1L/dlAH3UTEW/wSTR61fx2QgIf4sgMkVA++Zkrl6kzs cl/UG2nEw5A69WwvngMNwJSSduwoGH1mS8djY9mcNo+h99zDgWXYo1JsxQqVNUSikWBV RmTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id; bh=8QrtEI3prcQKnKMU9ZyXXXm9izByUvW4C9bzvrLjr1Y=; fh=YwT1SHZnZymu6V3YPNGSt6GSJLMvkgq3LRIHcCQ77UQ=; b=npvYkS0jSv4+D/UagPb4JLgsDTTJ36rvEngksBN1FiG1vx4d8hKuiX9VAzPLta+RYT QPrij7Nze3MCRh7k9X7vGZW3fSqelbGzeTbkoy5vNm5VXAQj4xe/J+kpdp0IwDus1BHQ YL9zLsjG5KLUy/GLHMZoPcdbYiEVvFksf5LDhzjEp4GS684LD/9VHkOyFErxMvIe3tZQ VRntkq7o0YWixn1xdw4Ccn+L72PvFj+jp0OSAAagaeGA9nD3amlSzLhfVsK1tJNa5lBi o0Iu55/rad0TBLiV/epnEKqf3WkGuHPvyl7EPSznRkrLX61JFIC4SmuzYbxggy/VsyrI gDyw==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=ubely@ilbers.de Return-Path: Received: from shymkent.ilbers.de (shymkent.ilbers.de. [85.214.156.166]) by gmr-mx.google.com with ESMTPS id c9-20020a056000184900b00341c9bc6836si238799wri.3.2024.04.15.05.48.01 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 15 Apr 2024 05:48:01 -0700 (PDT) Received-SPF: pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) client-ip=85.214.156.166; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=ubely@ilbers.de Received: from [127.0.0.1] (host-80-81-17-52.static.customer.m-online.net [80.81.17.52]) (authenticated bits=0) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPSA id 43FClwGI018027 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 15 Apr 2024 14:48:00 +0200 Message-ID: <4f7b08acb2640ce1f0f9bc56b5351fbdd685e206.camel@ilbers.de> Subject: Re: [PATCH v6 0/5] linux-custom: Split up binaries from kernel headers to kbuild package From: Uladzimir Bely To: Stefan Koch , isar-users@googlegroups.com Date: Mon, 15 Apr 2024 15:47:58 +0300 In-Reply-To: <20240214101025.2123540-1-stefan-koch@siemens.com> References: <20240214101025.2123540-1-stefan-koch@siemens.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.52.0 (by Flathub.org) MIME-Version: 1.0 X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-TUID: eO5tADu0hxJf On Wed, 2024-02-14 at 11:10 +0100, 'Stefan Koch' via isar-users wrote: > Hi >=20 > This updated v6 patchset implement suggestions from reviewed v4 > patchset. > It's now a set of five patches: > - linux-custom: Set PROVIDES variable using bitbake overrides > - linux-custom: Split up binaries from kernel headers to kbuild > package > - linux-custom: Provide target and host specific kernel kbuild > packages > - linux-module: Support emulated module build with cross-compiled > kernel > - docs: Update custom_kernel docs for split up of kernel scripts and > tools >=20 > The first commit sets the PROVIDES variable using > bitbake overrides instead of python code. >=20 > Swap out the binaries from the kernel headers > into kernel kbuild package is the main use-case > introduced by the second commit > "Split up binaries from kernel headers to kbuild package" >=20 > The third commit "Provide target and host specific kernel kbuild > packages" > introduces that the binaries could be swapped out into host and > target > specific kernel kbuild packages. >=20 > Support of emulated module build with a cross-compiled kernel build > is introduced by the fourth commit. >=20 > These are the main development goals: >=20 > 1. Solve already known isar custom kernel > limitations from doc/custom_kernel.inc > - kernel headers package does not support both native > =C2=A0 and cross compilation of kernel modules when cross built >=20 > 2. Honor recommendations for future from doc/custom_kernel.inc > - Generate kernel headers packages for both host and target > =C2=A0 when using cross build >=20 > 3. Add extensions known from debian kernel packages structure > - Generate a kernel headers package without binaries > - Create specific kernel kbuild packages that > =C2=A0 will ship the "scripts" and "tools" binaries > - Use symlinks to point to the "scripts" and "tools" binaries >=20 > 4. Be user friendly > - Avoid redundant configuration of kernel source definitions with > user > =C2=A0 actions to enable kbuild package generation > - Use already known way to include linux-custom.inc in just one > =C2=A0 own bitbake recipe that provides the kernel source definitions > - Keep known user behavior for existing build configurations: > =C2=A0 just update isar, and use the new linux-kbuild bitbake target > =C2=A0 to create the kbuild target package when cross building >=20 > Best regards >=20 > Stefan >=20 > Stefan Koch (5): > =C2=A0 linux-custom: Set PROVIDES variable using bitbake overrides > =C2=A0 linux-custom: Split up binaries from kernel headers to kbuild > package > =C2=A0 linux-custom: Provide target and host specific kernel kbuild > packages > =C2=A0 linux-module: Support emulated module build with cross-compiled > kernel > =C2=A0 docs: Update custom_kernel docs for split up of kernel scripts and > =C2=A0=C2=A0=C2=A0 tools >=20 > =C2=A0RECIPE-API-CHANGELOG.md=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 | 31 ++++++++ > =C2=A0doc/custom_kernel.md=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 | 18 +++-- > =C2=A0meta/recipes-kernel/linux-module/module.inc=C2=A0=C2=A0 |=C2=A0 3 += - > =C2=A0.../linux/classes/kbuildtarget.bbclass=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 |=C2=A0 8 ++ > =C2=A0.../linux/files/debian/control.tmpl=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 | 15 +++- > =C2=A0.../linux/files/debian/isar/build.tmpl=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 | 13 +++- > =C2=A0.../linux/files/debian/isar/common.tmpl=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0 | 11 +++ > =C2=A0.../linux/files/debian/isar/install.tmpl=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0 | 75 ++++++++++++++--- > -- > =C2=A0meta/recipes-kernel/linux/linux-custom.inc=C2=A0=C2=A0=C2=A0 | 65 += ++++++++++++--- > =C2=A0meta/recipes-kernel/linux/linux-distro.bb=C2=A0=C2=A0=C2=A0=C2=A0 |= =C2=A0 1 + > =C2=A010 files changed, 199 insertions(+), 41 deletions(-) > =C2=A0create mode 100644 meta/recipes- > kernel/linux/classes/kbuildtarget.bbclass >=20 > --=20 > 2.39.2 >=20 Hello Stefan. Recently I run the patchset through CI and it failed (test 2 in "dev" set) on amd64 targets with error like: [stdlog] 2024-04-12 16:23:10,235 avocado.app cibuilder L0222 ERROR| ERROR: Nothing PROVIDES 'linux-kbuild-amd64-native' (but mc:qemuamd64-bullseye:/workspace/build/isar_ub_devel_fast/567/meta- isar/recipes-kernel/example-module/example-module.bb DEPENDS on or otherwise requires it). Close matches: [stdlog] 2024-04-12 16:23:10,235 avocado.app cibuilder L0222 ERROR| linux-kbuild-amd64 [stdlog] 2024-04-12 16:23:10,235 avocado.test cibuilder L0220 INFO |=20 [stdlog] 2024-04-12 16:23:10,235 avocado.app cibuilder L0222 ERROR| linux-kbuild-cip-native [stdlog] 2024-04-12 16:23:10,235 avocado.app cibuilder L0222 ERROR| linux-kbuild-mainline-native [stdlog] 2024-04-12 16:23:10,235 avocado.app cibuilder L0222 ERROR| ERROR: Required build target 'isar-image-ci' has no buildable providers. I tried to reproduce it locally, and the easiest way to reproduce was the following: ``` ./kas/kas-container menu ... Parsing recipes: 100% |###################################################################### #########################################################| Time: 0:00:00 Parsing of 55 .bb files complete (0 cached, 55 parsed). 57 targets, 15 skipped, 0 masked, 0 errors. NOTE: Resolving any missing task queue dependencies ERROR: Nothing PROVIDES 'linux-kbuild-amd64-native' (but /build/../repo/meta-isar/recipes-kernel/example-module/example- module.bb DEPENDS on or otherwise requires it). Close matches: linux-kbuild-amd64 linux-kbuild-cip-native linux-kbuild-mainline-native ERROR: Required build target 'isar-image-base' has no buildable providers. Missing or unbuildable dependency chain was: ['isar-image-base', 'example-module-amd64', 'linux-kbuild-amd64-native'] ``` I also tried the patchset with older Isar (e.g. just some commits before v0.10, when the patchset was released) and the situation looks the same. When we remove "example-module" from list of packages to install, build is OK.