From 32c5126b654d17124b9ea3ee29bc03bb308389b2 Mon Sep 17 00:00:00 2001 From: MarsDoge Date: Fri, 5 Jun 2026 11:52:13 +0800 Subject: [PATCH] fix(lvgl): re-pin submodule to upstream-fetchable commit + edk2 shims PR #38 pinned External/lvgl at 4cdddfe, a local PR-branch SHA that does not exist on upstream lvgl/lvgl, so fresh clones can't fetch the submodule. Re-pin to the upstream merged commit 0b1ea312d (v9.5.0-273, PR #10221). That commit carries unrelated v9.5.0->273 churn, handled edk2-side without patching the submodule: drop dead wayland sources from LvglCoreLib.inf, add a documented empty efi.h shim for PR #10041's unconditional gnu-efi include, and switch spike sources to the umbrella instead of deprecated lvgl/src/drivers/uefi/* headers. Validated: OVMF X64 lvgl-mode build, LoongArch lvgl spike build, smoke. Co-Authored-By: Claude Opus 4.8 --- CHANGELOG.md | 24 ++++++++----- .../Include/Library/LvglCoreLib.h | 3 -- .../Library/LvglLib/LvglCoreLib.inf | 10 ------ .../Library/LvglLib/LvglSpikeProbe.c | 3 -- .../LvglSpikePkg/Library/LvglLib/efi.h | 35 +++++++++++++++++++ External/lvgl | 2 +- 6 files changed, 52 insertions(+), 25 deletions(-) create mode 100644 Experimental/LvglSpikePkg/Library/LvglLib/efi.h diff --git a/CHANGELOG.md b/CHANGELOG.md index 88fd351..73e7077 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -67,14 +67,22 @@ this file as both a release log and a lightweight development progress record. English values + all chrome) render end-to-end through LVGL. - Experimental LVGL rendering-backend spike (`experimental/lvgl-spike` branch only; `Experimental/LvglSpikePkg`, never in a default overlay or `ModernSetupApp`). - Pins `External/lvgl` at a tagged v9.5.0-derived baseline and validates that - LVGL core + software renderer + its upstream UEFI port build under edk2 GCC on - a hard architecture: `LvglSpikeProbe.efi` compiles for LoongArch64 and was run - on real LoongArch hardware, drawing an LVGL UI straight to GOP (standalone-app - path, not via any DisplayEngine). The ~3-site LoongArch64/RISC-V64 UEFI - arch-gate change was contributed upstream and is now in the pinned baseline, so - `External/lvgl` is consumed pristine (no local patch, no build-time patching). - See `Experimental/LvglSpikePkg/README.md`. + Pins `External/lvgl` at the upstream commit `0b1ea312d` (`v9.5.0-273`), which + is upstream lvgl/lvgl master carrying the merged LoongArch64/RISC-V64 UEFI + build support (PR #10221). Validates that LVGL core + software renderer + its + upstream UEFI port build under edk2 GCC on a hard architecture: + `LvglSpikeProbe.efi` compiles for LoongArch64 and was run on real LoongArch + hardware, drawing an LVGL UI straight to GOP (standalone-app path, not via any + DisplayEngine). The submodule is consumed pristine (no patch to `External/lvgl` + itself), with two edk2-side accommodations for unrelated upstream churn between + v9.5.0 and this commit: (1) a documented empty `efi.h` shim under + `Experimental/LvglSpikePkg/Library/LvglLib/` that satisfies an unconditional + `#include ` introduced by the header reorg PR #10041 (the EDK2 framework + path is selected via `LV_USE_UEFI_INCLUDE`, so the shim pulls in no gnu-efi + types); and (2) our spike sources include the canonical `` umbrella + instead of the now-deprecated `lvgl/src/drivers/uefi/*` public headers. Both are + removable once upstream gates the gnu-efi include behind the framework + selection. See `Experimental/LvglSpikePkg/README.md`. - ModernSetupApp header clock now updates live while the front page is idle. The app loop arms a one-second periodic timer and waits on it alongside the keyboard/pointer sources, repainting only the header clock text in place on diff --git a/Experimental/LvglSpikePkg/Include/Library/LvglCoreLib.h b/Experimental/LvglSpikePkg/Include/Library/LvglCoreLib.h index 1f00545..78a0975 100644 --- a/Experimental/LvglSpikePkg/Include/Library/LvglCoreLib.h +++ b/Experimental/LvglSpikePkg/Include/Library/LvglCoreLib.h @@ -11,8 +11,5 @@ #define LVGL_CORE_LIB_H_ #include "lvgl/lvgl.h" -#include "lvgl/src/drivers/uefi/lv_uefi.h" -#include "lvgl/src/drivers/uefi/lv_uefi_context.h" -#include "lvgl/src/drivers/uefi/lv_uefi_display.h" #endif // LVGL_CORE_LIB_H_ diff --git a/Experimental/LvglSpikePkg/Library/LvglLib/LvglCoreLib.inf b/Experimental/LvglSpikePkg/Library/LvglLib/LvglCoreLib.inf index 81c00b9..c651b67 100644 --- a/Experimental/LvglSpikePkg/Library/LvglLib/LvglCoreLib.inf +++ b/Experimental/LvglSpikePkg/Library/LvglLib/LvglCoreLib.inf @@ -232,16 +232,6 @@ lvgl/src/drivers/uefi/lv_uefi_indev_pointer.c lvgl/src/drivers/uefi/lv_uefi_indev_touch.c lvgl/src/drivers/uefi/lv_uefi_private.c - lvgl/src/drivers/wayland/lv_wayland.c - lvgl/src/drivers/wayland/lv_wl_egl_backend.c - lvgl/src/drivers/wayland/lv_wl_g2d_backend.c - lvgl/src/drivers/wayland/lv_wl_keyboard.c - lvgl/src/drivers/wayland/lv_wl_pointer.c - lvgl/src/drivers/wayland/lv_wl_seat.c - lvgl/src/drivers/wayland/lv_wl_shm_backend.c - lvgl/src/drivers/wayland/lv_wl_touch.c - lvgl/src/drivers/wayland/lv_wl_window.c - lvgl/src/drivers/wayland/lv_wl_xdg_shell.c lvgl/src/drivers/windows/lv_windows_context.c lvgl/src/drivers/windows/lv_windows_display.c lvgl/src/drivers/windows/lv_windows_input.c diff --git a/Experimental/LvglSpikePkg/Library/LvglLib/LvglSpikeProbe.c b/Experimental/LvglSpikePkg/Library/LvglLib/LvglSpikeProbe.c index eccd952..2c90fda 100644 --- a/Experimental/LvglSpikePkg/Library/LvglLib/LvglSpikeProbe.c +++ b/Experimental/LvglSpikePkg/Library/LvglLib/LvglSpikeProbe.c @@ -20,9 +20,6 @@ #include #include "lvgl/lvgl.h" -#include "lvgl/src/drivers/uefi/lv_uefi.h" -#include "lvgl/src/drivers/uefi/lv_uefi_context.h" -#include "lvgl/src/drivers/uefi/lv_uefi_display.h" /** Build the demo UI on the active screen: dark background, a large title, a diff --git a/Experimental/LvglSpikePkg/Library/LvglLib/efi.h b/Experimental/LvglSpikePkg/Library/LvglLib/efi.h new file mode 100644 index 0000000..3182bfd --- /dev/null +++ b/Experimental/LvglSpikePkg/Library/LvglLib/efi.h @@ -0,0 +1,35 @@ +/** @file + EDK2-side shim that satisfies LVGL's unconditional `#include `. + + TEMPORARY WORKAROUND. The pinned upstream `External/lvgl` + (commit 0b1ea312d, v9.5.0-273) inherits PR #10041 ("arch: move public headers + to include folder"), which makes the umbrella header `` + unconditionally `#include "drivers/uefi/lv_uefi_gnu_efi.h"`. That header in + turn does `#include ` (the gnu-efi framework header) whenever + `LV_USE_UEFI` is set -- even though this build selects the EDK2 framework via + `LV_USE_UEFI_INCLUDE = "lv_uefi_edk2.h"` and obtains every EFI type from + ``. EDK2 ships no ``, so the gnu-efi include is a hard error. + + This empty header satisfies that include harmlessly: `lv_uefi_gnu_efi.h` only + `#define`s `LV_UEFI_GNU_EFI_HEADERS` (no code branches on it to switch types) + and includes us; it pulls in zero gnu-efi types, so the EDK2 header path that + `lv_uefi_edk2.h` already established is left untouched. There is no EDK2/gnu-efi + mutual-exclusion check upstream, so both `*_HEADERS` macros being defined is + benign. + + Remove this file once the upstream guard fix lands -- gate the gnu-efi + `#include ` behind the framework selection so EDK2 builds skip it -- and + `External/lvgl` is re-pinned to an upstream commit that carries that fix. + + Copyright (c) 2026, MarsDoge. All rights reserved.
+ SPDX-License-Identifier: BSD-2-Clause-Patent +**/ + +#ifndef MODERNUI_LVGL_EDK2_EFI_H_SHIM_ +#define MODERNUI_LVGL_EDK2_EFI_H_SHIM_ + +// +// Intentionally empty. EFI types come from EDK2 via lv_uefi_edk2.h. +// + +#endif // MODERNUI_LVGL_EDK2_EFI_H_SHIM_ diff --git a/External/lvgl b/External/lvgl index 4cdddfe..0b1ea31 160000 --- a/External/lvgl +++ b/External/lvgl @@ -1 +1 @@ -Subproject commit 4cdddfe4ae6aaf08c713d86673f5675875415998 +Subproject commit 0b1ea312de6287984db9ed46ddc1291fbecc7895