summaryrefslogtreecommitdiffstats
path: root/recipes-devtools/python/files/sitecustomize.py
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2017-09-08 10:44:23 -0500
committerMark Hatle <mark.hatle@windriver.com>2017-09-14 08:29:01 -0500
commit4fefe83c3203c11fadbe43637a3058284b60427b (patch)
treeaf4b33f05100c12ed16851f5dd4129f0e176da25 /recipes-devtools/python/files/sitecustomize.py
parent694b8d1f1a590083e4445d6941f24b412ec0f206 (diff)
downloadmeta-selinux-4fefe83c3203c11fadbe43637a3058284b60427b.tar.gz
Refactor to conform to YP Compat requirements
Change the references to check for the distribution flag of 'selinux' being set before taking any action within the bbappends. This prevents the signature from being modified. Also remove PR changes, as they are no longer allowed. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Diffstat (limited to 'recipes-devtools/python/files/sitecustomize.py')
-rw-r--r--recipes-devtools/python/files/sitecustomize.py26
1 files changed, 26 insertions, 0 deletions
diff --git a/recipes-devtools/python/files/sitecustomize.py b/recipes-devtools/python/files/sitecustomize.py
new file mode 100644
index 0000000..d2b71fa
--- /dev/null
+++ b/recipes-devtools/python/files/sitecustomize.py
@@ -0,0 +1,26 @@
1# OpenEmbedded sitecustomize.py (C) 2002-2008 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
2# GPLv2 or later
3# Version: 20081123
4# Features:
5# * set proper default encoding
6# Features removed for SELinux:
7# * enable readline completion in the interactive interpreter
8# * load command line history on startup
9# * save command line history on exit
10
11import os
12
13def __enableDefaultEncoding():
14 import sys
15 try:
16 sys.setdefaultencoding( "utf8" )
17 except LookupError:
18 pass
19
20import sys
21try:
22 import rlcompleter, readline
23except ImportError:
24 pass
25else:
26 __enableDefaultEncoding()