From f1c092da8ba4d03125387a337ab45c9b5a1315dc Mon Sep 17 00:00:00 2001 From: Maxime Ripard Date: Wed, 29 May 2013 10:36:57 +0200 Subject: python3: Port python2 patches to reduce the interpreter size Some of the python2 patches were left behind when doing the python3 package. This was because the python build system can now autodetect what packages can be built in the system. However, some of these patches are actually useful to reduce drastically the size of the interpreter. This patch ports the relevant patches to the python3 package, and adds a new patch to remove the idle3 IDE as well from the interpreter. Fixes #5696 Signed-off-by: Maxime Ripard Signed-off-by: Peter Korsgaard --- package/python3/python3.mk | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) (limited to 'package/python3/python3.mk') diff --git a/package/python3/python3.mk b/package/python3/python3.mk index 11ffe61b8..39202ff1b 100644 --- a/package/python3/python3.mk +++ b/package/python3/python3.mk @@ -24,12 +24,8 @@ HOST_PYTHON3_CONF_OPT += \ --disable-codecs-cjk \ --disable-nis \ --disable-unicodedata \ - --disable-dbm \ - --disable-gdbm \ - --disable-bsddb \ --disable-test-modules \ - --disable-bz2 \ - --disable-ssl + --disable-idle3 HOST_PYTHON3_MAKE_ENV = \ PYTHON_MODULES_INCLUDE=$(HOST_DIR)/usr/include \ @@ -62,6 +58,8 @@ endif ifeq ($(BR2_PACKAGE_PYTHON3_CURSES),y) PYTHON3_DEPENDENCIES += ncurses +else +PYTHON3_CONF_OPT += --disable-curses endif ifeq ($(BR2_PACKAGE_PYTHON3_PYEXPAT),y) @@ -77,14 +75,24 @@ endif ifeq ($(BR2_PACKAGE_PYTHON3_SQLITE),y) PYTHON3_DEPENDENCIES += sqlite +else +PYTHON3_CONF_OPT += --disable-sqlite3 endif ifeq ($(BR2_PACKAGE_PYTHON3_SSL),y) -PYTHON_DEPENDENCIES += openssl +PYTHON3_DEPENDENCIES += openssl +endif + +ifneq ($(BR2_PACKAGE_PYTHON3_CODECSCJK),y) +PYTHON3_CONF_OPT += --disable-codecs-cjk +endif + +ifneq ($(BR2_PACKAGE_PYTHON3_UNICODEDATA),y) +PYTHON3_CONF_OPT += --disable-unicodedata endif ifeq ($(BR2_PACKAGE_PYTHON3_BZIP2),y) -PYTHON_DEPENDENCIES += bzip2 +PYTHON3_DEPENDENCIES += bzip2 endif ifeq ($(BR2_PACKAGE_PYTHON3_ZLIB),y) @@ -106,10 +114,9 @@ PYTHON3_CONF_OPT += \ --disable-pydoc \ --disable-test-modules \ --disable-lib2to3 \ - --disable-gdbm \ --disable-tk \ --disable-nis \ - --disable-dbm + --disable-idle3 PYTHON3_MAKE_ENV = \ _PROJECT_BASE=$(PYTHON3_DIR) \ -- cgit v1.2.3