0030-Do-not-install-the-idle-editor.patch 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. From 4b7c45c756dccfd3b5ece36fe572042353d1c2f0 Mon Sep 17 00:00:00 2001
  2. From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
  3. Date: Tue, 7 Mar 2017 22:30:56 +0100
  4. Subject: [PATCH] Do not install the idle editor
  5. IDLE is the Python IDE built with the tkinter GUI toolkit. Since it's
  6. highly unlikely to ever be useful in an embedded Linux system
  7. generated by Buildroot, this patch simply disables the installation of
  8. idle and the related Python modules. It saves 800 KB-900 KB of
  9. installed .pyc files.
  10. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
  11. ---
  12. Makefile.pre.in | 2 --
  13. setup.py | 2 +-
  14. 2 files changed, 1 insertion(+), 3 deletions(-)
  15. diff --git a/Makefile.pre.in b/Makefile.pre.in
  16. index 2582574..3cfc590 100644
  17. --- a/Makefile.pre.in
  18. +++ b/Makefile.pre.in
  19. @@ -1045,7 +1045,6 @@ LIBSUBDIRS= site-packages \
  20. json \
  21. logging csv importlib wsgiref \
  22. ctypes ctypes/macholib \
  23. - idlelib idlelib/Icons \
  24. distutils distutils/command \
  25. multiprocessing multiprocessing/dummy \
  26. unittest \
  27. @@ -1060,7 +1059,6 @@ TESTSUBDIRS = test test/audiodata test/capath test/data \
  28. email/test email/test/data \
  29. json/tests \
  30. ctypes/test \
  31. - idlelib/idle_test \
  32. distutils/tests \
  33. unittest/test
  34. diff --git a/setup.py b/setup.py
  35. index c68f6b4..8045a9b 100644
  36. --- a/setup.py
  37. +++ b/setup.py
  38. @@ -2234,7 +2234,7 @@ def main():
  39. import warnings
  40. warnings.filterwarnings("ignore",category=DeprecationWarning)
  41. - scripts = ['Tools/scripts/idle', 'Lib/smtpd.py']
  42. + scripts = ['Lib/smtpd.py']
  43. if not '--disable-pydoc' in sysconfig.get_config_var("CONFIG_ARGS"):
  44. scripts += [ 'Tools/scripts/pydoc' ]
  45. if not '--disable-lib2to3' in sysconfig.get_config_var("CONFIG_ARGS"):
  46. --
  47. 2.7.4