micropython-lib: update to 1.23.0 and fix compile on external mbedtls3
authorGlenn Strauss <gstrauss@gluelogic.com>
Thu, 25 Jul 2024 06:44:12 +0000 (02:44 -0400)
committerRosen Penev <rosenp@gmail.com>
Mon, 18 Nov 2024 05:40:15 +0000 (21:40 -0800)
* update micropython-lib to hash for 1.23.0
* remove micropython-lib unix-uffi patches

Co-authored-by: Jeffery To <jeffery.to@gmail.com>
Signed-off-by: Glenn Strauss <gstrauss@gluelogic.com>
lang/python/micropython-lib/Makefile
lang/python/micropython-lib/patches/001-build-unix-ffi.patch
lang/python/micropython-lib/patches/002-add-unix-ffi-os-path.patch [deleted file]
lang/python/micropython-lib/patches/003-add-unix-ffi-uu.patch [deleted file]

index d5fdd77fda04e6e93831bbcb4a0f8af3bf0859dc..fd9b31594b15721d20919b954ab02cbdbefac8aa 100644 (file)
@@ -12,9 +12,9 @@ PKG_RELEASE:=1
 
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_URL:=https://github.com/micropython/micropython-lib.git
-PKG_SOURCE_VERSION:=d8e163bb5f3ef45e71e145c27bc4f207beaad70f
-PKG_SOURCE_DATE:=20231031
-PKG_MIRROR_HASH:=311651a719ae645d3e40c3c8ebf706fa2e964ac1455d84bee73606ec6d7c13a2
+PKG_SOURCE_VERSION:=50ed36fbeb919753bcc26ce13a8cffd7691d06ef
+PKG_SOURCE_DATE:=20240525
+PKG_MIRROR_HASH:=c03c4226c461079d529b72456569797d3f87f0970e78d1c7c4d6c34d32586af4
 
 PKG_MAINTAINER:=Jeffery To <jeffery.to@gmail.com>
 PKG_LICENSE:=MIT Python-2.0.1
index 4dfaca6f9103f7342f0621cedcb5141303082370..c45190c8969b806b873ae25d919537b7234d245b 100644 (file)
@@ -9,16 +9,19 @@
      import manifestfile
      import mpy_cross
  
