diff mbox series

[meta-oe,v2,1/1] pocketpy: upgrade 2.1.8 -> 2.2.0

Message ID 20260928013709.2591219-1-ankur.tyagi85@gmail.com
State Under Review
Headers show
Series [meta-oe,v2,1/1] pocketpy: upgrade 2.1.8 -> 2.2.0 | expand

Commit Message

Ankur Tyagi Sept. 28, 2026, 1:37 a.m. UTC
From: Ankur Tyagi <ankur.tyagi85@gmail.com>

Changelog:
https://github.com/pocketpy/pocketpy/releases/tag/v2.2.0

Signed-off-by: Ankur Tyagi <ankur.tyagi85@gmail.com>
---
 ...nclude-threads.h-for-c11_thrd__yield.patch | 31 +++++++++++++++++++
 .../{pocketpy_2.1.8.bb => pocketpy_2.2.0.bb}  |  6 ++--
 2 files changed, 35 insertions(+), 2 deletions(-)
 create mode 100644 meta-oe/recipes-devtools/pocketpy/pocketpy/0001-time-include-threads.h-for-c11_thrd__yield.patch
 rename meta-oe/recipes-devtools/pocketpy/{pocketpy_2.1.8.bb => pocketpy_2.2.0.bb} (87%)
diff mbox series

Patch

diff --git a/meta-oe/recipes-devtools/pocketpy/pocketpy/0001-time-include-threads.h-for-c11_thrd__yield.patch b/meta-oe/recipes-devtools/pocketpy/pocketpy/0001-time-include-threads.h-for-c11_thrd__yield.patch
new file mode 100644
index 0000000000..b4300128fa
--- /dev/null
+++ b/meta-oe/recipes-devtools/pocketpy/pocketpy/0001-time-include-threads.h-for-c11_thrd__yield.patch
@@ -0,0 +1,31 @@ 
+From e3c1a60242c551fd7db266b9d0db6b3710d057fd Mon Sep 17 00:00:00 2001
+From: Ankur Tyagi <ankur.tyagi85@gmail.com>
+Date: Mon, 28 Sep 2026 14:20:30 +1300
+Subject: [PATCH] time: include threads.h for c11_thrd__yield
+
+time_sleep() calls c11_thrd__yield() when PK_ENABLE_THREADS is set,
+but time.c does not include pocketpy/common/threads.h. This only
+builds with the CMake Unity build, where an earlier translation unit
+pulls in the header. With PK_BUILD_WITH_UNITY=OFF it fails with:
+
+  error: implicit declaration of function 'c11_thrd__yield'
+
+Upstream-Status: Submitted [https://github.com/pocketpy/pocketpy/pull/546]
+Assisted-by: GitHub Copilot:claude-opus-5.5
+Signed-off-by: Ankur Tyagi <ankur.tyagi85@gmail.com>
+---
+ src/modules/time.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/modules/time.c b/src/modules/time.c
+index fd16a57..ac18037 100644
+--- a/src/modules/time.c
++++ b/src/modules/time.c
+@@ -10,6 +10,7 @@
+ #endif
+ 
+ #include "pocketpy/pocketpy.h"
++#include "pocketpy/common/threads.h"
+ #include <assert.h>
+ 
+ #define NANOS_PER_SEC 1000000000
diff --git a/meta-oe/recipes-devtools/pocketpy/pocketpy_2.1.8.bb b/meta-oe/recipes-devtools/pocketpy/pocketpy_2.2.0.bb
similarity index 87%
rename from meta-oe/recipes-devtools/pocketpy/pocketpy_2.1.8.bb
rename to meta-oe/recipes-devtools/pocketpy/pocketpy_2.2.0.bb
index 7f3775941a..5df9301880 100644
--- a/meta-oe/recipes-devtools/pocketpy/pocketpy_2.1.8.bb
+++ b/meta-oe/recipes-devtools/pocketpy/pocketpy_2.2.0.bb
@@ -13,8 +13,10 @@  BUGTRACKER = "https://github.com/pocketpy/pocketpy/issues"
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=224889df377610675315e194ac59276c"
 
-SRC_URI = "git://github.com/pocketpy/pocketpy.git;protocol=https;branch=main;tag=v${PV}"
-SRCREV = "a2f16e5f1f5fcc3b3d2cc1bdacfc3a027dfe2d76"
+SRC_URI = "git://github.com/pocketpy/pocketpy.git;protocol=https;branch=main;tag=v${PV} \
+           file://0001-time-include-threads.h-for-c11_thrd__yield.patch \
+           "
+SRCREV = "6cbece9ebc98c19fa2c189dc6963b421c22c40ae"
 
 
 inherit cmake