janus-gateway: make echo test plugin optional
[buildroot-gz.git] / package / python3 / 0021-Add-an-option-to-disable-the-tk-module.patch
blob7dfb339ea4c6ae5a5540581d62166e84938d7a80
1 From d0d42570e5a23c3bf559e0413ec97729fd2f9e24 Mon Sep 17 00:00:00 2001
2 From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
3 Date: Wed, 23 Dec 2015 11:49:14 +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 c822dbd..0a93c27 100644
15 --- a/Makefile.pre.in
16 +++ b/Makefile.pre.in
17 @@ -1170,7 +1170,7 @@ maninstall: altmaninstall
18 PLATDIR= @PLATDIR@
19 MACHDEPS= $(PLATDIR)
20 XMLLIBSUBDIRS= xml xml/dom xml/etree xml/parsers xml/sax
21 -LIBSUBDIRS= tkinter \
22 +LIBSUBDIRS= \
23 site-packages \
24 asyncio \
25 collections concurrent concurrent/futures encodings \
26 @@ -1188,8 +1188,7 @@ LIBSUBDIRS= tkinter \
27 venv venv/scripts venv/scripts/posix \
28 curses $(MACHDEPS)
30 -TESTSUBDIRS = tkinter/test tkinter/test/test_tkinter tkinter/test/test_ttk \
31 - test test/test_asyncio \
32 +TESTSUBDIRS = test test/test_asyncio \
33 test/test_email test/test_email/data \
34 test/test_json \
35 test/audiodata \
36 @@ -1248,6 +1247,12 @@ LIBSUBDIRS += sqlite3
37 TESTSUBDIRS += sqlite3/test
38 endif
40 +ifeq (@TK@,yes)
41 +LIBSUBDIRS += tkinter
42 +TESTSUBDIRS += tkinter/test tkinter/test/test_tkinter \
43 + tkinter/test/test_ttk
44 +endif
46 ifeq (@TEST_MODULES@,yes)
47 LIBSUBDIRS += $(TESTSUBDIRS)
48 endif
49 diff --git a/configure.ac b/configure.ac
50 index cae12ad..787b185 100644
51 --- a/configure.ac
52 +++ b/configure.ac
53 @@ -2903,6 +2903,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.6.4