-@@ -310,7 +310,7 @@ def build(output_path, hash_prefix_len,
+@@ -310,7 +310,10 @@ def build(output_path, hash_prefix_len,
  
      # For now, don't process unix-ffi. In the future this can be extended to
      # allow a way to request unix-ffi packages via mip.
 -    lib_dirs = ["micropython", "python-stdlib", "python-ecosys"]
 +    lib_dirs = ["unix-ffi"] if unix_ffi else ["micropython", "python-stdlib", "python-ecosys"]
++
++    if unix_ffi:
++        manifestfile.BASE_LIBRARY_NAMES = ("unix-ffi",) + manifestfile.BASE_LIBRARY_NAMES
  
      mpy_version, _mpy_sub_version = mpy_cross.mpy_version(mpy_cross=mpy_cross_path)
      mpy_version = str(mpy_version)
-@@ -438,6 +438,7 @@ def main():
+@@ -438,6 +441,7 @@ def main():
  
      cmd_parser = argparse.ArgumentParser(description="Compile micropython-lib for serving to mip.")
      cmd_parser.add_argument("--output", required=True, help="output directory")
@@ -26,7 +29,7 @@
      cmd_parser.add_argument("--hash-prefix", default=8, type=int, help="hash prefix length")
      cmd_parser.add_argument("--mpy-cross", default=None, help="optional path to mpy-cross binary")
      cmd_parser.add_argument("--micropython", default=None, help="path to micropython repo")
-@@ -447,7 +448,7 @@ def main():
+@@ -447,7 +451,7 @@ def main():
          sys.path.append(os.path.join(args.micropython, "tools"))  # for manifestfile
          sys.path.append(os.path.join(args.micropython, "mpy-cross"))  # for mpy_cross
  
diff --git a/lang/python/micropython-lib/patches/002-add-unix-ffi-os-path.patch b/lang/python/micropython-lib/patches/002-add-unix-ffi-os-path.patch
deleted file mode 100644 (file)
index 5ebc682..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-From dcce62dd525cf0f8e572e56a8990aea7ec2f0ade Mon Sep 17 00:00:00 2001
-From: Jeffery To <jeffery.to@gmail.com>
-Date: Tue, 30 May 2023 23:47:59 +0800
-Subject: [PATCH] unix-ffi/os-path: Add unix-ffi version of `os-path` package.
-
-This package reuses the code from the python-stdlib version of `os-path`
-but requires the unix-ffi version of `os`.
-
-This also updates `glob` to require this version of `os-path`.
-
-Signed-off-by: Jeffery To <jeffery.to@gmail.com>
----
- unix-ffi/glob/manifest.py    | 2 +-
- unix-ffi/os-path/manifest.py | 6 ++++++
- unix-ffi/os/os/__init__.py   | 6 ++++++
- 3 files changed, 13 insertions(+), 1 deletion(-)
- create mode 100644 unix-ffi/os-path/manifest.py
-
---- a/unix-ffi/glob/manifest.py
-+++ b/unix-ffi/glob/manifest.py
-@@ -1,7 +1,7 @@
- metadata(version="0.5.2")
- require("os", unix_ffi=True)
--require("os-path")
-+require("os-path", unix_ffi=True)
- require("re", unix_ffi=True)
- require("fnmatch")
---- /dev/null
-+++ b/unix-ffi/os-path/manifest.py
-@@ -0,0 +1,6 @@
-+metadata(version="0.1.4")
-+
-+# Originally written by Paul Sokolovsky.
-+
-+require("os", unix_ffi=True)
-+package("os", base_path="../../python-stdlib/os-path")
---- a/unix-ffi/os/os/__init__.py
-+++ b/unix-ffi/os/os/__init__.py
-@@ -5,6 +5,12 @@ import stat as stat_
- import ffilib
- import uos
-+# Provide optional dependencies (which may be installed separately).
-+try:
-+    from . import path
-+except ImportError:
-+    pass
-+
- R_OK = const(4)
- W_OK = const(2)
- X_OK = const(1)
diff --git a/lang/python/micropython-lib/patches/003-add-unix-ffi-uu.patch b/lang/python/micropython-lib/patches/003-add-unix-ffi-uu.patch
deleted file mode 100644 (file)
index 363fae3..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-From 2e7bfd08a306bd9e80b22097ef8fe66e1dd85054 Mon Sep 17 00:00:00 2001
-From: Jeffery To <jeffery.to@gmail.com>
-Date: Wed, 31 May 2023 00:00:11 +0800
-Subject: [PATCH] unix-ffi/uu: Add unix-ffi version of `uu` package.
-
-This package reuses the code from the python-stdlib version of `uu` but
-requires the unix-ffi version of `os-path`.
-
-This also updates `email.message` to require this version of `uu`.
-
-Signed-off-by: Jeffery To <jeffery.to@gmail.com>
----
- unix-ffi/email.message/manifest.py | 2 +-
- unix-ffi/uu/manifest.py            | 6 ++++++
- 2 files changed, 7 insertions(+), 1 deletion(-)
- create mode 100644 unix-ffi/uu/manifest.py
-
---- a/unix-ffi/email.message/manifest.py
-+++ b/unix-ffi/email.message/manifest.py
-@@ -1,7 +1,7 @@
- metadata(version="0.5.3")
- require("re", unix_ffi=True)
--require("uu")
-+require("uu", unix_ffi=True)
- require("base64")
- require("binascii")
- require("email.utils", unix_ffi=True)
---- /dev/null
-+++ b/unix-ffi/uu/manifest.py
-@@ -0,0 +1,6 @@
-+metadata(version="0.5.1")
-+
-+require("binascii")
-+require("os-path", unix_ffi=True)
-+
-+module("uu.py", base_path="../../python-stdlib/uu")