python-dataproperty: bump version to 0.17.0
[buildroot-gz.git] / package / python / 0020-Add-an-option-to-disable-the-tk-module.patch
blob82df405e450e5d934b2e9b3cfa006b3575f20204
1 From 05fbe2527b6f87edeef11f288c36bcbaa378ca02 Mon Sep 17 00:00:00 2001
2 From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
3 Date: Tue, 7 Mar 2017 22:28:57 +0100
4 Subject: [PATCH] Add an option to disable the tk module
6 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
7 Signed-off-by: Samuel Martin <s.martin49@gmail.com>
8 ---
9 Makefile.pre.in | 11 ++++++++---
10 configure.ac | 9 +++++++++
11 2 files changed, 17 insertions(+), 3 deletions(-)
13 diff --git a/Makefile.pre.in b/Makefile.pre.in
14 index 974a052..f7f025f 100644
15 --- a/Makefile.pre.in
16 +++ b/Makefile.pre.in
17 @@ -1038,7 +1038,7 @@ PLATMACDIRS= plat-mac plat-mac/Carbon plat-mac/lib-scriptpackages \
18 plat-mac/lib-scriptpackages/SystemEvents \
19 plat-mac/lib-scriptpackages/Terminal
20 PLATMACPATH=:plat-mac:plat-mac/lib-scriptpackages
21 -LIBSUBDIRS= lib-tk site-packages \
22 +LIBSUBDIRS= site-packages \
23 encodings compiler hotshot \
24 email email/mime \
25 ensurepip ensurepip/_bundled \
26 @@ -1052,8 +1052,7 @@ LIBSUBDIRS= lib-tk site-packages \
27 lib-old \
28 curses $(MACHDEPS)
30 -TESTSUBDIRS = lib-tk/test lib-tk/test/test_tkinter \
31 - lib-tk/test/test_ttk test test/audiodata test/capath test/data \
32 +TESTSUBDIRS = test test/audiodata test/capath test/data \
33 test/cjkencodings test/decimaltestdata test/xmltestdata \
34 test/imghdrdata \
35 test/subprocessdata \
36 @@ -1087,6 +1086,12 @@ LIBSUBDIRS += sqlite3
37 TESTSUBDIRS += sqlite3/test
38 endif
40 +ifeq (@TK@,yes)
41 +LIBSUBDIRS += lib-tk
42 +TESTSUBDIRS += lib-tk/test lib-tk/test/test_tkinter \
43 + lib-tk/test/test_ttk
44 +endif
46 libinstall: build_all $(srcdir)/Lib/$(PLATDIR) $(srcdir)/Modules/xxmodule.c
47 @for i in $(SCRIPTDIR) $(LIBDEST); \
48 do \
49 diff --git a/configure.ac b/configure.ac
50 index e9e1897..d0f032c 100644
51 --- a/configure.ac
52 +++ b/configure.ac
53 @@ -2814,6 +2814,15 @@ if test "$SQLITE3" = "no" ; then
54 DISABLED_EXTENSIONS="${DISABLED_EXTENSIONS} _sqlite3"
57 +AC_SUBST(TK)
58 +AC_ARG_ENABLE(tk,
59 + AS_HELP_STRING([--disable-tk], [disable tk]),
60 + [ TK="${enableval}" ], [ TK=yes ])
62 +if test "$TK" = "no"; then
63 + DISABLED_EXTENSIONS="${DISABLED_EXTENSIONS} _tkinter"
64 +fi
66 AC_SUBST(PYDOC)
68 AC_ARG_ENABLE(pydoc,
69 --
70 2.7.4