mirror of
https://github.com/apache/nuttx-apps.git
synced 2025-10-17 15:32:21 +08:00

NuttX implements a function with the same name which may end up being included whenever `CONFIG_MM_KERNEL_HEAP` is set. To avoid it, insert a prefix to it on Python's implementation. Please note that the other patches had their metadata updated too.
34 lines
1003 B
Diff
34 lines
1003 B
Diff
From 954d39ba94e772940486575e35d586ba1cf738e3 Mon Sep 17 00:00:00 2001
|
|
From: Tiago Medicci <tiago.medicci@espressif.com>
|
|
Date: Fri, 31 Jan 2025 14:06:21 -0300
|
|
Subject: [PATCH 13/14] transform functions used by NuttX to lowercase
|
|
|
|
---
|
|
Include/pylifecycle.h | 10 ++++++++++
|
|
1 file changed, 10 insertions(+)
|
|
|
|
diff --git a/Include/pylifecycle.h b/Include/pylifecycle.h
|
|
index de1bcb1d2cb..044780ee188 100644
|
|
--- a/Include/pylifecycle.h
|
|
+++ b/Include/pylifecycle.h
|
|
@@ -33,6 +33,16 @@ PyAPI_FUNC(void) _Py_NO_RETURN Py_Exit(int);
|
|
PyAPI_FUNC(int) Py_Main(int argc, wchar_t **argv);
|
|
PyAPI_FUNC(int) Py_BytesMain(int argc, char **argv);
|
|
|
|
+#if defined(__NuttX__)
|
|
+#define py_bytesmain Py_BytesMain
|
|
+#endif
|
|
+
|
|
+void _PyRuntime_Early_Init(void);
|
|
+
|
|
+#if defined(__NuttX__)
|
|
+#define _pyruntime_early_init _PyRuntime_Early_Init
|
|
+#endif
|
|
+
|
|
/* In pathconfig.c */
|
|
Py_DEPRECATED(3.11) PyAPI_FUNC(void) Py_SetProgramName(const wchar_t *);
|
|
Py_DEPRECATED(3.13) PyAPI_FUNC(wchar_t *) Py_GetProgramName(void);
|
|
--
|
|
2.50.0
|
|
|