From f32f21de44f2b5280c2a339b0917f61f698de66c Mon Sep 17 00:00:00 2001 From: Jeremy Puhlman Date: Thu, 30 Jan 2020 15:28:40 -0800 Subject: python: move appends to a dynamic-layer Signed-off-by: Jeremy Puhlman Signed-off-by: Joe MacDonald --- .../recipes-devtools/python/files/sitecustomize.py | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 dynamic-layers/python2-layer/recipes-devtools/python/files/sitecustomize.py (limited to 'dynamic-layers/python2-layer/recipes-devtools/python/files/sitecustomize.py') diff --git a/dynamic-layers/python2-layer/recipes-devtools/python/files/sitecustomize.py b/dynamic-layers/python2-layer/recipes-devtools/python/files/sitecustomize.py new file mode 100644 index 0000000..d2b71fa --- /dev/null +++ b/dynamic-layers/python2-layer/recipes-devtools/python/files/sitecustomize.py @@ -0,0 +1,26 @@ +# OpenEmbedded sitecustomize.py (C) 2002-2008 Michael 'Mickey' Lauer +# GPLv2 or later +# Version: 20081123 +# Features: +# * set proper default encoding +# Features removed for SELinux: +# * enable readline completion in the interactive interpreter +# * load command line history on startup +# * save command line history on exit + +import os + +def __enableDefaultEncoding(): + import sys + try: + sys.setdefaultencoding( "utf8" ) + except LookupError: + pass + +import sys +try: + import rlcompleter, readline +except ImportError: + pass +else: + __enableDefaultEncoding() -- cgit v1.2.3-54-g00ecf