From patchwork Fri May 30 11:37:41 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mikko Rapeli X-Patchwork-Id: 63890 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 81764C5B543 for ; Fri, 30 May 2025 11:38:35 +0000 (UTC) Received: from mail-lf1-f41.google.com (mail-lf1-f41.google.com [209.85.167.41]) by mx.groups.io with SMTP id smtpd.web10.4131.1748605106035463878 for ; Fri, 30 May 2025 04:38:26 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=f+pYnoS9; spf=pass (domain: linaro.org, ip: 209.85.167.41, mailfrom: mikko.rapeli@linaro.org) Received: by mail-lf1-f41.google.com with SMTP id 2adb3069b0e04-5532f9ac219so2381247e87.1 for ; Fri, 30 May 2025 04:38:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1748605104; x=1749209904; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=8D9X+QFuY+dHK3UiPK8XjK7HcDMxZHYwDlfzd/O4uBg=; b=f+pYnoS9a+cl3N37dpJxHtr3Vf2uRTNB4C2PZfA2Cg9OISkucN6HvrcbCjL/1rbac4 j4PwzANzesUlL3Fi4Il8tseYerDzK9EwyWZrnIfiLhB7czwEeQewBXcGqW/frKApdOvg i7+YVAUCCsNo5S5mtpTIy9WkGVJi8f8uXbZAV6bGSXUpyB6MWasuxqax+MNFUsT7ScJ6 2Tq55d48hEOwb40gGJpU8Gs38tYYMj6gjYlHtYffBUcrRTerIFH+RvRpcaRO/cNtp3wu FmVwrWceyQtJOYujy8UJ3k91b7QXjn8MrCgWU3F6wnYZJ6gFazce+zcIqdJYNBa/9Cpi NyEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1748605104; x=1749209904; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=8D9X+QFuY+dHK3UiPK8XjK7HcDMxZHYwDlfzd/O4uBg=; b=uf6fePkpyTRE71I95ICwLCe/dzMk9qf1YQJxcQL1FFL/aVx8CKvY1sVRTyf9Wdni02 Gdte7QMAUKGkrBEqRPV8kBBzZII12MOnTmWL02jsFgCRFcXmDX7NVnCDmSWmgChlZ4dd At1PgvvJlZn+Q0FjL+jEBhPw6ZlPMGxMzBFx/jBgagJdVC30jPgC9G+/xEMQXpgfU+DC oRF9uXWcLUdqHC2nf8DE3qlWZ8xjKHJ5SBqcqlP4K8WY8zX3svKNnMOb6lZt4EV7jLWH QNVUaZwyBk9i1r5xA6DecKhq0sLDjPQEjZniqA+xI/HZFnhCJKHt9clPfPcoX7cqRA0A 0jqQ== X-Gm-Message-State: AOJu0YyvIr9uBxPzjw2IeO+6sWp1rODWKwWjp61tbamhD4vpSGR1vuPA PHVESxN8OhA3C6YGzwY2WqESPCEmGqnXT7zv0+4VmI1zbnrOoCgJ7hFOCuYHzf6m3b0Lf7Z7zoZ 4VyJqEIY= X-Gm-Gg: ASbGncsgFB9QET7AXVZKlJ4YymIwAPVAgK3c8lKldcZKfqOhgKOFyHXRoS2mTMQqqTk pwgvkhGqM7vPbDgnHZPGGDMexW55Mf1+ZA2zzKi2KQ5dSFVeDGZe11Q14/ooDlAy14UW2Wy1ePf vmoemopJ+RfSL7dtLXS8bcnTEAZwhzb9t9V/PCw+v1MSzAi5/XN1Q3UAQWCA5OuPlEJVgHoRBHC 9/i3PcTxSiPFq/cIYOf57NVOA+WX98yWMakrffgtAeOSyQ62vnhV6WXo5gihR5L3wxiG418Nt8T FJSUWQWa3EtqdKFJehX/h4IjSqJGe8iS0zb097FyAcYtIn2oiXanZofPAYEVolhVCAcmNVNhdci kpptdUUwy1qdB3VXWWngANAQVoVGd X-Google-Smtp-Source: AGHT+IF9sezkrDxRSK0Xrb6RUJqrKU81hztirajDXnlDYYqdTzPQXcXBEvz2xBuuRLP9J14qhmhjKg== X-Received: by 2002:a05:6512:1328:b0:54e:81ec:2c83 with SMTP id 2adb3069b0e04-5533b8f412cmr1038201e87.18.1748605103871; Fri, 30 May 2025 04:38:23 -0700 (PDT) Received: from localhost.localdomain (87-100-218-141.bb.dnainternet.fi. [87.100.218.141]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-553379378f7sm676469e87.244.2025.05.30.04.38.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 May 2025 04:38:23 -0700 (PDT) From: Mikko Rapeli To: openembedded-core@lists.openembedded.org Cc: Mikko Rapeli Subject: [PATCH v7 1/5] wic bootimg-efi.py: fail build if no binaries installed Date: Fri, 30 May 2025 14:37:41 +0300 Message-ID: <20250530113745.778397-1-mikko.rapeli@linaro.org> X-Mailer: git-send-email 2.49.0 MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 30 May 2025 11:38:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/217497 With systemd-boot, some builds included correct EFI bootloader binaries and some not. Thus some builds booted and some not. Check that some boot binary was installed so that build fails if none were installed. Signed-off-by: Mikko Rapeli --- scripts/lib/wic/plugins/source/bootimg-efi.py | 7 +++++++ 1 file changed, 7 insertions(+) v7: replaced "systemd-boot" with "EFI loaders" in debug message since files can be from any EFI loader or app v6: no changes v5: separated from modular kernel changes, changed from shell "ls" command to python glob diff --git a/scripts/lib/wic/plugins/source/bootimg-efi.py b/scripts/lib/wic/plugins/source/bootimg-efi.py index 96c710bf77ad..38da5080fb47 100644 --- a/scripts/lib/wic/plugins/source/bootimg-efi.py +++ b/scripts/lib/wic/plugins/source/bootimg-efi.py @@ -367,6 +367,13 @@ class BootimgEFIPlugin(SourcePlugin): else: raise WicError("unrecognized bootimg-efi loader: %s" % source_params['loader']) + + # must have installed at least one EFI bootloader + out = glob(os.path.join(hdddir, 'EFI', 'BOOT', 'boot*.efi')) + logger.debug("Installed EFI loader files:\n%s" % out) + if not out: + raise WicError("No EFI loaders installed to ESP partition. Check that grub-efi, systemd-boot or similar is installed.") + except KeyError: raise WicError("bootimg-efi requires a loader, none specified") From patchwork Fri May 30 11:37:42 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mikko Rapeli X-Patchwork-Id: 63893 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 88FE8C5B552 for ; Fri, 30 May 2025 11:38:35 +0000 (UTC) Received: from mail-lf1-f41.google.com (mail-lf1-f41.google.com [209.85.167.41]) by mx.groups.io with SMTP id smtpd.web11.4273.1748605107633103392 for ; Fri, 30 May 2025 04:38:27 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=icuff/nw; spf=pass (domain: linaro.org, ip: 209.85.167.41, mailfrom: mikko.rapeli@linaro.org) Received: by mail-lf1-f41.google.com with SMTP id 2adb3069b0e04-54c0fa6d455so2265880e87.1 for ; Fri, 30 May 2025 04:38:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1748605106; x=1749209906; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=FjUHs9nb7bavCpeuukQOPRRWSCF/saJplSuNvUvvSlg=; b=icuff/nwGxhb9VdCKvZYst6rPHdk0OhGJxV8vkdLBwOT1dPPuMHeWX7RGwWjZ3uYww 6zw1Qm/q3d1VxRnER++G77E/gUDOaV+ko2VzACfczbNCKP287kQPL8l6WVl389oispa4 7KRvDXQeBKxLla7xg2rwy8WA8ArhoMtXPvCnm34SAfkEIRenXZipM56kl5CwO+g3adQJ rUOyDfQ76qcMVoKGlpEtplyZOvbweHhQ2T9khwZ8HVhQmezvhAAEXgilDzkHptXzLYX9 ybVc/5dlE6IiSpIpXQcJlb76t7pxF9p0SUvuKdbMcXq+j/+SDxPn8ycxwnc+8EyOU7BZ jgBA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1748605106; x=1749209906; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=FjUHs9nb7bavCpeuukQOPRRWSCF/saJplSuNvUvvSlg=; b=BeeQFqGlsF9i9KM80OWDAJgvhET/V1aRnlcje0OEuW2O1U10b5Rxs+9xh1B9qKGrRV 7xrZZfORR6pNT/lrmBzxw4WrpvxjuLAjWusLN2MD2K5dbOGYBchcY9I8Fuvrt75iIBVc 7D7m1juUpGd7iSwdfDH/EgzuRIL8LJzeOdoBS64T2oQ4dPqxs9QrOr7goQyaGsyHUhmp TrEgp6ZKm+vJmOL0BakGiLHs47DeM3FVZV+1MjBNnJwv24vQ2j00zMwHdbf633K9QAo8 3tEt8MZA9zt2m2Y0Z80PBlkc5o+u/ZTpD7a4GSJ17UlhtDhU/m7QoFoiZW7yhHZooLVY i7iA== X-Gm-Message-State: AOJu0YwVQHwUbaqt4yp134HJYanpQMYE9IKUNNSTwajiL8qspSjmutD+ XhMoF1ZrsHKGwwUskWVRGU5/IObNb6r8OR6ByAQJOfBHdXyctwannAQifXGOpKH8xYkKDMi/86u H7hkEBSg= X-Gm-Gg: ASbGncse9rUiD8OHYwETEq3d/gnAmG/VRTEBByuqbV3pKqXbsllgV5y6SHgYMQ2MuXn OuRfWgkoFhXztM6Eetdc5fOWQH+/2XR9HMp6+p3xzfcN13kadw/xQw2V6XCzajxj/TevpLuU05b y4/gnkfgAvv2WjzC1WoAYPh/AHW45waowXK0pdnS3Z587LyhHPvvJQ0URjhkhg865rztsxhP9bA SR+cyEHoQMmu5jb/KOVw/f1n+4VMDFSXM4+XVfZY76Lg7artV95VzsM2MDl+lo4O+p+cDARsBT+ 7QjxkCqR/1wty4Qy4u++m/Sz9pFYt+qB6MxvViIT3zwQ6oPcXt3KctbmB6s+lLDlihzqaHtM6J3 DKu1Xm6//AcSVA0uAcmr4PM0PTzTp X-Google-Smtp-Source: AGHT+IF7mYg9qLxG+6Ly/mb3jYJjlSjeuX/7Q0TRHruPnuV72ZJfs36QMpXM0y9zVha2dAWpoS+QBQ== X-Received: by 2002:a05:6512:39cb:b0:553:23c4:6825 with SMTP id 2adb3069b0e04-5533b8f40femr855393e87.19.1748605105700; Fri, 30 May 2025 04:38:25 -0700 (PDT) Received: from localhost.localdomain (87-100-218-141.bb.dnainternet.fi. [87.100.218.141]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-553379378f7sm676469e87.244.2025.05.30.04.38.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 May 2025 04:38:25 -0700 (PDT) From: Mikko Rapeli To: openembedded-core@lists.openembedded.org Cc: Mikko Rapeli Subject: [PATCH v7 2/5] image_types_wic.bbclass: depend on grub-efi and systemd-boot on aarch64, systemd-boot on arm Date: Fri, 30 May 2025 14:37:42 +0300 Message-ID: <20250530113745.778397-2-mikko.rapeli@linaro.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250530113745.778397-1-mikko.rapeli@linaro.org> References: <20250530113745.778397-1-mikko.rapeli@linaro.org> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 30 May 2025 11:38:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/217498 On x86 family builds, grub and systemd-boot are always included and thus get built and deployed before wic image builds. On aarch64 builds that was not the case. Result is that some builds added systemd-boot binaries to the wic image ESP partition and some not, though bugs in wic plugins contributed here too since missing files were silently ignored. Boot of such images fails since firmware is not able to load the default EFI binaries. Adding EFI_PROVIDER to WKS_FILE_DEPENDS_BOOTLOADERS is not possible because of parsing order so adding grub-efi and systemd-boot to aarch64 and systemd-boot to arm depends which makes sure their do_deploy is always executed before wic image is generated. Thus systemd-boot and grub binaries will get copied from deploy directory to the wic image ESP partition, and boot of the images succeeds. Signed-off-by: Mikko Rapeli --- meta/classes-recipe/image_types_wic.bbclass | 2 ++ 1 file changed, 2 insertions(+) v7: no changes v6: no changes v5: separated from modular kernel/systemd initrd series, os-release removal added as separate commit diff --git a/meta/classes-recipe/image_types_wic.bbclass b/meta/classes-recipe/image_types_wic.bbclass index 61f028bd7bdc..90bf8c7a60bc 100644 --- a/meta/classes-recipe/image_types_wic.bbclass +++ b/meta/classes-recipe/image_types_wic.bbclass @@ -111,6 +111,8 @@ WKS_FILE_DEPENDS_DEFAULT += "bmaptool-native cdrtools-native btrfs-tools-native # Unified kernel images need objcopy WKS_FILE_DEPENDS_DEFAULT += "virtual/cross-binutils" WKS_FILE_DEPENDS_BOOTLOADERS = "" +WKS_FILE_DEPENDS_BOOTLOADERS:aarch64 = "grub-efi systemd-boot" +WKS_FILE_DEPENDS_BOOTLOADERS:arm = "systemd-boot" WKS_FILE_DEPENDS_BOOTLOADERS:x86 = "syslinux grub-efi systemd-boot os-release" WKS_FILE_DEPENDS_BOOTLOADERS:x86-64 = "syslinux systemd-boot os-release" WKS_FILE_DEPENDS_BOOTLOADERS:x86-x32 = "syslinux grub-efi" From patchwork Fri May 30 11:37:43 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mikko Rapeli X-Patchwork-Id: 63889 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9C2AFC5B556 for ; Fri, 30 May 2025 11:38:35 +0000 (UTC) Received: from mail-lf1-f45.google.com (mail-lf1-f45.google.com [209.85.167.45]) by mx.groups.io with SMTP id smtpd.web11.4274.1748605109789807184 for ; Fri, 30 May 2025 04:38:30 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=eX+9q1Oo; spf=pass (domain: linaro.org, ip: 209.85.167.45, mailfrom: mikko.rapeli@linaro.org) Received: by mail-lf1-f45.google.com with SMTP id 2adb3069b0e04-5533302b49bso2651900e87.2 for ; Fri, 30 May 2025 04:38:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1748605108; x=1749209908; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=P0mlCDrgYckIp92Y3FKrghSywetzTIukwUY7alTTUCc=; b=eX+9q1OoEsiVbSOtnl2X5i/2y6cpfU0nSW9liw9u3McUdUEjvIaZzWFyUKyDlnTR9P mwa7HSAXlV9uO2g8g30kDb7p+Crxkqwgnn0kTIYSnbSDhQgVeh0Yhx+c9cRA39beTjn3 rtEW4bf8KRBi+H5xYGJz+9fcFVtA/4z036GF9Zs6iCDc+iOal1/4cXAmARJ43mOWlzST IRbYjwt4VJ4kEPp9Eldxqy1hJ9qxKNvJ3KlkhxhtG3WFIxpWabma7CQFZpFUTs3LoRU3 2Hh6TMrx0GdFjGsS3aEnRrYZMEb9GCsse9TElJpgdyZom514sBklJ+v2PCEqTU2lFwOj djmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1748605108; x=1749209908; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=P0mlCDrgYckIp92Y3FKrghSywetzTIukwUY7alTTUCc=; b=cfBmw2qJr00rswqToBFvC5BhzzCTvujgf6mVAUgai2yjrh5yg1qJoANFLVqA2VXAlQ bg0WkrsVw70cNxM9RnTjFPMcp+zV4IGZmTO/fgIRL3aPCHi5WGFt4HX5LT08NtIw6jaa Ve/r1hd4SnTSFCvu5Gz0QiLnw/ZsjodB7XsFh8dR63U7IkSaOJ90iBDBBgg6CvVojUgs SjFjZkoQqsMCl+qFjiyQoFWl/orFDrhqTKFTPo8UpDhb5rrTG4LFXKXF1p23vphDX+Az ZL0pGIaAwerooqUk7yIlxuCmzPehY82hyvoySHpfvLoIvKTf6FoguHKy8yQGsHo8uLDf 3PBQ== X-Gm-Message-State: AOJu0YyDizAehCuVT6Z2+NTmDygdjIB584i1R9iSsK4Xy2MUykjz9xKn +JykwjQVPzNKGIMOJaVUpkPirTqacoRMx/B47NAgvwBlbK99BoKeNBLn9RjA3nVRbimzmCCo0yZ RoL7KTE0= X-Gm-Gg: ASbGncuANysWgLV/yNTlxzKyKrZS2TE4sj7CUEXH21Yfj98M7aYHd/ThEhXtLvsouG0 UtpMI01xwvzaH516kdQEzsM+eK3sT748zc7fqoX7fIwat37k4t/FXzSpxjUwJW7dqX8+iK9ujw2 kf/RfE0N5LFOIFNpEEo0LFs2cZVTIpQkCyBKtgVJ5f8/dn1SAdQO2Jwfjm7ZCjrqIw698Ybb44v P7euvpSpggzqsgEK/DSJbu0gvxGv+6xv1Ws+pVj70RoMHrdUPqmY9UhJMjxhLKt/NdKxvNMpOq1 RN4ndjwLr3xWFlmaW8jyKuAP5i3GmPSU4yiaebEjT+aMsufA1IDwovpDRvgvm2sS507FWVg+yG0 FCM95KshXu87y9vd5BOTrXXVe05J5pc1ZCyv29VrdaJSkN3yeGg== X-Google-Smtp-Source: AGHT+IHp9If0pZOk7hqToQ7v2HXugCp1KUZdf+V/vffIzhdBczoF7V0gGuv8/7Wz4CboXmotSfpNEw== X-Received: by 2002:a05:6512:ad1:b0:553:2486:e0fd with SMTP id 2adb3069b0e04-5533b8f5559mr956853e87.23.1748605107842; Fri, 30 May 2025 04:38:27 -0700 (PDT) Received: from localhost.localdomain (87-100-218-141.bb.dnainternet.fi. [87.100.218.141]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-553379378f7sm676469e87.244.2025.05.30.04.38.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 May 2025 04:38:27 -0700 (PDT) From: Mikko Rapeli To: openembedded-core@lists.openembedded.org Cc: Mikko Rapeli Subject: [PATCH v7 3/5] image_types_wic.bbclass: remove os-release from WKS_FILE_DEPENDS_BOOTLOADERS on x86 and x86_64 Date: Fri, 30 May 2025 14:37:43 +0300 Message-ID: <20250530113745.778397-3-mikko.rapeli@linaro.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250530113745.778397-1-mikko.rapeli@linaro.org> References: <20250530113745.778397-1-mikko.rapeli@linaro.org> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 30 May 2025 11:38:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/217499 os-release was needed with UKI generation when this was done using wic plugin but now with separate uki.bbclass wic does not need it anymore. Signed-off-by: Mikko Rapeli --- meta/classes-recipe/image_types_wic.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) v7: no changes v6: no changes diff --git a/meta/classes-recipe/image_types_wic.bbclass b/meta/classes-recipe/image_types_wic.bbclass index 90bf8c7a60bc..a64beda95e5f 100644 --- a/meta/classes-recipe/image_types_wic.bbclass +++ b/meta/classes-recipe/image_types_wic.bbclass @@ -113,8 +113,8 @@ WKS_FILE_DEPENDS_DEFAULT += "virtual/cross-binutils" WKS_FILE_DEPENDS_BOOTLOADERS = "" WKS_FILE_DEPENDS_BOOTLOADERS:aarch64 = "grub-efi systemd-boot" WKS_FILE_DEPENDS_BOOTLOADERS:arm = "systemd-boot" -WKS_FILE_DEPENDS_BOOTLOADERS:x86 = "syslinux grub-efi systemd-boot os-release" -WKS_FILE_DEPENDS_BOOTLOADERS:x86-64 = "syslinux systemd-boot os-release" +WKS_FILE_DEPENDS_BOOTLOADERS:x86 = "syslinux grub-efi systemd-boot" +WKS_FILE_DEPENDS_BOOTLOADERS:x86-64 = "syslinux systemd-boot" WKS_FILE_DEPENDS_BOOTLOADERS:x86-x32 = "syslinux grub-efi" WKS_FILE_DEPENDS ??= "${WKS_FILE_DEPENDS_DEFAULT} ${WKS_FILE_DEPENDS_BOOTLOADERS}" From patchwork Fri May 30 11:37:44 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mikko Rapeli X-Patchwork-Id: 63892 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id A5712C5B55A for ; Fri, 30 May 2025 11:38:35 +0000 (UTC) Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) by mx.groups.io with SMTP id smtpd.web10.4133.1748605111135908206 for ; Fri, 30 May 2025 04:38:31 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=aBMlSzHX; spf=pass (domain: linaro.org, ip: 209.85.167.51, mailfrom: mikko.rapeli@linaro.org) Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-54acc0cd458so2463565e87.0 for ; Fri, 30 May 2025 04:38:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1748605109; x=1749209909; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=5ZgnfNgk1d50UXfggC4xfzDpN2MVKZ499dDNvFRONco=; b=aBMlSzHXnAEF2HEIdRDtbOCF3qEO47ypm8uQPncKwaB7VXF0N36O18FB+vjvN8sxLt oobG91DA4mAXVdF2qOIhlV4qHvlqmtbG+Imy/Nhdi91tefNCYVya+e9KXoONTxK4Ldnr k+hJexSqNhcPLp12u6xgv1yn1ZjfW0cQb0S6mBaSS/4YhrahJ/VtSoRcKUcJTwtA8LSe 5NhAqAZ2DJtGhr5bCEAr1o8yBFlqhyNo5yUXr4rPIC8pQN/Sg+hVw1inJXvcUe4HksW3 xBHPlMp2NRKboWJ5P9zTzMtOgn1LUbUo94BsS5kjR2UmskWnar+Bs1LElJUWFLfOYJCE IUWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1748605109; x=1749209909; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=5ZgnfNgk1d50UXfggC4xfzDpN2MVKZ499dDNvFRONco=; b=uKVEOErPc0zz2rr3VrTB5p7AdwBPILNU6BbCzQ5htp1hzdFSs2S0SOQlqXTuh8dpOF N0xzNVbAbScSRJwnBKA0vDM1hJCSLkG8KiXz1bpOxtL3Cdq22qmofPOwspBTOjwbdzSk sKizpbrT08wuWLnlctWrvptZmOS2ZRLJ0RKZrC0DDuk8Kw+caSbaG5IccLwsorRxXH6f t8tkYlzKcZcUHDWKdtixFBYJA9kkhCQ2/5LuBQjlFxUZDUS8whIXDegTZa0tpyH/RZaN kMsNGyjZRxGJLla3p1jSsQNb8M1mdM7wY5ECcMTrtgJA5GCHElezKUj3851eMX0kwJZX 81Kw== X-Gm-Message-State: AOJu0YyrbKWsJoJFkfNhqAZ7dt7VZfH9q8lJXdmLUa8O19PzUcC+8sr3 u20YurFZyuprU92N+Cq+Tjx5anY9gMDUeK2CDJ7q4a8Yxwlscz1Hg4qGzVRIx8/7Uaky2VV8sEm hNKr/i0k= X-Gm-Gg: ASbGncsEiZQj32lRBeyjdcUSWRq9L73mEOLGgGd3icPv//Xe4YS2rd5VChAPDZFnUH/ nFu9qnbShozZYPxoUX5ZbpODnIDXKspi3yvBxrr+3gjiWVsGyif7bC4zkKDMkt7VFCO54sG153O QWBZss5wNqmUYvPDp8vHQuV5ifN4wLwp4bbMKkpvSNXT92IW7NfeFjoPfYA0/PF+6XlpulSAw8B EpJhL72kxtAZBWYaaRMBlQqK48w7us3fOX9wpm0iv2iVo2Dudim/vKVp6Lao584ercEJu1Onxfq uww/zyMVB7Gp3EH/5aD9QdWG3HFkVvM5Xkx7S6XnucMqfYZ/m/I2kanIaExCUP0Cd1OKXarkYUP gEJoEYhFrWqAX5V/Vmk7+GJsBRT9EOLrPk5JXZ7A= X-Google-Smtp-Source: AGHT+IHDOgki2t5qGY81hKxX0+EoJLhhxKLBcLYYE6xwxZdYSzkWiw0XlDgfcUlUOvYFUCPZCpFytg== X-Received: by 2002:a05:6512:3dac:b0:553:2ca4:39e2 with SMTP id 2adb3069b0e04-5533b93a607mr882476e87.52.1748605109228; Fri, 30 May 2025 04:38:29 -0700 (PDT) Received: from localhost.localdomain (87-100-218-141.bb.dnainternet.fi. [87.100.218.141]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-553379378f7sm676469e87.244.2025.05.30.04.38.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 May 2025 04:38:28 -0700 (PDT) From: Mikko Rapeli To: openembedded-core@lists.openembedded.org Cc: Mikko Rapeli Subject: [PATCH v7 4/5] image_types_wic.bbclass: capture verbose wic output by default Date: Fri, 30 May 2025 14:37:44 +0300 Message-ID: <20250530113745.778397-4-mikko.rapeli@linaro.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250530113745.778397-1-mikko.rapeli@linaro.org> References: <20250530113745.778397-1-mikko.rapeli@linaro.org> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 30 May 2025 11:38:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/217500 Call wic with --debug to capture logs from wic internals so that it's clear which partitions get created and which files get copied where. wic plugins contain for example race conditions which don't install files at all and thus images fail to boot and it's not possible to debug these without something in wic task logs. As an example core-image-initramfs-boot do_image_wic log is now 576 lines which is not excessive but very important when debugging problems, especially race conditions which are only hit in some builds in CI. With all issues I have to deal within wic, I always need to apply this change before I get to see any details what wic and its plugins are doing. Thus I strongly believe this verbose outuput should be the default. Signed-off-by: Mikko Rapeli --- meta/classes-recipe/image_types_wic.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) v7: no changes v6: no changes but this change helped to resolve issues in v5 series v5: no changes, v4 caused pseudo aborts on autobuilder but these are likely fixed now after path inclusion list changes v4: https://lists.openembedded.org/g/openembedded-core/message/215221 v3: https://lists.openembedded.org/g/openembedded-core/message/214360 diff --git a/meta/classes-recipe/image_types_wic.bbclass b/meta/classes-recipe/image_types_wic.bbclass index a64beda95e5f..7c6a6f2e2307 100644 --- a/meta/classes-recipe/image_types_wic.bbclass +++ b/meta/classes-recipe/image_types_wic.bbclass @@ -72,7 +72,7 @@ IMAGE_CMD:wic () { if [ -z "$wks" ]; then bbfatal "No kickstart files from WKS_FILES were found: ${WKS_FILES}. Please set WKS_FILE or WKS_FILES appropriately." fi - BUILDDIR="${TOPDIR}" PSEUDO_UNLOAD=1 wic create "$wks" --vars "${STAGING_DIR}/${MACHINE}/imgdata/" -e "${IMAGE_BASENAME}" -o "$build_wic/" -w "$tmp_wic" ${WIC_CREATE_EXTRA_ARGS} + BUILDDIR="${TOPDIR}" PSEUDO_UNLOAD=1 wic create --debug "$wks" --vars "${STAGING_DIR}/${MACHINE}/imgdata/" -e "${IMAGE_BASENAME}" -o "$build_wic/" -w "$tmp_wic" ${WIC_CREATE_EXTRA_ARGS} # look to see if the user specifies a custom imager IMAGER=direct From patchwork Fri May 30 11:37:45 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mikko Rapeli X-Patchwork-Id: 63891 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8DF27C5B549 for ; Fri, 30 May 2025 11:38:35 +0000 (UTC) Received: from mail-lf1-f54.google.com (mail-lf1-f54.google.com [209.85.167.54]) by mx.groups.io with SMTP id smtpd.web11.4276.1748605112479004880 for ; Fri, 30 May 2025 04:38:32 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=iZJRifjc; spf=pass (domain: linaro.org, ip: 209.85.167.54, mailfrom: mikko.rapeli@linaro.org) Received: by mail-lf1-f54.google.com with SMTP id 2adb3069b0e04-5532f6d184eso2649469e87.0 for ; Fri, 30 May 2025 04:38:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1748605111; x=1749209911; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=+5pK56p6iC0Z26KB1uEbG9XW8rWxtG5WhgMWISzm9nk=; b=iZJRifjcJgqMbsdTHXhYVTWA/y3P65qnXNvamaaZMcn/QIotwCiK5qyKKWHudP60t1 Wig0sWPUUIAdE+HgC/uT/lg/T6cxKPcNCYmkmuMynuThsAv3U6l9zdkdCbdK8W3Mymbs D+WHR3mni/5dyzQ9j1/Lwds1RMqfq5Hvfl9pTVC8xPwBTE0KTgGjTNOWYctDTRlB4men YBQcBEZrg860VVUVSMED39fCQzcJPhlz6ufQK6hMeEUMBXlX0RAFTTJRwocjphIoWBgF gibgRR4HlHZAUxakmEk6p5LKJrf37IiULOK8YipzNBIz5zbrrooyeJqIcp5GKOV1iS47 X+Uw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1748605111; x=1749209911; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+5pK56p6iC0Z26KB1uEbG9XW8rWxtG5WhgMWISzm9nk=; b=G/KHxF7zrVKe5Oz9LdklZmbrT1m2nnsJAP0a886kl9r/00QNO4hxGeYM4eFrwaZYIQ //c/FvoI3nd1t8qVWpmXARExn5bm0vHfkoKtFEgw/RhflQ7IsaH+itoVck9yltqkMkMi rRizavDLhZ8dNt5amALK//xnqV5gljca65XrVN7FIsDpXe/RrBcxCaEsArEMspLPmTZW ArP4WXBau4vUkHSOO7ff/oa7sQPQyYusPXqv7lr909/6OIsdgNhimGp+huLdzuJPS7Vq wFh6N4U3O9aKKZIUBHlV1xKbcHpvCQiTCJ0iMPaJ7XTMXsGDQ0BJtRrFwS62XS6Cxwkr Cc6w== X-Gm-Message-State: AOJu0YyPig1C0igBzXZ2TIqwhRbTPwQkaRnRVcK1Q4C1ZZBxILpgW/YB sDhp/Veb5Ki/8q0L4qNsA5YZ9B5FmgcKyrCeYDQU/XwS9U2PzUqhfDHtGnyrDXZ1C8qdM9oVYHy r0fJeg1s= X-Gm-Gg: ASbGnctM7CGW/JBgAe3/ihW4flGd07ePUP/fIqidEvspYrexSPM7tBv7JcEhZouslAK ZPWg+G09ffboGHMfeYcjjIyevpM2wacG6TI+qx04pBgSxrnIU9Gt3ekYod3yR6KyB1op33ciSDM x1DvOR8cWT61vf759ckXWPZ3yW2rm02V4qc2wvSOLHks1rybRv0puFS0w8cw/LTZlS+CBimnHJY +7A/a8dHT9aydKqwMcFt/GaaM6v/x43w+w9qyAsgsZZ9lhIJQy9xj8lPS3b2Zwy4nRSxI19lW12 raYgKilYBtohS27n7JJWF6tUWpf1Jq6UcvXuG453Pdky1JeY/ARfWqJMDD9U9J3ejetEWHv4lP2 plmnoaYKUazAgQ7yJ+E7myLyTiwj8 X-Google-Smtp-Source: AGHT+IF1tkyYU/Xfjt7GTT2jdGBUA5eacYPCq9VUGelBGaPoIv5sPv/codcZcv8B1athkrZOZJ+LLw== X-Received: by 2002:a05:6512:b8c:b0:553:23bf:bb26 with SMTP id 2adb3069b0e04-5533b8e1115mr1080560e87.11.1748605110564; Fri, 30 May 2025 04:38:30 -0700 (PDT) Received: from localhost.localdomain (87-100-218-141.bb.dnainternet.fi. [87.100.218.141]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-553379378f7sm676469e87.244.2025.05.30.04.38.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 May 2025 04:38:30 -0700 (PDT) From: Mikko Rapeli To: openembedded-core@lists.openembedded.org Cc: Mikko Rapeli Subject: [PATCH v7 5/5] image_types_wic.bbclass: add "grub-efi" back to WKS_FILE_DEPENDS_BOOTLOADERS on x86-64 Date: Fri, 30 May 2025 14:37:45 +0300 Message-ID: <20250530113745.778397-5-mikko.rapeli@linaro.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250530113745.778397-1-mikko.rapeli@linaro.org> References: <20250530113745.778397-1-mikko.rapeli@linaro.org> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 30 May 2025 11:38:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/217501 This was removed by me without good reasons in commit 2f0ef8cd0e61c34e67ad9c7508094da3c23f5fce "wic bootimg-efi.py: change UKI support from wic plugin to uki.bbclass" and results in grub-efi binaries missing from genereted ESP partition on qemux86-64. Fixes oeqa selftest overlayfs.OverlayFSEtcRunTimeTests.test_image_feature_is_missing after wic detects missing EFI loader files on ESP partition. Test case was passing due qemu syslinux boot using kernel directly from /boot and not using UEFI firmware to boot. Fixes: 2f0ef8cd0e61 ("wic bootimg-efi.py: change UKI support from wic plugin to uki.bbclass") WKS_FILE_DEPENDS_BOOTLOADERS needs to list all EFI loaders because it's used in DEPENDS and thus can't use conditional python macros to select which loader is actually needed in sysroot when wic builds the images and ESP partition. Signed-off-by: Mikko Rapeli --- meta/classes-recipe/image_types_wic.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) v7: no changes v6: new changes in series, fixes missing grub-efi binaries on qemux86-64 overlayfs selftest diff --git a/meta/classes-recipe/image_types_wic.bbclass b/meta/classes-recipe/image_types_wic.bbclass index 7c6a6f2e2307..740ed946f8fa 100644 --- a/meta/classes-recipe/image_types_wic.bbclass +++ b/meta/classes-recipe/image_types_wic.bbclass @@ -114,7 +114,7 @@ WKS_FILE_DEPENDS_BOOTLOADERS = "" WKS_FILE_DEPENDS_BOOTLOADERS:aarch64 = "grub-efi systemd-boot" WKS_FILE_DEPENDS_BOOTLOADERS:arm = "systemd-boot" WKS_FILE_DEPENDS_BOOTLOADERS:x86 = "syslinux grub-efi systemd-boot" -WKS_FILE_DEPENDS_BOOTLOADERS:x86-64 = "syslinux systemd-boot" +WKS_FILE_DEPENDS_BOOTLOADERS:x86-64 = "syslinux grub-efi systemd-boot" WKS_FILE_DEPENDS_BOOTLOADERS:x86-x32 = "syslinux grub-efi" WKS_FILE_DEPENDS ??= "${WKS_FILE_DEPENDS_DEFAULT} ${WKS_FILE_DEPENDS_BOOTLOADERS}"