package/micropython: libffi is optional, not mandatory

libffi is optional, not mandatory since bump to version 1.22.0 in commit
1e12b7dd49 and
89b3207376

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
This commit is contained in:
Fabrice Fontaine 2024-01-16 19:36:29 +01:00 committed by Yann E. MORIN
parent 0c6ffa5513
commit 2c1cac10d8
2 changed files with 8 additions and 2 deletions

View File

@ -2,7 +2,6 @@ config BR2_PACKAGE_MICROPYTHON
bool "micropython"
depends on BR2_TOOLCHAIN_HAS_THREADS
depends on !BR2_STATIC_LIBS
select BR2_PACKAGE_LIBFFI
help
Micro Python is a lean and fast implementation of the Python
3 programming language that is optimised to run on a

View File

@ -12,7 +12,7 @@ MICROPYTHON_SOURCE = micropython-$(MICROPYTHON_VERSION).tar.xz
# and most of the copied code is not used in the unix build.
MICROPYTHON_LICENSE = MIT, BSD-1-Clause, BSD-3-Clause, Zlib
MICROPYTHON_LICENSE_FILES = LICENSE
MICROPYTHON_DEPENDENCIES = host-pkgconf libffi host-python3
MICROPYTHON_DEPENDENCIES = host-python3
MICROPYTHON_CPE_ID_VENDOR = micropython
# Use fallback implementation for exception handling on architectures that don't
@ -36,6 +36,13 @@ MICROPYTHON_MAKE_OPTS += \
LDFLAGS_EXTRA="$(TARGET_LDFLAGS)" \
CWARN=
ifeq ($(BR2_PACKAGE_LIBFFI),y)
MICROPYTHON_DEPENDENCIES += host-pkgconf libffi
MICROPYTHON_MAKE_OPTS += MICROPY_PY_FFI=1
else
MICROPYTHON_MAKE_OPTS += MICROPY_PY_FFI=0
endif
define MICROPYTHON_BUILD_CMDS
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D)/mpy-cross
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D)/ports/unix \