package/python3: add optional zstd support

Python 3.14 introduced a new zstd module [1][2] that requires zstd
package as dependency.

Packages that requires this new module should select
BR2_PACKAGE_PYTHON3_ZSTD.

[1] https://docs.python.org/3.14/library/compression.zstd.html
[2] https://peps.python.org/pep-0784/

Signed-off-by: Romain Naour <romain.naour@smile.fr>
[Julien: change link [1] to use 3.14 specific version]
Signed-off-by: Julien Olivain <ju.o@free.fr>
This commit is contained in:
Romain Naour
2026-02-02 19:15:26 +01:00
committed by Julien Olivain
parent e258607bc9
commit 5bfea99b11
2 changed files with 12 additions and 0 deletions

View File

@@ -127,6 +127,12 @@ config BR2_PACKAGE_PYTHON3_ZLIB
help
zlib support in Python3
config BR2_PACKAGE_PYTHON3_ZSTD
bool "zstd module"
select BR2_PACKAGE_ZSTD
help
zstd support in Python3
endmenu
endif

View File

@@ -170,6 +170,12 @@ else
PYTHON3_CONF_ENV += py_cv_module_zlib=n/a
endif
ifeq ($(BR2_PACKAGE_PYTHON3_ZSTD),y)
PYTHON3_DEPENDENCIES += zstd
else
PYTHON3_CONF_ENV += py_cv_module__zstd=n/a
endif
ifneq ($(BR2_PACKAGE_PYTHON3_OSSAUDIODEV),y)
PYTHON3_CONF_ENV += py_cv_module_ossaudiodev=n/a
endif